aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorMelanie Thielker2009-07-08 14:36:00 +0000
committerMelanie Thielker2009-07-08 14:36:00 +0000
commit2d949c1f25e1fa1359a8f780675dbb0396b755d7 (patch)
treea95909217132657f5568f336063f5c9d8cf20057
parentPrevent scripts from moving prims underground (diff)
downloadopensim-SC-2d949c1f25e1fa1359a8f780675dbb0396b755d7.zip
opensim-SC-2d949c1f25e1fa1359a8f780675dbb0396b755d7.tar.gz
opensim-SC-2d949c1f25e1fa1359a8f780675dbb0396b755d7.tar.bz2
opensim-SC-2d949c1f25e1fa1359a8f780675dbb0396b755d7.tar.xz
Add DisableUndergroundMovement to scrpting API to allow underground movement
if needed. Defaults to true, so those who want to continue using underground scripted prims need to add that option and set it.
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs4
1 files changed, 3 insertions, 1 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index 9f02880..1d71da3 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -1857,7 +1857,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
1857 } 1857 }
1858 1858
1859 float ground = World.GetGroundHeight((float)targetPos.x, (float)targetPos.y); 1859 float ground = World.GetGroundHeight((float)targetPos.x, (float)targetPos.y);
1860 if (targetPos.z < ground) 1860 bool disable_underground_movement = m_ScriptEngine.Config.GetBoolean("DisableUndergroundMovement", true);
1861
1862 if ((targetPos.z < ground) && disable_underground_movement)
1861 targetPos.z = ground; 1863 targetPos.z = ground;
1862 1864
1863 if (part.ParentGroup == null) 1865 if (part.ParentGroup == null)