From a70ef1c2cb90a5b40a2e19acb81cf7310c140663 Mon Sep 17 00:00:00 2001 From: MW Date: Wed, 4 Apr 2007 11:06:39 +0000 Subject: Started to clean up/ rewrite Primitive class , currently the new version is called Primitive2 and not used, but once it is complete then it will replace the old version. --- OpenSim.RegionServer/world/World.cs | 32 ++++++++------------------------ 1 file changed, 8 insertions(+), 24 deletions(-) (limited to 'OpenSim.RegionServer/world/World.cs') diff --git a/OpenSim.RegionServer/world/World.cs b/OpenSim.RegionServer/world/World.cs index 0799e38..b6f71aa 100644 --- a/OpenSim.RegionServer/world/World.cs +++ b/OpenSim.RegionServer/world/World.cs @@ -76,32 +76,16 @@ namespace OpenSim.world scriptend = scriptData.LastIndexOf(""); substring = scriptData.Substring(scriptstart + 8, scriptend - scriptstart - 8); substring = substring.Trim(); - Console.WriteLine("searching for script to add: " + substring); - + //Console.WriteLine("searching for script to add: " + substring); + ScriptFactory scriptFactory; - - if (this.m_scripts.TryGetValue(substring, out scriptFactory )) + + if (this.m_scripts.TryGetValue(substring, out scriptFactory)) { - Console.WriteLine("added script"); - - - + //Console.WriteLine("added script"); this.AddScript(entity, scriptFactory()); } - /*string delimStr = " "; - char[] delimiter = delimStr.ToCharArray(); - string[] line; - line = scriptData.Split(delimiter); - if (line.Length > 1) - { - if (line[0] == "script:") - { - if (this.m_scripts.ContainsKey(line[1])) - { - this.AddScript(entity, this.m_scripts[line[1]]); - } - } - }*/ + } public InventoryCache InventoryCache @@ -566,8 +550,8 @@ namespace OpenSim.world { this.m_scripts.Add("FollowRandomAvatar", delegate() { - return new FollowRandomAvatar(); - }); + return new FollowRandomAvatar(); + }); } -- cgit v1.1