From 24f0d97075595251ecae8a4c86bbd180885c338f Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Fri, 2 Jan 2009 16:24:44 +0000 Subject: Small fix to prevent client thread crash in multi-region instances when a scripted object is paid --- OpenSim/Region/ScriptEngine/XEngine/EventManager.cs | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'OpenSim') diff --git a/OpenSim/Region/ScriptEngine/XEngine/EventManager.cs b/OpenSim/Region/ScriptEngine/XEngine/EventManager.cs index bb939fb..8355b60 100644 --- a/OpenSim/Region/ScriptEngine/XEngine/EventManager.cs +++ b/OpenSim/Region/ScriptEngine/XEngine/EventManager.cs @@ -70,8 +70,17 @@ namespace OpenSim.Region.ScriptEngine.XEngine private void HandleObjectPaid(UUID objectID, UUID agentID, int amount) { + // Since this is an event from a shared module, all scenes will + // get it. But only one has the object in question. The others + // just ignore it. + // SceneObjectPart part = myScriptEngine.World.GetSceneObjectPart(objectID); + + if (part == null) + return; + + Console.WriteLine("Paid: {0} from {1}, amount {2}", objectID,agentID,amount); if (part.ParentGroup != null) part = part.ParentGroup.RootPart; -- cgit v1.1