aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs32
1 files changed, 28 insertions, 4 deletions
diff --git a/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs b/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs
index a3f546d..7903b52 100644
--- a/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs
+++ b/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs
@@ -2058,8 +2058,15 @@ namespace OpenSim.Region.ScriptEngine.Common
2058 public string llGetOwnerKey(string id) 2058 public string llGetOwnerKey(string id)
2059 { 2059 {
2060 m_host.AddScriptLPS(1); 2060 m_host.AddScriptLPS(1);
2061 2061 LLUUID key = new LLUUID();
2062 return m_host.OwnerID.ToString(); 2062 if (LLUUID.TryParse(id, out key))
2063 {
2064 return World.GetSceneObjectPart(World.Entities[key].LocalId).OwnerID.ToString();
2065 }
2066 else
2067 {
2068 return LLUUID.Zero.ToString();
2069 }
2063 } 2070 }
2064 2071
2065 public LSL_Types.Vector3 llGetCenterOfMass() 2072 public LSL_Types.Vector3 llGetCenterOfMass()
@@ -2715,9 +2722,26 @@ namespace OpenSim.Region.ScriptEngine.Common
2715 2722
2716 public int llOverMyLand(string id) 2723 public int llOverMyLand(string id)
2717 { 2724 {
2725
2718 m_host.AddScriptLPS(1); 2726 m_host.AddScriptLPS(1);
2719 NotImplemented("llOverMyLand"); 2727 LLUUID key = new LLUUID();
2720 return 0; 2728 if (LLUUID.TryParse(id,out key))
2729 {
2730 SceneObjectPart obj = new SceneObjectPart();
2731 obj = World.GetSceneObjectPart(World.Entities[key].LocalId);
2732 if (obj.OwnerID == World.GetLandOwner(obj.AbsolutePosition.X, obj.AbsolutePosition.Y))
2733 {
2734 return 1;
2735 }
2736 else
2737 {
2738 return 0;
2739 }
2740 }
2741 else
2742 {
2743 return 0;
2744 }
2721 } 2745 }
2722 2746
2723 public string llGetLandOwnerAt(LSL_Types.Vector3 pos) 2747 public string llGetLandOwnerAt(LSL_Types.Vector3 pos)