mirror of
https://github.com/opensim/opensim.git
synced 2026-08-01 14:16:07 +08:00
Add plumbing for the SceneObjectDeleter to wait for the script engine to
allow final deletion of objects. Meant to support the attach(NULL_KEY) event,
This commit is contained in:
@@ -476,5 +476,10 @@ namespace OpenSim.Region.ScriptEngine.DotNetEngine
|
||||
{
|
||||
return "";
|
||||
}
|
||||
|
||||
public bool CanBeDeleted(UUID itemID)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -95,6 +95,7 @@ namespace OpenSim.Region.ScriptEngine.Interfaces
|
||||
UUID GetDetectID(int idx);
|
||||
void SaveState(string assembly);
|
||||
void DestroyScriptInstance();
|
||||
bool CanBeDeleted();
|
||||
|
||||
IScriptApi GetApi(string name);
|
||||
|
||||
|
||||
@@ -991,5 +991,10 @@ namespace OpenSim.Region.ScriptEngine.Shared.Instance
|
||||
{
|
||||
get { return m_RegionID; }
|
||||
}
|
||||
|
||||
public bool CanBeDeleted()
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1241,5 +1241,14 @@ namespace OpenSim.Region.ScriptEngine.XEngine
|
||||
return "";
|
||||
return instance.GetXMLState();
|
||||
}
|
||||
|
||||
public bool CanBeDeleted(UUID itemID)
|
||||
{
|
||||
IScriptInstance instance = GetInstance(itemID);
|
||||
if (instance == null)
|
||||
return true;
|
||||
|
||||
return instance.CanBeDeleted();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user