mirror of
https://github.com/opensim/opensim.git
synced 2026-08-01 22:26:09 +08:00
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.
This commit is contained in:
@@ -1857,7 +1857,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
|
||||
}
|
||||
|
||||
float ground = World.GetGroundHeight((float)targetPos.x, (float)targetPos.y);
|
||||
if (targetPos.z < ground)
|
||||
bool disable_underground_movement = m_ScriptEngine.Config.GetBoolean("DisableUndergroundMovement", true);
|
||||
|
||||
if ((targetPos.z < ground) && disable_underground_movement)
|
||||
targetPos.z = ground;
|
||||
|
||||
if (part.ParentGroup == null)
|
||||
|
||||
Reference in New Issue
Block a user