Scripting Languages

From OpenSimulator

Revision as of 19:51, 1 February 2008 by Tedd (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Contents

Scripting Languages

OpenSim currently supports 3 scripting languages, and more are under way.
Scripts are restored automatically when OpenSim starts.

LSL

LSLv2 is the well know Second Life scripting language. It is basically a C#/Java-like language. Allthough many commands are still being developed, the majority of ll-functions has been implemented and it is possible to make usable scripts. If you want to ensure that the compiler treats your script as LSL you should have "//lsl" as the first 5 letters in script.

C#

C# is a .Net language.
Allthough it is C# the behaviour is much like LSL in the sense that you still use ll-functions like llSay(), and still use the same events as in LSL.
The first 4 characters in your script must be "//cs" for the compiler to treat it as C#.

Example code:

   //cs
   public void default_event_state_entry()
   {
       llSay(0, "This is an incredibly useless program." );
   }

VB.Net

VB.Net is a .Net language.
Allthough it is VB.Net the behaviour is much like LSL in the sense that you still use ll-functions like llSay(), and still use the same events as in LSL.
The first 4 characters in your script must be "//vb" for the compiler to treat it as VB.Net.

Example code:

   //vb
   Public Sub default_event_state_entry()
       llSay(0, "This is an incredibly useless program.")
   End Sub
Personal tools
General
About This Wiki