mirror of
https://github.com/opensim/opensim.git
synced 2026-08-10 03:06:05 +08:00
Removed some ScriptEngine config debugging.
Added experimental console command to: * unload module (note: module probably doesn't support it) * load module Not visible in help (needs testing first).
This commit is contained in:
@@ -961,6 +961,30 @@ namespace OpenSim
|
||||
m_console.Notice("Shared region module: " + irm.Name);
|
||||
}
|
||||
break;
|
||||
case "unload":
|
||||
if (cmdparams.Length > 1)
|
||||
{
|
||||
foreach (IRegionModule rm in new System.Collections.ArrayList(m_moduleLoader.GetLoadedSharedModules))
|
||||
{
|
||||
if (rm.Name.ToLower() == cmdparams[1].ToLower())
|
||||
{
|
||||
m_console.Notice("Unloading module: " + rm.Name);
|
||||
m_moduleLoader.UnloadModule(rm);
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
case "load":
|
||||
if (cmdparams.Length > 1)
|
||||
{
|
||||
foreach (Scene s in new System.Collections.ArrayList(m_sceneManager.Scenes))
|
||||
{
|
||||
|
||||
m_console.Notice("Loading module: " + cmdparams[1]);
|
||||
m_moduleLoader.LoadRegionModules(cmdparams[1], s);
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -294,5 +294,12 @@ namespace OpenSim.Region.Environment
|
||||
{
|
||||
LoadedAssemblys.Clear();
|
||||
}
|
||||
|
||||
public void UnloadModule(IRegionModule rm)
|
||||
{
|
||||
rm.Close();
|
||||
|
||||
m_loadedModules.Remove(rm);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -45,6 +45,11 @@ namespace OpenSim.Region.Environment.Scenes
|
||||
private readonly List<Scene> m_localScenes;
|
||||
private Scene m_currentScene = null;
|
||||
|
||||
public List<Scene> Scenes
|
||||
{
|
||||
get { return m_localScenes; }
|
||||
}
|
||||
|
||||
public Scene CurrentScene
|
||||
{
|
||||
get { return m_currentScene; }
|
||||
|
||||
Reference in New Issue
Block a user