aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs15
1 files changed, 14 insertions, 1 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
index bc20f71..29d0342 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
@@ -1673,9 +1673,22 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
1673 CheckThreatLevel(ThreatLevel.Low, "osMessageObject"); 1673 CheckThreatLevel(ThreatLevel.Low, "osMessageObject");
1674 m_host.AddScriptLPS(1); 1674 m_host.AddScriptLPS(1);
1675 1675
1676 UUID objUUID;
1677 if (!UUID.TryParse(objectUUID, out objUUID)) // prior to patching, a thrown exception regarding invalid GUID format would be shouted instead.
1678 {
1679 OSSLShoutError("osMessageObject() cannot send messages to objects with invalid UUIDs");
1680 return;
1681 }
1682
1676 object[] resobj = new object[] { new LSL_Types.LSLString(m_host.UUID.ToString()), new LSL_Types.LSLString(message) }; 1683 object[] resobj = new object[] { new LSL_Types.LSLString(m_host.UUID.ToString()), new LSL_Types.LSLString(message) };
1677 1684
1678 SceneObjectPart sceneOP = World.GetSceneObjectPart(new UUID(objectUUID)); 1685 SceneObjectPart sceneOP = World.GetSceneObjectPart(objUUID);
1686
1687 if (sceneOP == null) // prior to patching, PostObjectEvent() would cause a throw exception to be shouted instead.
1688 {
1689 OSSLShoutError("osMessageObject() cannot send message to " + objUUID.ToString() + ", object was not found in scene.");
1690 return;
1691 }
1679 1692
1680 m_ScriptEngine.PostObjectEvent( 1693 m_ScriptEngine.PostObjectEvent(
1681 sceneOP.LocalId, new EventParams( 1694 sceneOP.LocalId, new EventParams(