mirror of
https://github.com/opensim/opensim.git
synced 2026-08-11 03:45:35 +08:00
Delay loading scripts until the scene has finished loading
This commit is contained in:
committed by
Justin Clark-Casey (justincc)
parent
7cafc2e46e
commit
1dd904b78e
@@ -57,11 +57,11 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
protected AsyncInventorySender m_asyncInventorySender;
|
||||
|
||||
/// <summary>
|
||||
/// Start all the scripts in the scene which should be started.
|
||||
/// Creates all the scripts in the scene which should be started.
|
||||
/// </summary>
|
||||
public void CreateScriptInstances()
|
||||
{
|
||||
m_log.Info("[PRIM INVENTORY]: Starting scripts in scene");
|
||||
m_log.Info("[PRIM INVENTORY]: Creating scripts in scene");
|
||||
|
||||
EntityBase[] entities = Entities.GetEntities();
|
||||
foreach (EntityBase group in entities)
|
||||
@@ -74,6 +74,26 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Lets the script engines start processing scripts.
|
||||
/// </summary>
|
||||
public void StartScripts()
|
||||
{
|
||||
m_log.Info("[PRIM INVENTORY]: Starting scripts in scene");
|
||||
|
||||
IScriptModule[] engines = RequestModuleInterfaces<IScriptModule>();
|
||||
if (engines != null)
|
||||
{
|
||||
foreach (IScriptModule engine in engines)
|
||||
{
|
||||
if (engine != null)
|
||||
{
|
||||
engine.StartProcessing();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void AddUploadedInventoryItem(UUID agentID, InventoryItemBase item)
|
||||
{
|
||||
IMoneyModule money = RequestModuleInterface<IMoneyModule>();
|
||||
|
||||
Reference in New Issue
Block a user