diff options
author | Teravus Ovares | 2008-01-17 02:23:48 +0000 |
---|---|---|
committer | Teravus Ovares | 2008-01-17 02:23:48 +0000 |
commit | c2863df49d3bd1f4f7c2f4c17d897d9f66b36b26 (patch) | |
tree | 8d2c29d6623d9e5c61634e8f7a742858eee2a5db /OpenSim/Region/ScriptEngine/Common/ScriptEngineBase | |
parent | * Fixed standing up so that you're at the new position of the prim if you mov... (diff) | |
download | opensim-SC_OLD-c2863df49d3bd1f4f7c2f4c17d897d9f66b36b26.zip opensim-SC_OLD-c2863df49d3bd1f4f7c2f4c17d897d9f66b36b26.tar.gz opensim-SC_OLD-c2863df49d3bd1f4f7c2f4c17d897d9f66b36b26.tar.bz2 opensim-SC_OLD-c2863df49d3bd1f4f7c2f4c17d897d9f66b36b26.tar.xz |
* Added and implemented the LSL changed event.
* An example changed event syntax is at: http://opensimulator.org/wiki/Changed_Event_Example
* You can use this to trigger actions in your script if someone sits on your object_rez
* You can use this to figure out all of the CHANGED_ constants except for CHANGED_REGION, CHANGED_TELEPORT, and CHANGED_ALLOW_DROP
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Common/ScriptEngineBase')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/EventManager.cs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/EventManager.cs b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/EventManager.cs index 0a8f7ea..a32a132 100644 --- a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/EventManager.cs +++ b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/EventManager.cs | |||
@@ -68,10 +68,17 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase | |||
68 | myScriptEngine.World.EventManager.OnObjectGrab += touch_start; | 68 | myScriptEngine.World.EventManager.OnObjectGrab += touch_start; |
69 | myScriptEngine.World.EventManager.OnRezScript += OnRezScript; | 69 | myScriptEngine.World.EventManager.OnRezScript += OnRezScript; |
70 | myScriptEngine.World.EventManager.OnRemoveScript += OnRemoveScript; | 70 | myScriptEngine.World.EventManager.OnRemoveScript += OnRemoveScript; |
71 | myScriptEngine.World.EventManager.OnScriptChangedEvent += changed; | ||
71 | // TODO: HOOK ALL EVENTS UP TO SERVER! | 72 | // TODO: HOOK ALL EVENTS UP TO SERVER! |
72 | } | 73 | } |
73 | } | 74 | } |
74 | 75 | ||
76 | public void changed(uint localID, uint change) | ||
77 | { | ||
78 | // Add to queue for all scripts in localID, Object pass change. | ||
79 | myScriptEngine.m_EventQueueManager.AddToObjectQueue(localID,"changed", new object[] {(int) change}); | ||
80 | } | ||
81 | |||
75 | public void touch_start(uint localID, LLVector3 offsetPos, IClientAPI remoteClient) | 82 | public void touch_start(uint localID, LLVector3 offsetPos, IClientAPI remoteClient) |
76 | { | 83 | { |
77 | // Add to queue for all scripts in ObjectID object | 84 | // Add to queue for all scripts in ObjectID object |