mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 17:05:55 +08:00
Yengine: we also need to cancel timer events in queue, because some bad scripts that do work on X
This commit is contained in:
@@ -854,7 +854,7 @@ namespace OpenSim.Region.ScriptEngine.Yengine
|
||||
public bool PostScriptEvent(UUID itemID, EventParams parms)
|
||||
{
|
||||
XMRInstance instance = GetInstance(itemID);
|
||||
if(instance == null)
|
||||
if (instance == null)
|
||||
return false;
|
||||
|
||||
TraceCalls("[YEngine]: YEngine.PostScriptEvent({0},{1})", itemID.ToString(), parms.EventName);
|
||||
@@ -863,6 +863,17 @@ namespace OpenSim.Region.ScriptEngine.Yengine
|
||||
return true;
|
||||
}
|
||||
|
||||
public void CancelScriptEvent(UUID itemID, string eventName)
|
||||
{
|
||||
XMRInstance instance = GetInstance(itemID);
|
||||
if (instance == null)
|
||||
return;
|
||||
|
||||
TraceCalls("[YEngine]: YEngine.CancelScriptEvent({0},{1})", itemID.ToString(), eventName);
|
||||
|
||||
instance.CancelEvent(eventName);
|
||||
}
|
||||
|
||||
// Events targeted at all scripts in the given prim.
|
||||
// localID = which prim
|
||||
// parms = event to post
|
||||
|
||||
Reference in New Issue
Block a user