diff options
author | Tedd Hansen | 2008-02-10 19:03:38 +0000 |
---|---|---|
committer | Tedd Hansen | 2008-02-10 19:03:38 +0000 |
commit | 0756e01475f05663e23fc2e328620750d981dd40 (patch) | |
tree | 9a0ecb4f950a0cf804f341898d57bce5180ab9da /OpenSim/Region | |
parent | * Added support for delinking individual prim from a linkset. (diff) | |
download | opensim-SC-0756e01475f05663e23fc2e328620750d981dd40.zip opensim-SC-0756e01475f05663e23fc2e328620750d981dd40.tar.gz opensim-SC-0756e01475f05663e23fc2e328620750d981dd40.tar.bz2 opensim-SC-0756e01475f05663e23fc2e328620750d981dd40.tar.xz |
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).
Diffstat (limited to 'OpenSim/Region')
-rw-r--r-- | OpenSim/Region/Application/OpenSimMain.cs | 24 | ||||
-rw-r--r-- | OpenSim/Region/Environment/ModuleLoader.cs | 7 | ||||
-rw-r--r-- | OpenSim/Region/Environment/Scenes/SceneManager.cs | 5 |
3 files changed, 36 insertions, 0 deletions
diff --git a/OpenSim/Region/Application/OpenSimMain.cs b/OpenSim/Region/Application/OpenSimMain.cs index 6fd479c..d28d65a 100644 --- a/OpenSim/Region/Application/OpenSimMain.cs +++ b/OpenSim/Region/Application/OpenSimMain.cs | |||
@@ -961,6 +961,30 @@ namespace OpenSim | |||
961 | m_console.Notice("Shared region module: " + irm.Name); | 961 | m_console.Notice("Shared region module: " + irm.Name); |
962 | } | 962 | } |
963 | break; | 963 | break; |
964 | case "unload": | ||
965 | if (cmdparams.Length > 1) | ||
966 | { | ||
967 | foreach (IRegionModule rm in new System.Collections.ArrayList(m_moduleLoader.GetLoadedSharedModules)) | ||
968 | { | ||
969 | if (rm.Name.ToLower() == cmdparams[1].ToLower()) | ||
970 | { | ||
971 | m_console.Notice("Unloading module: " + rm.Name); | ||
972 | m_moduleLoader.UnloadModule(rm); | ||
973 | } | ||
974 | } | ||
975 | } | ||
976 | break; | ||
977 | case "load": | ||
978 | if (cmdparams.Length > 1) | ||
979 | { | ||
980 | foreach (Scene s in new System.Collections.ArrayList(m_sceneManager.Scenes)) | ||
981 | { | ||
982 | |||
983 | m_console.Notice("Loading module: " + cmdparams[1]); | ||
984 | m_moduleLoader.LoadRegionModules(cmdparams[1], s); | ||
985 | } | ||
986 | } | ||
987 | break; | ||
964 | } | 988 | } |
965 | } | 989 | } |
966 | 990 | ||
diff --git a/OpenSim/Region/Environment/ModuleLoader.cs b/OpenSim/Region/Environment/ModuleLoader.cs index bc0bbaf..1200c8d 100644 --- a/OpenSim/Region/Environment/ModuleLoader.cs +++ b/OpenSim/Region/Environment/ModuleLoader.cs | |||
@@ -294,5 +294,12 @@ namespace OpenSim.Region.Environment | |||
294 | { | 294 | { |
295 | LoadedAssemblys.Clear(); | 295 | LoadedAssemblys.Clear(); |
296 | } | 296 | } |
297 | |||
298 | public void UnloadModule(IRegionModule rm) | ||
299 | { | ||
300 | rm.Close(); | ||
301 | |||
302 | m_loadedModules.Remove(rm); | ||
303 | } | ||
297 | } | 304 | } |
298 | } \ No newline at end of file | 305 | } \ No newline at end of file |
diff --git a/OpenSim/Region/Environment/Scenes/SceneManager.cs b/OpenSim/Region/Environment/Scenes/SceneManager.cs index 0b88050..490f808 100644 --- a/OpenSim/Region/Environment/Scenes/SceneManager.cs +++ b/OpenSim/Region/Environment/Scenes/SceneManager.cs | |||
@@ -45,6 +45,11 @@ namespace OpenSim.Region.Environment.Scenes | |||
45 | private readonly List<Scene> m_localScenes; | 45 | private readonly List<Scene> m_localScenes; |
46 | private Scene m_currentScene = null; | 46 | private Scene m_currentScene = null; |
47 | 47 | ||
48 | public List<Scene> Scenes | ||
49 | { | ||
50 | get { return m_localScenes; } | ||
51 | } | ||
52 | |||
48 | public Scene CurrentScene | 53 | public Scene CurrentScene |
49 | { | 54 | { |
50 | get { return m_currentScene; } | 55 | get { return m_currentScene; } |