diff options
author | Melanie | 2014-04-30 20:54:34 +0100 |
---|---|---|
committer | Melanie | 2014-04-30 20:54:34 +0100 |
commit | f0eeb47262c116b893644ee532bebb4dd52dec77 (patch) | |
tree | 608d072fa7cae831e429d6772f92f1a77ce810ae /OpenSim/Region/ScriptEngine | |
parent | Assign value to 'vector' to fix building under xbuild and Monodevelop (diff) | |
download | opensim-SC_OLD-f0eeb47262c116b893644ee532bebb4dd52dec77.zip opensim-SC_OLD-f0eeb47262c116b893644ee532bebb4dd52dec77.tar.gz opensim-SC_OLD-f0eeb47262c116b893644ee532bebb4dd52dec77.tar.bz2 opensim-SC_OLD-f0eeb47262c116b893644ee532bebb4dd52dec77.tar.xz |
Add the "StateChange" function to the async comand manager to differentiate
between state changes and script exit/reset.
Diffstat (limited to 'OpenSim/Region/ScriptEngine')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Implementation/AsyncCommandManager.cs | 24 |
1 files changed, 23 insertions, 1 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/AsyncCommandManager.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/AsyncCommandManager.cs index 998f40b..40a05cf 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/AsyncCommandManager.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/AsyncCommandManager.cs | |||
@@ -300,6 +300,28 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
300 | } | 300 | } |
301 | } | 301 | } |
302 | 302 | ||
303 | public static void StateChange(IScriptEngine engine, uint localID, UUID itemID) | ||
304 | { | ||
305 | // Remove a specific script | ||
306 | |||
307 | // Remove dataserver events | ||
308 | m_Dataserver[engine].RemoveEvents(localID, itemID); | ||
309 | |||
310 | IWorldComm comms = engine.World.RequestModuleInterface<IWorldComm>(); | ||
311 | if (comms != null) | ||
312 | comms.DeleteListener(itemID); | ||
313 | |||
314 | IXMLRPC xmlrpc = engine.World.RequestModuleInterface<IXMLRPC>(); | ||
315 | if (xmlrpc != null) | ||
316 | { | ||
317 | xmlrpc.DeleteChannels(itemID); | ||
318 | xmlrpc.CancelSRDRequests(itemID); | ||
319 | } | ||
320 | // Remove Sensors | ||
321 | m_SensorRepeat[engine].UnSetSenseRepeaterEvents(localID, itemID); | ||
322 | |||
323 | } | ||
324 | |||
303 | /// <summary> | 325 | /// <summary> |
304 | /// Get the sensor repeat plugin for this script engine. | 326 | /// Get the sensor repeat plugin for this script engine. |
305 | /// </summary> | 327 | /// </summary> |
@@ -439,4 +461,4 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
439 | } | 461 | } |
440 | } | 462 | } |
441 | } | 463 | } |
442 | } \ No newline at end of file | 464 | } |