aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
authorAdam Frisby2007-07-16 18:06:35 +0000
committerAdam Frisby2007-07-16 18:06:35 +0000
commitddf73763db5cbb7084c9f5ded156dac9291cde87 (patch)
tree5f852d3f868c1de25fa5d362bb0b4309cfbd524c /OpenSim/Region
parent* Updating internal LSL handler/compiler with Tedd's r1. (diff)
downloadopensim-SC-ddf73763db5cbb7084c9f5ded156dac9291cde87.zip
opensim-SC-ddf73763db5cbb7084c9f5ded156dac9291cde87.tar.gz
opensim-SC-ddf73763db5cbb7084c9f5ded156dac9291cde87.tar.bz2
opensim-SC-ddf73763db5cbb7084c9f5ded156dac9291cde87.tar.xz
* Rigged up LSL Script Engine to OpenSim - not quite fully tied yet however, still lacks connection to ScriptInterpretedAPI. (but Hello World should work!)
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/Environment/Scenes/scripting/Engines/LSLEngine/LSLScript.cs31
-rw-r--r--OpenSim/Region/Environment/Scenes/scripting/Engines/LSLEngine/LSLScriptEngine.cs27
2 files changed, 58 insertions, 0 deletions
diff --git a/OpenSim/Region/Environment/Scenes/scripting/Engines/LSLEngine/LSLScript.cs b/OpenSim/Region/Environment/Scenes/scripting/Engines/LSLEngine/LSLScript.cs
new file mode 100644
index 0000000..1d82cd2
--- /dev/null
+++ b/OpenSim/Region/Environment/Scenes/scripting/Engines/LSLEngine/LSLScript.cs
@@ -0,0 +1,31 @@
1using System;
2using System.Collections.Generic;
3using System.Text;
4
5using OpenSim.Region.Scripting;
6using OpenSim.Region.Scripting.LSL;
7
8namespace OpenSim.Region.Scripting.LSL
9{
10 class LSLScript : IScript
11 {
12 ScriptInfo scriptInfo;
13 LSL.Engine lindenScriptEngine;
14
15 public LSLScript(string filename)
16 {
17 lindenScriptEngine = new Engine();
18 lindenScriptEngine.Start(filename);
19 }
20
21 public void Initialise(ScriptInfo info)
22 {
23 scriptInfo = info;
24 }
25
26 public string getName()
27 {
28 return "LSL Script";
29 }
30 }
31}
diff --git a/OpenSim/Region/Environment/Scenes/scripting/Engines/LSLEngine/LSLScriptEngine.cs b/OpenSim/Region/Environment/Scenes/scripting/Engines/LSLEngine/LSLScriptEngine.cs
new file mode 100644
index 0000000..65f73dd
--- /dev/null
+++ b/OpenSim/Region/Environment/Scenes/scripting/Engines/LSLEngine/LSLScriptEngine.cs
@@ -0,0 +1,27 @@
1using System;
2using System.Collections.Generic;
3using System.Text;
4
5using OpenSim.Region.Scripting;
6using OpenSim.Region.Scripting.LSL;
7
8namespace OpenSim.Region.Scripting
9{
10 public class LSLEngine : IScriptCompiler
11 {
12 public string FileExt()
13 {
14 return ".lso";
15 }
16
17 public Dictionary<string, IScript> compile(string filename)
18 {
19 LSLScript script = new LSLScript(filename);
20 Dictionary<string, IScript> returns = new Dictionary<string, IScript>();
21
22 returns.Add(filename, script);
23
24 return returns;
25 }
26 }
27} \ No newline at end of file