aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim.RegionServer/world/World.cs
diff options
context:
space:
mode:
authorMW2007-04-11 12:13:21 +0000
committerMW2007-04-11 12:13:21 +0000
commit5ad6d5a939fb7bf0fdfdc6925d4afed306e08641 (patch)
tree8bcf302b69297a27ab254d087f73fe88fecab464 /OpenSim.RegionServer/world/World.cs
parentChanged so that a bin\ScriptEngines\ directory will be searched for scripting... (diff)
downloadopensim-SC_OLD-5ad6d5a939fb7bf0fdfdc6925d4afed306e08641.zip
opensim-SC_OLD-5ad6d5a939fb7bf0fdfdc6925d4afed306e08641.tar.gz
opensim-SC_OLD-5ad6d5a939fb7bf0fdfdc6925d4afed306e08641.tar.bz2
opensim-SC_OLD-5ad6d5a939fb7bf0fdfdc6925d4afed306e08641.tar.xz
First basic test script now works in the jvm scripting engine.
For it to work you need to have a java sdk installed and the javac.exe somewhere in the environment Path variable. Then To test, copy the text from bin/script1.text into a note card and then add that note to a prim.
Diffstat (limited to 'OpenSim.RegionServer/world/World.cs')
-rw-r--r--OpenSim.RegionServer/world/World.cs10
1 files changed, 5 insertions, 5 deletions
diff --git a/OpenSim.RegionServer/world/World.cs b/OpenSim.RegionServer/world/World.cs
index 74325b0..a973c6c 100644
--- a/OpenSim.RegionServer/world/World.cs
+++ b/OpenSim.RegionServer/world/World.cs
@@ -87,22 +87,22 @@ namespace OpenSim.world
87 //Console.WriteLine("searching for script to add: " + substring); 87 //Console.WriteLine("searching for script to add: " + substring);
88 88
89 ScriptFactory scriptFactory; 89 ScriptFactory scriptFactory;
90 Console.WriteLine("script string is " + substring); 90 //Console.WriteLine("script string is " + substring);
91 if(substring.StartsWith("<ScriptEngine:")) 91 if(substring.StartsWith("<ScriptEngine:"))
92 { 92 {
93 string substring1 = ""; 93 string substring1 = "";
94 string script = ""; 94 string script = "";
95 Console.WriteLine("searching for script engine"); 95 // Console.WriteLine("searching for script engine");
96 substring1 = substring.Remove(0, 14); 96 substring1 = substring.Remove(0, 14);
97 int dev = substring1.IndexOf(','); 97 int dev = substring1.IndexOf(',');
98 string sEngine = substring1.Substring(0, dev); 98 string sEngine = substring1.Substring(0, dev);
99 substring1 = substring1.Remove(0, dev+1); 99 substring1 = substring1.Remove(0, dev+1);
100 int end = substring1.IndexOf('>'); 100 int end = substring1.IndexOf('>');
101 string sName = substring1.Substring(0, end); 101 string sName = substring1.Substring(0, end);
102 Console.WriteLine(" script info : " + sEngine + " , " + sName); 102 //Console.WriteLine(" script info : " + sEngine + " , " + sName);
103 int startscript = substring.IndexOf('>'); 103 int startscript = substring.IndexOf('>');
104 script = substring.Remove(0, startscript + 1); 104 script = substring.Remove(0, startscript + 1);
105 Console.WriteLine("script data is " + script); 105 // Console.WriteLine("script data is " + script);
106 if (this.scriptEngines.ContainsKey(sEngine)) 106 if (this.scriptEngines.ContainsKey(sEngine))
107 { 107 {
108 this.scriptEngines[sEngine].LoadScript(script, sName, entity.localid); 108 this.scriptEngines[sEngine].LoadScript(script, sName, entity.localid);
@@ -172,7 +172,7 @@ namespace OpenSim.world
172 } 172 }
173 foreach (IScriptEngine scripteng in this.scriptEngines.Values) 173 foreach (IScriptEngine scripteng in this.scriptEngines.Values)
174 { 174 {
175 //scripteng.OnFrame(); 175 scripteng.OnFrame();
176 } 176 }
177 //backup world data 177 //backup world data
178 this.storageCount++; 178 this.storageCount++;