Generic LSL Examples
From XRPSAPIWiki
Contents |
LSL Script Examples
Why collect generic LSL scripts on this site?
- Because we want to encourage community members to create exciting content
- Because we believe in making knowledge accessible
Posting Guidelines
- Submittals should be made via script or notecard in Second Life to Baron Nowhere
- Scripts should be clearly commented, tested, and free of obvious bugs
- Submittals should be able to be used by other viewers. We perfer submittals that abide by Creative Commons Licenses but will consider other licenses too on a case-by-case basis (BSD, L/GPL).
Full Script Examples
Scripts in this section can be dropped into an empty script and compiled. These are fully working script examples.
Scripts For Debugging
| Name | Creator | Description |
| Listen Oracle | Baron Nowhere | This listener can be inserted into an object to "overhear" the traffic inside. I commonly use this to aid in debugging creations where scripts talk to other sources. |
| HTTP Requester | Baron Nowhere | Allows you to send an arbitrary web request into the script and see the contents of what the server returns via llHttpRequest |
Miscellaneous Scripts
| Name | Creator | Description |
| Have A Heart | Baron Nowhere | Want a Heart Prim? Here's a script to create one for you. |
| SL Avatar Count | Baron Nowhere | This is a simple example that parses the Second Life XML which lists a series of live statistics. It tells the owner how many users are logged in. |
| Get Region Corner | Baron Nowhere | This is another simple example using a dataserver, much like how notecards are read. It allows you to ask Second Life the region corner of multiple sims at once. |
Other LSL References
LSL Utilities
- LSLEditor is great because it offers a great runtime environment that Baron Nowhere uses to execute offline tests and evaluations
- TextPad Editor (Syntax File) is the generic and fast text editor of choice for Baron Nowhere
- LSL IDE for Eclipse is an environment Baron Nowhere uses for other development outside of LSL, and occasionally for LSL too
- KDiff3 is a file/directory comparison tool
