<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.secondlife.com/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Tedd+Maa</id>
	<title>Second Life Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.secondlife.com/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Tedd+Maa"/>
	<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/wiki/Special:Contributions/Tedd_Maa"/>
	<updated>2026-07-28T05:11:40Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.42.1</generator>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=User_talk:Tedd_Maa/stand-alone_script_engine&amp;diff=35957</id>
		<title>User talk:Tedd Maa/stand-alone script engine</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=User_talk:Tedd_Maa/stand-alone_script_engine&amp;diff=35957"/>
		<updated>2007-10-16T19:54:11Z</updated>

		<summary type="html">&lt;p&gt;Tedd Maa: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;* Although this is interesting Tedd, it doesn&#039;t seem to keep in mind one very fundamental issue:  computations at the server end have limited scalability, relative to any of the pressure points on scaling, which all derive from population pressure in one way or another.  No matter how we partition computing resources server-side, there will always be a key computational workload there for physics etc, so in general there is only limited power left over for ambitious scripting.  While we&#039;d all like high-powered in-world scripting, that&#039;s just not going to happen as long as the only available computing horsepower for scripting is server-side.&lt;br /&gt;
&lt;br /&gt;
* Although it&#039;s not going to happen for a long time, relatively unlimited scripting power is ultimately going to have to come by harnessing the clients, through server-side orchestration of partitioned tasks distributed very dynamically across all connected participants.  This is the &#039;&#039;&#039;only&#039;&#039;&#039; source of computing power that both scales with population and offers massive resource per leaf node.  What&#039;s more, with multicore CPUs everywhere (and with very little work for them to do because desktop apps tend not to be structured for parallelism), this is one resource that has a very bright future.&lt;br /&gt;
&lt;br /&gt;
* So, while you offer some interesting things to think about here, if you want to look ahead to a future of high-powered server-side scripting, you really need to think about workload offloading too.  (That&#039;s still &amp;quot;server-side scripting&amp;quot;, even though the computations are distributed and run client-side, because such computations can never under any circumstances affect the client state;  &amp;quot;client-side scripting&amp;quot; is a different matter altogether.) --[[User:Morgaine Dinova|Morgaine Dinova]] 04:18, 15 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
[[User:Tedd Maa|Tedd Maa]]: In reply to the points by Morgaine.&lt;br /&gt;
&lt;br /&gt;
* There are limitations on the server side, yes. But this does not mean we should purposely design the scripting system in a bad way. It is up to the server itself to scale physics well. But the script engine is not limited to controlling physical objects. It can be clouds, smoke or even gameplay rules that don&#039;t even exist as an object in the world.&lt;br /&gt;
&lt;br /&gt;
* The whole point of this design is to be able to run scripts from anywhere. For example from the client. But running it from the client breaks persistency in the world. When user logs off, objects disappear. So I imagine people who want to run their own script engine having a shell somewhere like we did back in the 90&#039;s with good old bots and bouncers on IRC. But your script can very well be bound to a script engine embedded in your SL viewer for example, no problem. The region server doesn&#039;t need to discriminate on who is running the script server if server admin doesn&#039;t want it to.&lt;br /&gt;
&lt;br /&gt;
* It is still &#039;&#039;called&#039;&#039; server-side scripting. But one single script (or multiple scripts) can be any program in any programming language running on any number of computers on any number of different operating systems and CPUs anywhere in the world. As long as the region has only ONE endpoint to speak to it does not discriminate on implementation, operating system, number of computers involved in computation, etc. This is the whole essence of my plan. I will look through the document and see if maybe I didn&#039;t communicate that clearly enough. Its still just a first draft.&lt;br /&gt;
&lt;br /&gt;
[[User:Tedd Maa|Tedd Maa]] 20071015 16:40 UTC/GMT+1&lt;br /&gt;
&lt;br /&gt;
== Object Orientated Program Environment ==&lt;br /&gt;
&lt;br /&gt;
Most traditional OOP languages fall short of the object orientated design. That is they call themselves a object-oriented program language, but they are not much of a object orientated approach outside of the language itself. Notice how I use &amp;quot;oriented&amp;quot; and &amp;quot;orientated.&amp;quot; One leans towards the paradigm from the outside and the other is centered in the entire paradigm and works outward. At first glance of the your plan I heard a familiar tune, and it matches with the object-oriented program languages. Such languages have been quite a step in the industry, but they have been pushed out to market before their maturity.&lt;br /&gt;
&lt;br /&gt;
As you can see from my post about &amp;quot;[[User:Dzonatas Sol|Client Script &amp;amp; Persistent Data Object]],&amp;quot; one of the ideas here is similar. In fact, the entire concept you have presented so far can be summed up underneath paravirtual machines. On that point, to call this &amp;quot;Tedds stand-alone script engine&amp;quot; may do some injustice to those who might want to contribute to the development of this project.&lt;br /&gt;
&lt;br /&gt;
Another point, the security has to go much deeper than what I see talked about in the article. To offset the execute state to a different physical area is not enough, for example. We need to be able to run arbitrary code in arbitrary locations.&lt;br /&gt;
&lt;br /&gt;
I stay focused on the object-orientated environments, and I hope you follow if you continue such motives to rewrite the engine. [[User:Dzonatas Sol|Dzonatas Sol]] 12:31, 15 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
good point on the &amp;quot;Tedds stand-alone script engine&amp;quot; - wasn&#039;t meant to name it at all, was meant as &amp;quot;Tedds proposal on ...&amp;quot; or &amp;quot;Tedds discussion on ...&amp;quot;. I will fix that in next revision (hopefully coming in a couple of days).&lt;br /&gt;
&lt;br /&gt;
Security is something I&#039;m still thinking about. I&#039;ll try to get something more about that into next revision.&lt;br /&gt;
(security always comes first, so it will probably dictate some of the details in the design)&lt;br /&gt;
&lt;br /&gt;
[[User:Tedd Maa|Tedd Maa]] 20071016 21:50 UTC/GMT+1&lt;/div&gt;</summary>
		<author><name>Tedd Maa</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=User:Tedd_Maa/stand-alone_script_engine&amp;diff=35794</id>
		<title>User:Tedd Maa/stand-alone script engine</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=User:Tedd_Maa/stand-alone_script_engine&amp;diff=35794"/>
		<updated>2007-10-15T19:11:55Z</updated>

		<summary type="html">&lt;p&gt;Tedd Maa: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Version 1: 20071014 (14th October 2007)&lt;br /&gt;
By: [[User:Tedd Maa|Tedd Maa]]&lt;br /&gt;
&lt;br /&gt;
=Intro=&lt;br /&gt;
In this document I try to argue what I think is the best way to go in script engine implementation.&lt;br /&gt;
&lt;br /&gt;
Blog for my OpenSim script engine development: [http://teddmaa.blogspot.com/ http://teddmaa.blogspot.com/]&lt;br /&gt;
&lt;br /&gt;
=Current script support=&lt;br /&gt;
==Implementation==&lt;br /&gt;
Current script support is in LSL2, a proprietary language with syntax similar to C#. It compiles down to a 16KB byte code that is executed on the server. Execution is done fully within that 16KB file, including stack and heap. This enables servers to easily move script between them during runtime. Because of the 16KB limit scripts can not be very large.&lt;br /&gt;
&lt;br /&gt;
There is no inter process communication (communication between scripts) except public chat channels or HTTP requests to a common HTTP server. One or more scripts are put into objects, and run individually. Execution is known to be slow. Scripts are executed locally on each region where the script is running.&lt;br /&gt;
&lt;br /&gt;
==Language==&lt;br /&gt;
The LSL2 script language consists of about 16 events and 360+ functions. The 16 events are triggers from server or from the script engine. The functions are normal functions like math/string manipulation and world manipulation. LSL2 language also has relatively advanced support for single dimension array list manipulation.&lt;br /&gt;
&lt;br /&gt;
Linden Labs are planning to implement C# support through Mono. By doing this more programmers will be able to make applications, and the language syntax will be more consistent. Execution is also expected to be faster.&lt;br /&gt;
&lt;br /&gt;
=Future script support=&lt;br /&gt;
==Multiple server implementations==&lt;br /&gt;
Decentralized architecture and standardization of communication protocol will spawn many different server implementations and areas of use. Scripts must be able to run on different CPU’s and operating systems. This poses a problem when a script can be moved between regions while it is executing. For that we either need a common byte code that can run on all operating systems. Most likely without JIT (Just In Time) compile to be compatible with the stack position during transfer – or a script parser execution model.&lt;br /&gt;
&lt;br /&gt;
==Various use==&lt;br /&gt;
Currently scripts are used mainly to control objects. Because of their limitation they perform small limited functions, and only a few scripts can said to contain any complexity.&lt;br /&gt;
In the future I would like to see more advanced scripts.&lt;br /&gt;
&lt;br /&gt;
If the limitations of scripts are removed one could develop highly complex scripts like artificial life, advanced procedural generators, environment controls, and even complex game engines that fully control all the rules of the world.&lt;br /&gt;
&lt;br /&gt;
It would of course be up to the server administrator to limit the script engine and user scripts. But a script engine should not only mean “user scripts”. Server administrators should be able to write their own complex engines that control any element of the world. It should for example be possible to write script engines that create rules like Word of Warcraft, Eve Online, etc. It should even be possible to have a cluster of supercomputers running behind a single script, region or grid.&lt;br /&gt;
Language support&lt;br /&gt;
We do not want to limit the language support. People should be able to use any language, for example .Net languages, Java, C/C++ and Perl. Just like CGI scripts for web pages, the language that controls the content should not affect the presentation.&lt;br /&gt;
&lt;br /&gt;
Multitasking between many scripts is a problem that needs to be handled on per script engine basis, at least in the nearest foreseeable future. If a region wants to run 10.000 .Net scripts, it is up to the script engine for .Net to do micro threading on these.&lt;br /&gt;
&lt;br /&gt;
==Security==&lt;br /&gt;
Security in this case is a two way street. Script creators may want to protect intellectual property of your script (source code), encryption algorithms, passwords in code, access to HTTP or SQL servers, etc. Even though code might be using security through obscurity, in some cases it is more than good enough. And server administrators don’t really want foreign code running on their server.&lt;br /&gt;
&lt;br /&gt;
As pointed out earlier in this document crossing region borders with the wide language support we want will be difficult. Even if it was possible it would mean that the server you were crossing into had to support your specific language. This in turn means that every script engine for every language supported needs to be 100% secure. And implementations would probably be “Allow everything then try to remove security holes”. Not something you want running on your server. The whole concept of letting anyone run a script on your server is wrong from a security perspective.&lt;br /&gt;
&lt;br /&gt;
==New architecture==&lt;br /&gt;
Today script execution in SL is implemented into the region where the script exists. I propose adding a separate stand alone script engine to the architecture. &lt;br /&gt;
&lt;br /&gt;
Whenever a script is introduced into a region, the region contacts a script server. The IP of the script engine can be determined either by default script engine for that region, user specific script engine or object/script specific script server. It may be necessary for the script to only exist on the script server and the object to contain a script reference. This way one can sell or rent scripts like virtual pets and still keep the source a secret.&lt;br /&gt;
&lt;br /&gt;
Script commands that require manipulation of the world will be sent from remote script server to the region. Events from world to the object will be sent from the region to the script server. Only one connection is necessary from a region to a specific script server regardless of number of scripts (one connection can serve many scripts).&lt;br /&gt;
&lt;br /&gt;
For communication I propose using a custom binary protocol that contains name of function and a dynamic number of parameters of dynamic type. If a command needs reply it should contain an ID that will be used for reply (async). This way the script server and region server can have a continuous flow of function calls going in both directions.&lt;br /&gt;
&lt;br /&gt;
The basic set of commands supported on the script server should be LSL commands. Not all are required though. Some are better suited to be executed inside the script server. For example timers, mathematical functions, string/list manipulation, etc. But the protocol should not be limited to LSL commands only.&lt;br /&gt;
&lt;br /&gt;
The protocol should have versioning and/or some sort of capability implementation. This way server scripting support can be extended by modules on the region server, and remote script servers can utilize implementation specific functionality on region server.&lt;br /&gt;
&lt;br /&gt;
A permission system for remote scripts should also be implemented so that script servers can for example get God-like access to the region server and therefore control more aspects of the world than a single script could.&lt;br /&gt;
&lt;br /&gt;
==OpenSim implementation==&lt;br /&gt;
Originally script support in OpenSim was implemented to run scripts locally. Support for dynamically loading script engines. The same support will be extended to support stand alone remote servers, and the remote servers will be able to load the same .Net modules as OpenSim can locally.&lt;/div&gt;</summary>
		<author><name>Tedd Maa</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=User:Tedd_Maa&amp;diff=35762</id>
		<title>User:Tedd Maa</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=User:Tedd_Maa&amp;diff=35762"/>
		<updated>2007-10-15T15:52:26Z</updated>

		<summary type="html">&lt;p&gt;Tedd Maa: New page: =About me= My name is Tedd Hansen, my SL cyberego is Tedd Maa.  I am 27 years old, live in Oslo, Norway. I run my own little company with programming related project management. I have bee...&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=About me=&lt;br /&gt;
My name is Tedd Hansen, my SL cyberego is Tedd Maa.&lt;br /&gt;
&lt;br /&gt;
I am 27 years old, live in Oslo, Norway. I run my own little company with programming related project management. I have been programming since forever (age 7 or so). &lt;br /&gt;
&lt;br /&gt;
=OpenSim=&lt;br /&gt;
I am working on the OpenSim project ([http://www.opensimulator.org/ http://www.opensimulator.org/]) with main focus on programming the script engine. The OpenSim project is a BSD licensed Second Life server being developed by volunteers around the world.&lt;br /&gt;
&lt;br /&gt;
I have through the OpenSim project been working with script engine implementation for some time. From the initial script engine where I did LSL byte code to .Net CIL (.Net assembly language) converting, compiling and execution, to the current one compiling LSL text scripts to .Net assemblies (.dll). &lt;br /&gt;
&lt;br /&gt;
=Interests=&lt;br /&gt;
My interests span from any nerds wet dream of robotics and AI to algorithms. My hobby for the past 15 or so years has been mainly programming, every day. With focus on algorithms suchs as early 3D (like Doom 1 &amp;amp; 2), communication protocols, compression, search, file systems, operative system kernels, etc. I enjoy a good challenge.&lt;br /&gt;
&lt;br /&gt;
=Plans for SL=&lt;br /&gt;
Mostly for fun. I believe this technology has the potential and is in the right time and place for it to happen. It just needs a major rewrite. It has a big untapped commercial potential, and I think in the coming years it will position itself in the market in ways we can not imagine now. A few will imagine it in time and make good money from it, most will just follow them. Same old story.&lt;br /&gt;
&lt;br /&gt;
I hope SL will be THE place for artificial life experiments, and that we can all experiment on the same piece land. http://www.alifegrid.com/&lt;/div&gt;</summary>
		<author><name>Tedd Maa</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=User_talk:Tedd_Maa/stand-alone_script_engine&amp;diff=35741</id>
		<title>User talk:Tedd Maa/stand-alone script engine</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=User_talk:Tedd_Maa/stand-alone_script_engine&amp;diff=35741"/>
		<updated>2007-10-15T14:39:38Z</updated>

		<summary type="html">&lt;p&gt;Tedd Maa: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;* Although this is interesting Tedd, it doesn&#039;t seem to keep in mind one very fundamental issue:  computations at the server end have limited scalability, relative to any of the pressure points on scaling, which all derive from population pressure in one way or another.  No matter how we partition computing resources server-side, there will always be a key computational workload there for physics etc, so in general there is only limited power left over for ambitious scripting.  While we&#039;d all like high-powered in-world scripting, that&#039;s just not going to happen as long as the only available computing horsepower for scripting is server-side.&lt;br /&gt;
&lt;br /&gt;
* Although it&#039;s not going to happen for a long time, relatively unlimited scripting power is ultimately going to have to come by harnessing the clients, through server-side orchestration of partitioned tasks distributed very dynamically across all connected participants.  This is the &#039;&#039;&#039;only&#039;&#039;&#039; source of computing power that both scales with population and offers massive resource per leaf node.  What&#039;s more, with multicore CPUs everywhere (and with very little work for them to do because desktop apps tend not to be structured for parallelism), this is one resource that has a very bright future.&lt;br /&gt;
&lt;br /&gt;
* So, while you offer some interesting things to think about here, if you want to look ahead to a future of high-powered server-side scripting, you really need to think about workload offloading too.  (That&#039;s still &amp;quot;server-side scripting&amp;quot;, even though the computations are distributed and run client-side, because such computations can never under any circumstances affect the client state;  &amp;quot;client-side scripting&amp;quot; is a different matter altogether.) --[[User:Morgaine Dinova|Morgaine Dinova]] 04:18, 15 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
[[User:Tedd Maa|Tedd Maa]]: In reply to the points by Morgaine.&lt;br /&gt;
&lt;br /&gt;
* There are limitations on the server side, yes. But this does not mean we should purposely design the scripting system in a bad way. It is up to the server itself to scale physics well. But the script engine is not limited to controlling physical objects. It can be clouds, smoke or even gameplay rules that don&#039;t even exist as an object in the world.&lt;br /&gt;
&lt;br /&gt;
* The whole point of this design is to be able to run scripts from anywhere. For example from the client. But running it from the client breaks persistency in the world. When user logs off, objects disappear. So I imagine people who want to run their own script engine having a shell somewhere like we did back in the 90&#039;s with good old bots and bouncers on IRC. But your script can very well be bound to a script engine embedded in your SL viewer for example, no problem. The region server doesn&#039;t need to discriminate on who is running the script server if server admin doesn&#039;t want it to.&lt;br /&gt;
&lt;br /&gt;
* It is still &#039;&#039;called&#039;&#039; server-side scripting. But one single script (or multiple scripts) can be any program in any programming language running on any number of computers on any number of different operating systems and CPUs anywhere in the world. As long as the region has only ONE endpoint to speak to it does not discriminate on implementation, operating system, number of computers involved in computation, etc. This is the whole essence of my plan. I will look through the document and see if maybe I didn&#039;t communicate that clearly enough. Its still just a first draft.&lt;br /&gt;
&lt;br /&gt;
[[User:Tedd Maa|Tedd Maa]] 20071015 16:40 UTC/GMT+1&lt;/div&gt;</summary>
		<author><name>Tedd Maa</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=User_talk:Tedd_Maa/stand-alone_script_engine&amp;diff=35740</id>
		<title>User talk:Tedd Maa/stand-alone script engine</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=User_talk:Tedd_Maa/stand-alone_script_engine&amp;diff=35740"/>
		<updated>2007-10-15T14:34:52Z</updated>

		<summary type="html">&lt;p&gt;Tedd Maa: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;* Although this is interesting Tedd, it doesn&#039;t seem to keep in mind one very fundamental issue:  computations at the server end have limited scalability, relative to any of the pressure points on scaling, which all derive from population pressure in one way or another.  No matter how we partition computing resources server-side, there will always be a key computational workload there for physics etc, so in general there is only limited power left over for ambitious scripting.  While we&#039;d all like high-powered in-world scripting, that&#039;s just not going to happen as long as the only available computing horsepower for scripting is server-side.&lt;br /&gt;
&lt;br /&gt;
* Although it&#039;s not going to happen for a long time, relatively unlimited scripting power is ultimately going to have to come by harnessing the clients, through server-side orchestration of partitioned tasks distributed very dynamically across all connected participants.  This is the &#039;&#039;&#039;only&#039;&#039;&#039; source of computing power that both scales with population and offers massive resource per leaf node.  What&#039;s more, with multicore CPUs everywhere (and with very little work for them to do because desktop apps tend not to be structured for parallelism), this is one resource that has a very bright future.&lt;br /&gt;
&lt;br /&gt;
* So, while you offer some interesting things to think about here, if you want to look ahead to a future of high-powered server-side scripting, you really need to think about workload offloading too.  (That&#039;s still &amp;quot;server-side scripting&amp;quot;, even though the computations are distributed and run client-side, because such computations can never under any circumstances affect the client state;  &amp;quot;client-side scripting&amp;quot; is a different matter altogether.) --[[User:Morgaine Dinova|Morgaine Dinova]] 04:18, 15 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
In reply to the points by Morgaine.&lt;br /&gt;
&lt;br /&gt;
* There are limitations on the server side, yes. But this does not mean we should purposely design the scripting system in a bad way. It is up to the server itself to scale physics well. But the script engine is not limited to controlling physical objects. It can be clouds, smoke or even gameplay rules that don&#039;t even exist as an object in the world.&lt;br /&gt;
&lt;br /&gt;
* The whole point of this design is to be able to run scripts from anywhere. For example from the client. But running it from the client breaks persistency in the world. When user logs off, objects disappear. So I imagine people who want to run their own script engine having a shell somewhere like we did back in the 90&#039;s with good old bots and bouncers on IRC. But your script can very well be bound to a script engine embedded in your SL viewer for example, no problem. The region server doesn&#039;t need to discriminate on who is running the script server if server admin doesn&#039;t want it to.&lt;br /&gt;
&lt;br /&gt;
* It is still &#039;&#039;called&#039;&#039; server-side scripting. But one single script (or multiple scripts) can be any program in any programming language running on any number of computers on any number of different operating systems and CPUs anywhere in the world. As long as the region has only ONE endpoint to speak to it does not discriminate on implementation, operating system, number of computers involved in computation, etc. This is the whole essence of my plan. I will look through the document and see if maybe I didn&#039;t communicate that clearly enough. Its still just a first draft.&lt;/div&gt;</summary>
		<author><name>Tedd Maa</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=User:Tedd_Maa/stand-alone_script_engine&amp;diff=35733</id>
		<title>User:Tedd Maa/stand-alone script engine</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=User:Tedd_Maa/stand-alone_script_engine&amp;diff=35733"/>
		<updated>2007-10-15T13:52:44Z</updated>

		<summary type="html">&lt;p&gt;Tedd Maa: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Version 1: 20071014 (14th October 2007)&lt;br /&gt;
&lt;br /&gt;
=Intro=&lt;br /&gt;
My name is Tedd Hansen, SL alias Tedd Maa. I am 27 years old, live in Oslo, Norway. I run my own company with programming related project management. I have been programming since forever (age 7 or so).&lt;br /&gt;
&lt;br /&gt;
I am working on the OpenSim project (http://www.opensimulator.org/) with main focus on programming the script engine. The OpenSim project is a BSD licensed Second Life server being developed by volunteers around the world. Many people are contributing.&lt;br /&gt;
&lt;br /&gt;
I have through the OpenSim project been working with script engine implementation for some time. From the initial script engine where I did LSL ByteCode to .Net CIL (.Net assembly language) converting, to the current compiling LSL scripts to .Net assemblies (.dll).&lt;br /&gt;
&lt;br /&gt;
In this document I try to argue what I think is the best way to go in script engine implementation.&lt;br /&gt;
&lt;br /&gt;
Blog for my OpenSim script engine development: [http://teddmaa.blogspot.com/ http://teddmaa.blogspot.com/]&lt;br /&gt;
&lt;br /&gt;
=Current script support=&lt;br /&gt;
==Implementation==&lt;br /&gt;
Current script support is in LSL2, a proprietary language with syntax similar to C#. It compiles down to a 16KB byte code that is executed on the server. Execution is done fully within that 16KB file, including stack and heap. This enables servers to easily move script between them during runtime. Because of the 16KB limit scripts can not be very large.&lt;br /&gt;
&lt;br /&gt;
There is no inter process communication (communication between scripts) except public chat channels or HTTP requests to a common HTTP server. One or more scripts are put into objects, and run individually. Execution is known to be slow. Scripts are executed locally on each region where the script is running.&lt;br /&gt;
&lt;br /&gt;
==Language==&lt;br /&gt;
The LSL2 script language consists of about 16 events and 360+ functions. The 16 events are triggers from server or from the script engine. The functions are normal functions like math/string manipulation and world manipulation. LSL2 language also has relatively advanced support for single dimension array list manipulation.&lt;br /&gt;
&lt;br /&gt;
Linden Labs are planning to implement C# support through Mono. By doing this more programmers will be able to make applications, and the language syntax will be more consistent. Execution is also expected to be faster.&lt;br /&gt;
&lt;br /&gt;
=Future script support=&lt;br /&gt;
==Multiple server implementations==&lt;br /&gt;
Decentralized architecture and standardization of communication protocol will spawn many different server implementations and areas of use. Scripts must be able to run on different CPU’s and operating systems. This poses a problem when a script can be moved between regions while it is executing. For that we either need a common byte code that can run on all operating systems. Most likely without JIT (Just In Time) compile to be compatible with the stack position during transfer – or a script parser execution model.&lt;br /&gt;
&lt;br /&gt;
==Various use==&lt;br /&gt;
Currently scripts are used mainly to control objects. Because of their limitation they perform small limited functions, and only a few scripts can said to contain any complexity.&lt;br /&gt;
In the future I would like to see more advanced scripts.&lt;br /&gt;
&lt;br /&gt;
If the limitations of scripts are removed one could develop highly complex scripts like artificial life, advanced procedural generators, environment controls, and even complex game engines that fully control all the rules of the world.&lt;br /&gt;
&lt;br /&gt;
It would of course be up to the server administrator to limit the script engine and user scripts. But a script engine should not only mean “user scripts”. Server administrators should be able to write their own complex engines that control any element of the world. It should for example be possible to write script engines that create rules like Word of Warcraft, Eve Online, etc. It should even be possible to have a cluster of supercomputers running behind a single script, region or grid.&lt;br /&gt;
Language support&lt;br /&gt;
We do not want to limit the language support. People should be able to use any language, for example .Net languages, Java, C/C++ and Perl. Just like CGI scripts for web pages, the language that controls the content should not affect the presentation.&lt;br /&gt;
&lt;br /&gt;
Multitasking between many scripts is a problem that needs to be handled on per script engine basis, at least in the nearest foreseeable future. If a region wants to run 10.000 .Net scripts, it is up to the script engine for .Net to do micro threading on these.&lt;br /&gt;
&lt;br /&gt;
==Security==&lt;br /&gt;
Security in this case is a two way street. Script creators may want to protect intellectual property of your script (source code), encryption algorithms, passwords in code, access to HTTP or SQL servers, etc. Even though code might be using security through obscurity, in some cases it is more than good enough. And server administrators don’t really want foreign code running on their server.&lt;br /&gt;
&lt;br /&gt;
As pointed out earlier in this document crossing region borders with the wide language support we want will be difficult. Even if it was possible it would mean that the server you were crossing into had to support your specific language. This in turn means that every script engine for every language supported needs to be 100% secure. And implementations would probably be “Allow everything then try to remove security holes”. Not something you want running on your server. The whole concept of letting anyone run a script on your server is wrong from a security perspective.&lt;br /&gt;
&lt;br /&gt;
==New architecture==&lt;br /&gt;
Today script execution in SL is implemented into the region where the script exists. I propose adding a separate stand alone script engine to the architecture. &lt;br /&gt;
&lt;br /&gt;
Whenever a script is introduced into a region, the region contacts a script server. The IP of the script engine can be determined either by default script engine for that region, user specific script engine or object/script specific script server. It may be necessary for the script to only exist on the script server and the object to contain a script reference. This way one can sell or rent scripts like virtual pets and still keep the source a secret.&lt;br /&gt;
&lt;br /&gt;
Script commands that require manipulation of the world will be sent from remote script server to the region. Events from world to the object will be sent from the region to the script server. Only one connection is necessary from a region to a specific script server regardless of number of scripts (one connection can serve many scripts).&lt;br /&gt;
&lt;br /&gt;
For communication I propose using a custom binary protocol that contains name of function and a dynamic number of parameters of dynamic type. If a command needs reply it should contain an ID that will be used for reply (async). This way the script server and region server can have a continuous flow of function calls going in both directions.&lt;br /&gt;
&lt;br /&gt;
The basic set of commands supported on the script server should be LSL commands. Not all are required though. Some are better suited to be executed inside the script server. For example timers, mathematical functions, string/list manipulation, etc. But the protocol should not be limited to LSL commands only.&lt;br /&gt;
&lt;br /&gt;
The protocol should have versioning and/or some sort of capability implementation. This way server scripting support can be extended by modules on the region server, and remote script servers can utilize implementation specific functionality on region server.&lt;br /&gt;
&lt;br /&gt;
A permission system for remote scripts should also be implemented so that script servers can for example get God-like access to the region server and therefore control more aspects of the world than a single script could.&lt;br /&gt;
&lt;br /&gt;
==OpenSim implementation==&lt;br /&gt;
Originally script support in OpenSim was implemented to run scripts locally. Support for dynamically loading script engines. The same support will be extended to support stand alone remote servers, and the remote servers will be able to load the same .Net modules as OpenSim can locally.&lt;/div&gt;</summary>
		<author><name>Tedd Maa</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=User:Tedd_Maa/stand-alone_script_engine&amp;diff=35640</id>
		<title>User:Tedd Maa/stand-alone script engine</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=User:Tedd_Maa/stand-alone_script_engine&amp;diff=35640"/>
		<updated>2007-10-14T21:02:21Z</updated>

		<summary type="html">&lt;p&gt;Tedd Maa: /* Intro */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Intro=&lt;br /&gt;
My name is Tedd Hansen, SL alias Tedd Maa. I am 27 years old, live in Oslo, Norway. I run my own company with programming related project management. I have been programming since forever (age 7 or so).&lt;br /&gt;
&lt;br /&gt;
I am working on the OpenSim project (http://www.opensimulator.org/) with main focus on programming the script engine. The OpenSim project is a BSD licensed Second Life server being developed by volunteers around the world. Many people are contributing.&lt;br /&gt;
&lt;br /&gt;
I have through the OpenSim project been working with script engine implementation for some time. From the initial script engine where I did LSL ByteCode to .Net CIL (.Net assembly language) converting, to the current compiling LSL scripts to .Net assemblies (.dll).&lt;br /&gt;
&lt;br /&gt;
In this document I try to argue what I think is the best way to go in script engine implementation.&lt;br /&gt;
&lt;br /&gt;
Blog for my OpenSim script engine development: [http://teddmaa.blogspot.com/ http://teddmaa.blogspot.com/]&lt;br /&gt;
&lt;br /&gt;
=Current script support=&lt;br /&gt;
==Implementation==&lt;br /&gt;
Current script support is in LSL2, a proprietary language with syntax similar to C#. It compiles down to a 16KB byte code that is executed on the server. Execution is done fully within that 16KB file, including stack and heap. This enables servers to easily move script between them during runtime. Because of the 16KB limit scripts can not be very large.&lt;br /&gt;
&lt;br /&gt;
There is no inter process communication (communication between scripts) except public chat channels or HTTP requests to a common HTTP server. One or more scripts are put into objects, and run individually. Execution is known to be slow. Scripts are executed locally on each region where the script is running.&lt;br /&gt;
&lt;br /&gt;
==Language==&lt;br /&gt;
The LSL2 script language consists of about 16 events and 360+ functions. The 16 events are triggers from server or from the script engine. The functions are normal functions like math/string manipulation and world manipulation. LSL2 language also has relatively advanced support for single dimension array list manipulation.&lt;br /&gt;
&lt;br /&gt;
Linden Labs are planning to implement C# support through Mono. By doing this more programmers will be able to make applications, and the language syntax will be more consistent. Execution is also expected to be faster.&lt;br /&gt;
&lt;br /&gt;
=Future script support=&lt;br /&gt;
==Multiple server implementations==&lt;br /&gt;
Decentralized architecture and standardization of communication protocol will spawn many different server implementations and areas of use. Scripts must be able to run on different CPU’s and operating systems. This poses a problem when a script can be moved between regions while it is executing. For that we either need a common byte code that can run on all operating systems. Most likely without JIT (Just In Time) compile to be compatible with the stack position during transfer – or a script parser execution model.&lt;br /&gt;
&lt;br /&gt;
==Various use==&lt;br /&gt;
Currently scripts are used mainly to control objects. Because of their limitation they perform small limited functions, and only a few scripts can said to contain any complexity.&lt;br /&gt;
In the future I would like to see more advanced scripts.&lt;br /&gt;
&lt;br /&gt;
If the limitations of scripts are removed one could develop highly complex scripts like artificial life, advanced procedural generators, environment controls, and even complex game engines that fully control all the rules of the world.&lt;br /&gt;
&lt;br /&gt;
It would of course be up to the server administrator to limit the script engine and user scripts. But a script engine should not only mean “user scripts”. Server administrators should be able to write their own complex engines that control any element of the world. It should for example be possible to write script engines that create rules like Word of Warcraft, Eve Online, etc. It should even be possible to have a cluster of supercomputers running behind a single script, region or grid.&lt;br /&gt;
Language support&lt;br /&gt;
We do not want to limit the language support. People should be able to use any language, for example .Net languages, Java, C/C++ and Perl. Just like CGI scripts for web pages, the language that controls the content should not affect the presentation.&lt;br /&gt;
&lt;br /&gt;
Multitasking between many scripts is a problem that needs to be handled on per script engine basis, at least in the nearest foreseeable future. If a region wants to run 10.000 .Net scripts, it is up to the script engine for .Net to do micro threading on these.&lt;br /&gt;
&lt;br /&gt;
==Security==&lt;br /&gt;
Security in this case is a two way street. Script creators may want to protect intellectual property of your script (source code), encryption algorithms, passwords in code, access to HTTP or SQL servers, etc. Even though code might be using security through obscurity, in some cases it is more than good enough. And server administrators don’t really want foreign code running on their server.&lt;br /&gt;
&lt;br /&gt;
As pointed out earlier in this document crossing region borders with the wide language support we want will be difficult. Even if it was possible it would mean that the server you were crossing into had to support your specific language. This in turn means that every script engine for every language supported needs to be 100% secure. And implementations would probably be “Allow everything then try to remove security holes”. Not something you want running on your server. The whole concept of letting anyone run a script on your server is wrong from a security perspective.&lt;br /&gt;
&lt;br /&gt;
==New architecture==&lt;br /&gt;
Today script execution in SL is implemented into the region where the script exists. I propose adding a separate stand alone script engine to the architecture. &lt;br /&gt;
&lt;br /&gt;
Whenever a script is introduced into a region, the region contacts a script server. The IP of the script engine can be determined either by default script engine for that region, user specific script engine or object/script specific script server. It may be necessary for the script to only exist on the script server and the object to contain a script reference. This way one can sell or rent scripts like virtual pets and still keep the source a secret.&lt;br /&gt;
&lt;br /&gt;
Script commands that require manipulation of the world will be sent from remote script server to the region. Events from world to the object will be sent from the region to the script server. Only one connection is necessary from a region to a specific script server regardless of number of scripts (one connection can serve many scripts).&lt;br /&gt;
&lt;br /&gt;
For communication I propose using a custom binary protocol that contains name of function and a dynamic number of parameters of dynamic type. If a command needs reply it should contain an ID that will be used for reply (async). This way the script server and region server can have a continuous flow of function calls going in both directions.&lt;br /&gt;
&lt;br /&gt;
The basic set of commands supported on the script server should be LSL commands. Not all are required though. Some are better suited to be executed inside the script server. For example timers, mathematical functions, string/list manipulation, etc. But the protocol should not be limited to LSL commands only.&lt;br /&gt;
&lt;br /&gt;
The protocol should have versioning and/or some sort of capability implementation. This way server scripting support can be extended by modules on the region server, and remote script servers can utilize implementation specific functionality on region server.&lt;br /&gt;
&lt;br /&gt;
A permission system for remote scripts should also be implemented so that script servers can for example get God-like access to the region server and therefore control more aspects of the world than a single script could.&lt;br /&gt;
&lt;br /&gt;
==OpenSim implementation==&lt;br /&gt;
Originally script support in OpenSim was implemented to run scripts locally. Support for dynamically loading script engines. The same support will be extended to support stand alone remote servers, and the remote servers will be able to load the same .Net modules as OpenSim can locally.&lt;/div&gt;</summary>
		<author><name>Tedd Maa</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=User:Tedd_Maa/stand-alone_script_engine&amp;diff=35639</id>
		<title>User:Tedd Maa/stand-alone script engine</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=User:Tedd_Maa/stand-alone_script_engine&amp;diff=35639"/>
		<updated>2007-10-14T21:02:03Z</updated>

		<summary type="html">&lt;p&gt;Tedd Maa: /* Intro */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Intro=&lt;br /&gt;
My name is Tedd Hansen, SL alias Tedd Maa. I am 27 years old, live in Oslo, Norway. I run my own company with programming related project management. I have been programming since forever (age 7 or so).&lt;br /&gt;
&lt;br /&gt;
I am working on the OpenSim project (http://www.opensimulator.org/) with main focus on programming the script engine. The OpenSim project is a BSD licensed Second Life server being developed by volunteers around the world. Many people are contributing.&lt;br /&gt;
&lt;br /&gt;
I have through the OpenSim project been working with script engine implementation for some time. From the initial script engine where I did LSL ByteCode to .Net CIL (.Net assembly language) converting, to the current compiling LSL scripts to .Net assemblies (.dll).&lt;br /&gt;
&lt;br /&gt;
In this document I try to argue what I think is the best way to go in script engine implementation.&lt;br /&gt;
&lt;br /&gt;
Blog for my OpenSim script engine development: [http://teddmaa.blogspot.com/|http://teddmaa.blogspot.com/]&lt;br /&gt;
&lt;br /&gt;
=Current script support=&lt;br /&gt;
==Implementation==&lt;br /&gt;
Current script support is in LSL2, a proprietary language with syntax similar to C#. It compiles down to a 16KB byte code that is executed on the server. Execution is done fully within that 16KB file, including stack and heap. This enables servers to easily move script between them during runtime. Because of the 16KB limit scripts can not be very large.&lt;br /&gt;
&lt;br /&gt;
There is no inter process communication (communication between scripts) except public chat channels or HTTP requests to a common HTTP server. One or more scripts are put into objects, and run individually. Execution is known to be slow. Scripts are executed locally on each region where the script is running.&lt;br /&gt;
&lt;br /&gt;
==Language==&lt;br /&gt;
The LSL2 script language consists of about 16 events and 360+ functions. The 16 events are triggers from server or from the script engine. The functions are normal functions like math/string manipulation and world manipulation. LSL2 language also has relatively advanced support for single dimension array list manipulation.&lt;br /&gt;
&lt;br /&gt;
Linden Labs are planning to implement C# support through Mono. By doing this more programmers will be able to make applications, and the language syntax will be more consistent. Execution is also expected to be faster.&lt;br /&gt;
&lt;br /&gt;
=Future script support=&lt;br /&gt;
==Multiple server implementations==&lt;br /&gt;
Decentralized architecture and standardization of communication protocol will spawn many different server implementations and areas of use. Scripts must be able to run on different CPU’s and operating systems. This poses a problem when a script can be moved between regions while it is executing. For that we either need a common byte code that can run on all operating systems. Most likely without JIT (Just In Time) compile to be compatible with the stack position during transfer – or a script parser execution model.&lt;br /&gt;
&lt;br /&gt;
==Various use==&lt;br /&gt;
Currently scripts are used mainly to control objects. Because of their limitation they perform small limited functions, and only a few scripts can said to contain any complexity.&lt;br /&gt;
In the future I would like to see more advanced scripts.&lt;br /&gt;
&lt;br /&gt;
If the limitations of scripts are removed one could develop highly complex scripts like artificial life, advanced procedural generators, environment controls, and even complex game engines that fully control all the rules of the world.&lt;br /&gt;
&lt;br /&gt;
It would of course be up to the server administrator to limit the script engine and user scripts. But a script engine should not only mean “user scripts”. Server administrators should be able to write their own complex engines that control any element of the world. It should for example be possible to write script engines that create rules like Word of Warcraft, Eve Online, etc. It should even be possible to have a cluster of supercomputers running behind a single script, region or grid.&lt;br /&gt;
Language support&lt;br /&gt;
We do not want to limit the language support. People should be able to use any language, for example .Net languages, Java, C/C++ and Perl. Just like CGI scripts for web pages, the language that controls the content should not affect the presentation.&lt;br /&gt;
&lt;br /&gt;
Multitasking between many scripts is a problem that needs to be handled on per script engine basis, at least in the nearest foreseeable future. If a region wants to run 10.000 .Net scripts, it is up to the script engine for .Net to do micro threading on these.&lt;br /&gt;
&lt;br /&gt;
==Security==&lt;br /&gt;
Security in this case is a two way street. Script creators may want to protect intellectual property of your script (source code), encryption algorithms, passwords in code, access to HTTP or SQL servers, etc. Even though code might be using security through obscurity, in some cases it is more than good enough. And server administrators don’t really want foreign code running on their server.&lt;br /&gt;
&lt;br /&gt;
As pointed out earlier in this document crossing region borders with the wide language support we want will be difficult. Even if it was possible it would mean that the server you were crossing into had to support your specific language. This in turn means that every script engine for every language supported needs to be 100% secure. And implementations would probably be “Allow everything then try to remove security holes”. Not something you want running on your server. The whole concept of letting anyone run a script on your server is wrong from a security perspective.&lt;br /&gt;
&lt;br /&gt;
==New architecture==&lt;br /&gt;
Today script execution in SL is implemented into the region where the script exists. I propose adding a separate stand alone script engine to the architecture. &lt;br /&gt;
&lt;br /&gt;
Whenever a script is introduced into a region, the region contacts a script server. The IP of the script engine can be determined either by default script engine for that region, user specific script engine or object/script specific script server. It may be necessary for the script to only exist on the script server and the object to contain a script reference. This way one can sell or rent scripts like virtual pets and still keep the source a secret.&lt;br /&gt;
&lt;br /&gt;
Script commands that require manipulation of the world will be sent from remote script server to the region. Events from world to the object will be sent from the region to the script server. Only one connection is necessary from a region to a specific script server regardless of number of scripts (one connection can serve many scripts).&lt;br /&gt;
&lt;br /&gt;
For communication I propose using a custom binary protocol that contains name of function and a dynamic number of parameters of dynamic type. If a command needs reply it should contain an ID that will be used for reply (async). This way the script server and region server can have a continuous flow of function calls going in both directions.&lt;br /&gt;
&lt;br /&gt;
The basic set of commands supported on the script server should be LSL commands. Not all are required though. Some are better suited to be executed inside the script server. For example timers, mathematical functions, string/list manipulation, etc. But the protocol should not be limited to LSL commands only.&lt;br /&gt;
&lt;br /&gt;
The protocol should have versioning and/or some sort of capability implementation. This way server scripting support can be extended by modules on the region server, and remote script servers can utilize implementation specific functionality on region server.&lt;br /&gt;
&lt;br /&gt;
A permission system for remote scripts should also be implemented so that script servers can for example get God-like access to the region server and therefore control more aspects of the world than a single script could.&lt;br /&gt;
&lt;br /&gt;
==OpenSim implementation==&lt;br /&gt;
Originally script support in OpenSim was implemented to run scripts locally. Support for dynamically loading script engines. The same support will be extended to support stand alone remote servers, and the remote servers will be able to load the same .Net modules as OpenSim can locally.&lt;/div&gt;</summary>
		<author><name>Tedd Maa</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=User:Tedd_Maa/stand-alone_script_engine&amp;diff=35638</id>
		<title>User:Tedd Maa/stand-alone script engine</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=User:Tedd_Maa/stand-alone_script_engine&amp;diff=35638"/>
		<updated>2007-10-14T21:01:04Z</updated>

		<summary type="html">&lt;p&gt;Tedd Maa: New page: =Intro= My name is Tedd Hansen, SL alias Tedd Maa. I am 27 years old, live in Oslo, Norway. I run my own company with programming related project management. I have been programming since ...&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Intro=&lt;br /&gt;
My name is Tedd Hansen, SL alias Tedd Maa. I am 27 years old, live in Oslo, Norway. I run my own company with programming related project management. I have been programming since forever (age 7 or so).&lt;br /&gt;
&lt;br /&gt;
I am working on the OpenSim project (http://www.opensimulator.org/) with main focus on programming the script engine. The OpenSim project is a BSD licensed Second Life server being developed by volunteers around the world. Many people are contributing.&lt;br /&gt;
&lt;br /&gt;
I have through the OpenSim project been working with script engine implementation for some time. From the initial script engine where I did LSL ByteCode to .Net CIL (.Net assembly language) converting, to the current compiling LSL scripts to .Net assemblies (.dll).&lt;br /&gt;
&lt;br /&gt;
In this document I try to argue what I think is the best way to go in script engine implementation.&lt;br /&gt;
&lt;br /&gt;
Blog for my OpenSim script engine development: [http://teddmaa.blogspot.com/]&lt;br /&gt;
&lt;br /&gt;
=Current script support=&lt;br /&gt;
==Implementation==&lt;br /&gt;
Current script support is in LSL2, a proprietary language with syntax similar to C#. It compiles down to a 16KB byte code that is executed on the server. Execution is done fully within that 16KB file, including stack and heap. This enables servers to easily move script between them during runtime. Because of the 16KB limit scripts can not be very large.&lt;br /&gt;
&lt;br /&gt;
There is no inter process communication (communication between scripts) except public chat channels or HTTP requests to a common HTTP server. One or more scripts are put into objects, and run individually. Execution is known to be slow. Scripts are executed locally on each region where the script is running.&lt;br /&gt;
&lt;br /&gt;
==Language==&lt;br /&gt;
The LSL2 script language consists of about 16 events and 360+ functions. The 16 events are triggers from server or from the script engine. The functions are normal functions like math/string manipulation and world manipulation. LSL2 language also has relatively advanced support for single dimension array list manipulation.&lt;br /&gt;
&lt;br /&gt;
Linden Labs are planning to implement C# support through Mono. By doing this more programmers will be able to make applications, and the language syntax will be more consistent. Execution is also expected to be faster.&lt;br /&gt;
&lt;br /&gt;
=Future script support=&lt;br /&gt;
==Multiple server implementations==&lt;br /&gt;
Decentralized architecture and standardization of communication protocol will spawn many different server implementations and areas of use. Scripts must be able to run on different CPU’s and operating systems. This poses a problem when a script can be moved between regions while it is executing. For that we either need a common byte code that can run on all operating systems. Most likely without JIT (Just In Time) compile to be compatible with the stack position during transfer – or a script parser execution model.&lt;br /&gt;
&lt;br /&gt;
==Various use==&lt;br /&gt;
Currently scripts are used mainly to control objects. Because of their limitation they perform small limited functions, and only a few scripts can said to contain any complexity.&lt;br /&gt;
In the future I would like to see more advanced scripts.&lt;br /&gt;
&lt;br /&gt;
If the limitations of scripts are removed one could develop highly complex scripts like artificial life, advanced procedural generators, environment controls, and even complex game engines that fully control all the rules of the world.&lt;br /&gt;
&lt;br /&gt;
It would of course be up to the server administrator to limit the script engine and user scripts. But a script engine should not only mean “user scripts”. Server administrators should be able to write their own complex engines that control any element of the world. It should for example be possible to write script engines that create rules like Word of Warcraft, Eve Online, etc. It should even be possible to have a cluster of supercomputers running behind a single script, region or grid.&lt;br /&gt;
Language support&lt;br /&gt;
We do not want to limit the language support. People should be able to use any language, for example .Net languages, Java, C/C++ and Perl. Just like CGI scripts for web pages, the language that controls the content should not affect the presentation.&lt;br /&gt;
&lt;br /&gt;
Multitasking between many scripts is a problem that needs to be handled on per script engine basis, at least in the nearest foreseeable future. If a region wants to run 10.000 .Net scripts, it is up to the script engine for .Net to do micro threading on these.&lt;br /&gt;
&lt;br /&gt;
==Security==&lt;br /&gt;
Security in this case is a two way street. Script creators may want to protect intellectual property of your script (source code), encryption algorithms, passwords in code, access to HTTP or SQL servers, etc. Even though code might be using security through obscurity, in some cases it is more than good enough. And server administrators don’t really want foreign code running on their server.&lt;br /&gt;
&lt;br /&gt;
As pointed out earlier in this document crossing region borders with the wide language support we want will be difficult. Even if it was possible it would mean that the server you were crossing into had to support your specific language. This in turn means that every script engine for every language supported needs to be 100% secure. And implementations would probably be “Allow everything then try to remove security holes”. Not something you want running on your server. The whole concept of letting anyone run a script on your server is wrong from a security perspective.&lt;br /&gt;
&lt;br /&gt;
==New architecture==&lt;br /&gt;
Today script execution in SL is implemented into the region where the script exists. I propose adding a separate stand alone script engine to the architecture. &lt;br /&gt;
&lt;br /&gt;
Whenever a script is introduced into a region, the region contacts a script server. The IP of the script engine can be determined either by default script engine for that region, user specific script engine or object/script specific script server. It may be necessary for the script to only exist on the script server and the object to contain a script reference. This way one can sell or rent scripts like virtual pets and still keep the source a secret.&lt;br /&gt;
&lt;br /&gt;
Script commands that require manipulation of the world will be sent from remote script server to the region. Events from world to the object will be sent from the region to the script server. Only one connection is necessary from a region to a specific script server regardless of number of scripts (one connection can serve many scripts).&lt;br /&gt;
&lt;br /&gt;
For communication I propose using a custom binary protocol that contains name of function and a dynamic number of parameters of dynamic type. If a command needs reply it should contain an ID that will be used for reply (async). This way the script server and region server can have a continuous flow of function calls going in both directions.&lt;br /&gt;
&lt;br /&gt;
The basic set of commands supported on the script server should be LSL commands. Not all are required though. Some are better suited to be executed inside the script server. For example timers, mathematical functions, string/list manipulation, etc. But the protocol should not be limited to LSL commands only.&lt;br /&gt;
&lt;br /&gt;
The protocol should have versioning and/or some sort of capability implementation. This way server scripting support can be extended by modules on the region server, and remote script servers can utilize implementation specific functionality on region server.&lt;br /&gt;
&lt;br /&gt;
A permission system for remote scripts should also be implemented so that script servers can for example get God-like access to the region server and therefore control more aspects of the world than a single script could.&lt;br /&gt;
&lt;br /&gt;
==OpenSim implementation==&lt;br /&gt;
Originally script support in OpenSim was implemented to run scripts locally. Support for dynamically loading script engines. The same support will be extended to support stand alone remote servers, and the remote servers will be able to load the same .Net modules as OpenSim can locally.&lt;/div&gt;</summary>
		<author><name>Tedd Maa</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=Architecture_Working_Group&amp;diff=35635</id>
		<title>Architecture Working Group</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=Architecture_Working_Group&amp;diff=35635"/>
		<updated>2007-10-14T20:44:37Z</updated>

		<summary type="html">&lt;p&gt;Tedd Maa: /* Architecture Proposals */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Image:slarch.jpg]]&lt;br /&gt;
&lt;br /&gt;
    I have gathered my tools and my charts,&lt;br /&gt;
    My plans are finished and practical.&lt;br /&gt;
    I shall roll up my sleeves — make Second Life over. &lt;br /&gt;
&lt;br /&gt;
==Goal==&lt;br /&gt;
&lt;br /&gt;
Discuss, design and implement a scalable and open architecture for the future Second Life Grid.&lt;br /&gt;
&lt;br /&gt;
==Materials==&lt;br /&gt;
&lt;br /&gt;
* [[Project Motivation]]&lt;br /&gt;
* [[Architecture Working Group Glossary|Glossary]]&lt;br /&gt;
* [[Use Cases]]&lt;br /&gt;
* [[Brainstorming]]&lt;br /&gt;
* [[Scoping]]&lt;br /&gt;
* [[Viewpoint Advocacy Groups]] (proposal)&lt;br /&gt;
&lt;br /&gt;
==Architecture Proposals==&lt;br /&gt;
* [[Proposed Architecture|High Level Architecture proposed by Linden Lab]]&lt;br /&gt;
* [[Hyperplanes]]&lt;br /&gt;
* [[Stand-alone script engine|Tedds stand-alone script engine proposal]]&lt;br /&gt;
&lt;br /&gt;
== Participating ==&lt;br /&gt;
Membership in this group is open. Start contribution to the work, and you become a member. &lt;br /&gt;
* Contribute to the materials and documentation in this wiki --- a lot of material is being drafted and discussed in the [[AW Groupies]] section (also, see below).&lt;br /&gt;
* Join the [http://wiki.secondlife.com/wiki/SLDev sldev mailing list] and use tags like [ARCH] and [AWG] in the subject line.&lt;br /&gt;
* Meet with others for technical discussions: [[User:Zero Linden|Zero Linden&#039;s]] office hours, [[AW Groupies]].&lt;br /&gt;
&lt;br /&gt;
==Meetings==&lt;br /&gt;
Formal meetings will likely be held 3-4 times/year and located in Second Life to facilitate broad participation. Meetings will be coordinated on [[SLDev]]. Group members are encouraged to self-organize smaller meetings to move forward particular work areas and discuss hot topics as needed.&lt;br /&gt;
&lt;br /&gt;
* Meeting 1&lt;br /&gt;
** [[ArchWG_Mtg_1_Agenda|September 13th 2007, Meeting 1]] &lt;br /&gt;
** [[Workitems for Meeting 1]]&lt;br /&gt;
** [[2007-09-13 Arch WG Minutes]]&lt;br /&gt;
* [[Chatlog from 2007/09/16]] (Gigs, otakup0pe and Tao_T talk about possible forms of regions etc.)&lt;br /&gt;
*  [http://taotakashi.wordpress.com/2007/09/24/second-life-grid-architecture-meetup-transcript/ Transcript and Slides from Tao Takashi&#039;s informal meetup on 2007/09/23]&lt;br /&gt;
* [[In World Chatlogs]]&lt;br /&gt;
* [[AW Groupies]]&lt;br /&gt;
&lt;br /&gt;
See also: [[User:Zero Linden|Zero Linden&#039;s office hour transcripts]]&lt;br /&gt;
&lt;br /&gt;
==Individual Reviews and Feedback==&lt;br /&gt;
&lt;br /&gt;
* [[ Zha&#039;s comments on meeting 1]]&lt;br /&gt;
* [[AWG:  Zha&#039;s Desiderata for evaluating the proposed design]]&lt;br /&gt;
* [[ Tree&#039;s comments on meeting 1]]&lt;br /&gt;
* [[Diva Canto&#039;s Review]]&lt;br /&gt;
* [[Mic&#039;s Feedback]]&lt;br /&gt;
* [[Views of the Gareth]]&lt;br /&gt;
&lt;br /&gt;
==Discussions==&lt;br /&gt;
&lt;br /&gt;
* [[DRM, IP and permissions]] (from the mailing list)&lt;br /&gt;
* [[Initial CAPS seed]]&lt;br /&gt;
* [[AWG initial flows]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;noinclude&amp;gt;&lt;br /&gt;
[[Category:Architecture Working Group]]&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tedd Maa</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=Architecture_Working_Group&amp;diff=35636</id>
		<title>Architecture Working Group</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=Architecture_Working_Group&amp;diff=35636"/>
		<updated>2007-10-14T20:44:28Z</updated>

		<summary type="html">&lt;p&gt;Tedd Maa: /* Architecture Proposals */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Image:slarch.jpg]]&lt;br /&gt;
&lt;br /&gt;
    I have gathered my tools and my charts,&lt;br /&gt;
    My plans are finished and practical.&lt;br /&gt;
    I shall roll up my sleeves — make Second Life over. &lt;br /&gt;
&lt;br /&gt;
==Goal==&lt;br /&gt;
&lt;br /&gt;
Discuss, design and implement a scalable and open architecture for the future Second Life Grid.&lt;br /&gt;
&lt;br /&gt;
==Materials==&lt;br /&gt;
&lt;br /&gt;
* [[Project Motivation]]&lt;br /&gt;
* [[Architecture Working Group Glossary|Glossary]]&lt;br /&gt;
* [[Use Cases]]&lt;br /&gt;
* [[Brainstorming]]&lt;br /&gt;
* [[Scoping]]&lt;br /&gt;
* [[Viewpoint Advocacy Groups]] (proposal)&lt;br /&gt;
&lt;br /&gt;
==Architecture Proposals==&lt;br /&gt;
* [[Proposed Architecture|High Level Architecture proposed by Linden Lab]]&lt;br /&gt;
* [[Hyperplanes]]&lt;br /&gt;
* [[Tedds stand-alone script engine|Tedds stand-alone script engine proposal]]&lt;br /&gt;
&lt;br /&gt;
== Participating ==&lt;br /&gt;
Membership in this group is open. Start contribution to the work, and you become a member. &lt;br /&gt;
* Contribute to the materials and documentation in this wiki --- a lot of material is being drafted and discussed in the [[AW Groupies]] section (also, see below).&lt;br /&gt;
* Join the [http://wiki.secondlife.com/wiki/SLDev sldev mailing list] and use tags like [ARCH] and [AWG] in the subject line.&lt;br /&gt;
* Meet with others for technical discussions: [[User:Zero Linden|Zero Linden&#039;s]] office hours, [[AW Groupies]].&lt;br /&gt;
&lt;br /&gt;
==Meetings==&lt;br /&gt;
Formal meetings will likely be held 3-4 times/year and located in Second Life to facilitate broad participation. Meetings will be coordinated on [[SLDev]]. Group members are encouraged to self-organize smaller meetings to move forward particular work areas and discuss hot topics as needed.&lt;br /&gt;
&lt;br /&gt;
* Meeting 1&lt;br /&gt;
** [[ArchWG_Mtg_1_Agenda|September 13th 2007, Meeting 1]] &lt;br /&gt;
** [[Workitems for Meeting 1]]&lt;br /&gt;
** [[2007-09-13 Arch WG Minutes]]&lt;br /&gt;
* [[Chatlog from 2007/09/16]] (Gigs, otakup0pe and Tao_T talk about possible forms of regions etc.)&lt;br /&gt;
*  [http://taotakashi.wordpress.com/2007/09/24/second-life-grid-architecture-meetup-transcript/ Transcript and Slides from Tao Takashi&#039;s informal meetup on 2007/09/23]&lt;br /&gt;
* [[In World Chatlogs]]&lt;br /&gt;
* [[AW Groupies]]&lt;br /&gt;
&lt;br /&gt;
See also: [[User:Zero Linden|Zero Linden&#039;s office hour transcripts]]&lt;br /&gt;
&lt;br /&gt;
==Individual Reviews and Feedback==&lt;br /&gt;
&lt;br /&gt;
* [[ Zha&#039;s comments on meeting 1]]&lt;br /&gt;
* [[AWG:  Zha&#039;s Desiderata for evaluating the proposed design]]&lt;br /&gt;
* [[ Tree&#039;s comments on meeting 1]]&lt;br /&gt;
* [[Diva Canto&#039;s Review]]&lt;br /&gt;
* [[Mic&#039;s Feedback]]&lt;br /&gt;
* [[Views of the Gareth]]&lt;br /&gt;
&lt;br /&gt;
==Discussions==&lt;br /&gt;
&lt;br /&gt;
* [[DRM, IP and permissions]] (from the mailing list)&lt;br /&gt;
* [[Initial CAPS seed]]&lt;br /&gt;
* [[AWG initial flows]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;noinclude&amp;gt;&lt;br /&gt;
[[Category:Architecture Working Group]]&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tedd Maa</name></author>
	</entry>
</feed>