From 9a0ef22ed979433f4d017a252173f38fe5e56892 Mon Sep 17 00:00:00 2001 From: Charles Krinke Date: Sat, 28 Jun 2008 16:08:12 +0000 Subject: Mantis#1616. Applied Melanie's patch. This may or may not break trunk. --- OpenSim/Region/Environment/Scenes/EventManager.cs | 37 ++++++++++++++++------- 1 file changed, 26 insertions(+), 11 deletions(-) (limited to 'OpenSim/Region/Environment/Scenes/EventManager.cs') diff --git a/OpenSim/Region/Environment/Scenes/EventManager.cs b/OpenSim/Region/Environment/Scenes/EventManager.cs index 5c750e4..f3af0d1 100644 --- a/OpenSim/Region/Environment/Scenes/EventManager.cs +++ b/OpenSim/Region/Environment/Scenes/EventManager.cs @@ -95,17 +95,22 @@ namespace OpenSim.Region.Environment.Scenes public event OnPermissionErrorDelegate OnPermissionError; - public delegate void NewRezScript(uint localID, LLUUID itemID, string script); - public delegate void RezEvent(uint localID, LLUUID itemID, int param); + public delegate void NewRezScript(uint localID, LLUUID itemID, string script, int startParam, bool postOnRez); public event NewRezScript OnRezScript; - public event RezEvent OnRezEvent; - public delegate void RemoveScript(uint localID, LLUUID itemID); public event RemoveScript OnRemoveScript; + public delegate void StartScript(uint localID, LLUUID itemID); + + public event StartScript OnStartScript; + + public delegate void StopScript(uint localID, LLUUID itemID); + + public event StopScript OnStopScript; + public delegate bool SceneGroupMoved(LLUUID groupID, LLVector3 delta); public event SceneGroupMoved OnSceneGroupMove; @@ -332,8 +337,9 @@ namespace OpenSim.Region.Environment.Scenes private ObjectDeGrabDelegate handlerObjectDeGrab = null; //OnObjectDeGrab; private ScriptResetDelegate handlerScriptReset = null; // OnScriptReset private NewRezScript handlerRezScript = null; //OnRezScript; - private RezEvent handlerOnRezEvent = null; //OnRezEvent; private RemoveScript handlerRemoveScript = null; //OnRemoveScript; + private StartScript handlerStartScript = null; //OnStartScript; + private StopScript handlerStopScript = null; //OnStopScript; private SceneGroupMoved handlerSceneGroupMove = null; //OnSceneGroupMove; private SceneGroupGrabed handlerSceneGroupGrab = null; //OnSceneGroupGrab; private LandObjectAdded handlerLandObjectAdded = null; //OnLandObjectAdded; @@ -523,21 +529,30 @@ namespace OpenSim.Region.Environment.Scenes } } - public void TriggerRezScript(uint localID, LLUUID itemID, string script) + public void TriggerRezScript(uint localID, LLUUID itemID, string script, int startParam, bool postOnRez) { handlerRezScript = OnRezScript; if (handlerRezScript != null) { - handlerRezScript(localID, itemID, script); + handlerRezScript(localID, itemID, script, startParam, postOnRez); + } + } + + public void TriggerStartScript(uint localID, LLUUID itemID) + { + handlerStartScript = OnStartScript; + if (handlerStartScript != null) + { + handlerStartScript(localID, itemID); } } - public void TriggerOnRezEvent(uint localID, LLUUID itemID, int param) + public void TriggerStopScript(uint localID, LLUUID itemID) { - handlerOnRezEvent = OnRezEvent; - if (handlerOnRezEvent != null) + handlerStopScript = OnStopScript; + if (handlerStopScript != null) { - handlerOnRezEvent(localID, itemID, param); + handlerStopScript(localID, itemID); } } -- cgit v1.1