aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/XEngine
diff options
context:
space:
mode:
authorMelanie2011-10-25 02:57:01 +0100
committerMelanie2011-10-25 02:57:01 +0100
commit89e973805d30619b2309c538c205734af4907f1a (patch)
tree4bab60f7bcf03ee0b0c2f29ab71e7654ffdaff58 /OpenSim/Region/ScriptEngine/XEngine
parentMerge commit 'd9184eceab5ff9087801b0f0d447dec2f5227a50' into bigmerge (diff)
parentAdd "show scripts" command to show all scripts currently known to the script ... (diff)
downloadopensim-SC_OLD-89e973805d30619b2309c538c205734af4907f1a.zip
opensim-SC_OLD-89e973805d30619b2309c538c205734af4907f1a.tar.gz
opensim-SC_OLD-89e973805d30619b2309c538c205734af4907f1a.tar.bz2
opensim-SC_OLD-89e973805d30619b2309c538c205734af4907f1a.tar.xz
Merge commit 'ecad9f9fd589f90d1c7a20faf14af0304804b616' into bigmerge
Diffstat (limited to 'OpenSim/Region/ScriptEngine/XEngine')
-rw-r--r--OpenSim/Region/ScriptEngine/XEngine/XEngine.cs28
1 files changed, 28 insertions, 0 deletions
diff --git a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs
index 32d1fd3..572ca07 100644
--- a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs
+++ b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs
@@ -42,6 +42,7 @@ using log4net;
42using Nini.Config; 42using Nini.Config;
43using Amib.Threading; 43using Amib.Threading;
44using OpenSim.Framework; 44using OpenSim.Framework;
45using OpenSim.Framework.Console;
45using OpenSim.Region.Framework.Scenes; 46using OpenSim.Region.Framework.Scenes;
46using OpenSim.Region.Framework.Interfaces; 47using OpenSim.Region.Framework.Interfaces;
47using OpenSim.Region.ScriptEngine.Shared; 48using OpenSim.Region.ScriptEngine.Shared;
@@ -333,6 +334,33 @@ namespace OpenSim.Region.ScriptEngine.XEngine
333 OnScriptRemoved += m_XmlRpcRouter.ScriptRemoved; 334 OnScriptRemoved += m_XmlRpcRouter.ScriptRemoved;
334 OnObjectRemoved += m_XmlRpcRouter.ObjectRemoved; 335 OnObjectRemoved += m_XmlRpcRouter.ObjectRemoved;
335 } 336 }
337
338 MainConsole.Instance.Commands.AddCommand(
339 "scripts", false, "scripts show", "scripts show", "Show script information",
340 "Show information on all scripts known to the script engine", HandleShowScripts);
341
342 MainConsole.Instance.Commands.AddCommand(
343 "scripts", false, "show scripts", "show scripts", "Show script information",
344 "Synonym for scripts show command", HandleShowScripts);
345 }
346
347 public void HandleShowScripts(string module, string[] cmdparams)
348 {
349 lock (m_Scripts)
350 {
351 MainConsole.Instance.OutputFormat(
352 "Showing {0} scripts in {1}", m_Scripts.Count, m_Scene.RegionInfo.RegionName);
353
354 foreach (IScriptInstance instance in m_Scripts.Values)
355 {
356 SceneObjectPart sop = m_Scene.GetSceneObjectPart(instance.ObjectID);
357
358 MainConsole.Instance.OutputFormat(
359 "{0}.{1}, script UUID {2}, prim UUID {3} @ {4}",
360 instance.PrimName, instance.ScriptName, instance.AssetID, instance.ObjectID,
361 sop.AbsolutePosition, m_Scene.RegionInfo.RegionName);
362 }
363 }
336 } 364 }
337 365
338 public void RemoveRegion(Scene scene) 366 public void RemoveRegion(Scene scene)