aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorUbitUmarov2012-06-17 09:06:25 +0100
committerUbitUmarov2012-06-17 09:06:25 +0100
commite7aceae3e0e21b9f739dbcaac055c18991887e50 (patch)
tree71d739b2e23d77d12e199903887d4956b2c0b300
parentDon't let scripts rotate root part of physical linksets like SL, Update clien... (diff)
downloadopensim-SC-e7aceae3e0e21b9f739dbcaac055c18991887e50.zip
opensim-SC-e7aceae3e0e21b9f739dbcaac055c18991887e50.tar.gz
opensim-SC-e7aceae3e0e21b9f739dbcaac055c18991887e50.tar.bz2
opensim-SC-e7aceae3e0e21b9f739dbcaac055c18991887e50.tar.xz
split ugly expression in a if making it simpler to read
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs8
1 files changed, 5 insertions, 3 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index 389a82b..d9867a8 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -2343,10 +2343,12 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
2343 else 2343 else
2344 { 2344 {
2345 // we are a child. The rotation values will be set to the one of root modified by rot, as in SL. Don't ask. 2345 // we are a child. The rotation values will be set to the one of root modified by rot, as in SL. Don't ask.
2346 SceneObjectPart rootPart;// = m_host.ParentGroup.RootPart; 2346 SceneObjectPart rootPart;
2347 if (m_host.ParentGroup != null && ((rootPart = m_host.ParentGroup.RootPart) != null)) // better safe than sorry 2347 if (m_host.ParentGroup != null) // better safe than sorry
2348 { 2348 {
2349 SetRot(m_host, rootPart.RotationOffset * Rot2Quaternion(rot)); 2349 rootPart = m_host.ParentGroup.RootPart;
2350 if (rootPart != null)
2351 SetRot(m_host, rootPart.RotationOffset * Rot2Quaternion(rot));
2350 } 2352 }
2351 } 2353 }
2352 2354