diff options
author | SignpostMarv | 2012-08-21 12:30:47 +0100 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2012-08-22 23:55:01 +0100 |
commit | 4820dfd733a5b6dae54e120cfb1486643765bb3e (patch) | |
tree | 504f61668dd51961b3087b0fd58180696d448329 | |
parent | Lock disposal of separate gdi+ objects under different threads since this pre... (diff) | |
download | opensim-SC-4820dfd733a5b6dae54e120cfb1486643765bb3e.zip opensim-SC-4820dfd733a5b6dae54e120cfb1486643765bb3e.tar.gz opensim-SC-4820dfd733a5b6dae54e120cfb1486643765bb3e.tar.bz2 opensim-SC-4820dfd733a5b6dae54e120cfb1486643765bb3e.tar.xz |
this should be an if-else block in case the non-phys min/max are smaller than the physical min/max
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index 8140416..0d275f7 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | |||
@@ -1341,11 +1341,13 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
1341 | scale.y = Math.Max(World.m_minPhys, Math.Min(World.m_maxPhys, scale.y)); | 1341 | scale.y = Math.Max(World.m_minPhys, Math.Min(World.m_maxPhys, scale.y)); |
1342 | scale.z = Math.Max(World.m_minPhys, Math.Min(World.m_maxPhys, scale.z)); | 1342 | scale.z = Math.Max(World.m_minPhys, Math.Min(World.m_maxPhys, scale.z)); |
1343 | } | 1343 | } |
1344 | 1344 | else | |
1345 | // Next we clamp the scale to the non-physical min/max | 1345 | { |
1346 | scale.x = Math.Max(World.m_minNonphys, Math.Min(World.m_maxNonphys, scale.x)); | 1346 | // If not physical, then we clamp the scale to the non-physical min/max |
1347 | scale.y = Math.Max(World.m_minNonphys, Math.Min(World.m_maxNonphys, scale.y)); | 1347 | scale.x = Math.Max(World.m_minNonphys, Math.Min(World.m_maxNonphys, scale.x)); |
1348 | scale.z = Math.Max(World.m_minNonphys, Math.Min(World.m_maxNonphys, scale.z)); | 1348 | scale.y = Math.Max(World.m_minNonphys, Math.Min(World.m_maxNonphys, scale.y)); |
1349 | scale.z = Math.Max(World.m_minNonphys, Math.Min(World.m_maxNonphys, scale.z)); | ||
1350 | } | ||
1349 | 1351 | ||
1350 | Vector3 tmp = part.Scale; | 1352 | Vector3 tmp = part.Scale; |
1351 | tmp.X = (float)scale.x; | 1353 | tmp.X = (float)scale.x; |