From 2c9cb805f07c87f978cc4ff2712221be9523c3d2 Mon Sep 17 00:00:00 2001 From: xLinka Date: Sun, 21 Jul 2024 03:21:27 +0100 Subject: [PATCH] Update RandomFloatQ.cs Fixed Invalid Q values --- ProjectObsidian/ProtoFlux/Math/Random/RandomFloatQ.cs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ProjectObsidian/ProtoFlux/Math/Random/RandomFloatQ.cs b/ProjectObsidian/ProtoFlux/Math/Random/RandomFloatQ.cs index 8dfe0b2..a70e03c 100644 --- a/ProjectObsidian/ProtoFlux/Math/Random/RandomFloatQ.cs +++ b/ProjectObsidian/ProtoFlux/Math/Random/RandomFloatQ.cs @@ -3,10 +3,8 @@ using ProtoFlux.Runtimes.Execution; using Obsidian; - namespace ProtoFlux.Runtimes.Execution.Nodes.Obsidian.Math.Random { - [NodeCategory("Obsidian/Math/Random")] [ContinuouslyChanging] public class RandomFloatQ : ValueFunctionNode @@ -19,7 +17,10 @@ protected override floatQ Compute(ExecutionContext context) floatQ min = Min.Evaluate(context); floatQ max = Max.Evaluate(context); - return RandomXExtensions.Range(min, max); + floatQ randomQuat = RandomXExtensions.Range(min, max); + randomQuat = randomQuat.Normalized; + + return randomQuat; } } } \ No newline at end of file