aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authordahlia2013-06-10 17:54:14 -0700
committerdahlia2013-06-10 17:54:14 -0700
commitba84074468e0805e0a378bf31fc580437e7ce015 (patch)
tree5baf570b6bd6b2d6636e64eb6669f0f13e3aa56d
parentllRot2Angle now checks absolute value of s rotation component before normalizing (diff)
downloadopensim-SC_OLD-ba84074468e0805e0a378bf31fc580437e7ce015.zip
opensim-SC_OLD-ba84074468e0805e0a378bf31fc580437e7ce015.tar.gz
opensim-SC_OLD-ba84074468e0805e0a378bf31fc580437e7ce015.tar.bz2
opensim-SC_OLD-ba84074468e0805e0a378bf31fc580437e7ce015.tar.xz
LSL_Rotation.Normalize() now returns 0,0,0,1 for x,y,z,s when normalization fails
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/LSL_Types.cs4
1 files changed, 2 insertions, 2 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/LSL_Types.cs b/OpenSim/Region/ScriptEngine/Shared/LSL_Types.cs
index f6d94a3..50f9377 100644
--- a/OpenSim/Region/ScriptEngine/Shared/LSL_Types.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/LSL_Types.cs
@@ -377,10 +377,10 @@ namespace OpenSim.Region.ScriptEngine.Shared
377 double length = Math.Sqrt(x * x + y * y + z * z + s * s); 377 double length = Math.Sqrt(x * x + y * y + z * z + s * s);
378 if (length < float.Epsilon) 378 if (length < float.Epsilon)
379 { 379 {
380 x = 1; 380 x = 0;
381 y = 0; 381 y = 0;
382 z = 0; 382 z = 0;
383 s = 0; 383 s = 1;
384 } 384 }
385 else 385 else
386 { 386 {