Don't click here unless you want to be banned.

LSL Wiki : ScriptLibrary

HomePage :: PageIndex :: RecentChanges :: RecentlyCommented :: UserSettings :: You are

Script Library

There are many scripts that have become buried in the Scripting Library forum, were lost with the death of the scripting forums, or sit idle in inventories that could be useful and should be more accessible. Other scripters may be in the same situation. This wiki is a well-suited medium for a script library. Feel free to add scripts to the script library by creating new pages for them and linking to those pages here.

Proper etiquette for the library is to not edit someone else's script because you think your way is better, but rather to post your own version, linked from and back to the original.

There is a companion particle library that contains particle systems.

Rules for posting:
1. Prefix pages for the script library with "Library" to keep the Wiki namespace clean. Example: LibraryEventLottery
2. Your script must be tested and working. If it's not, stick it on your own username page until it is. This is a list of working, usable scripts.
3. Add a link to your script's page here. Link back to this page from your script's page. Also, keep this list in alphabetical order.
4. Don't add scripts that duplicate the same functionality as an existing script. If yours does, explain why.

Name Creator Description
Hello Avatar Linden Lab SL's default script
ASCII ChadStatosky ASCII <-> int
AirSeaAltimeter OoPsGalatea A pretty decent air/sea altimeter.
AltPickPocket MitzpatrickFitzsimmons Transfer Money from your Alt's account without logging them in.
AvatarKeyScript KingHenrikLundquist Basic key-detecting script
Barometer CidJacobs Check Barometric Pressure.
Bezier Curve Demo LionelForager Draws a bezier curve in 3D given by 3 control points.
Builders' Buddy NewfiePendragon Large building positioning/movement utility.
Builders' Tabs TimelessPrototype Advanced precision builder's tool.
Camera Sync MeyermagicSalome and NomadPadar Camera Synchronization utility
Color Scripts KagePixel Convert from HSB to RGB and back.
Common String Functions GarrMeDagger Common String Functions
Channel Number Generator PetreLamar Given a text string, generate a (relatively) unique channel number.
PublicBillboard Chasingred3Ixtab A Public Cycling Texture Billboard.
Conversation AI AmaOmega Simple conversation tree (Eliza-like).
Camera Follower ArkLehane Follows just above your camera.
Chat Extension Module ChristopherOmega Allows transfer of >255 character strings over chat, via Packet Chat Protocol.
Create a flying pet CatFart (Incomplete/Not being worked on) A worked example on how to create a small flying object using physics-based movement.
Case Insensitive Listen rezzer Chasingred3Ixtab Case insensitive listen rezzer.
DanceBall AsiraSakai This script plus dance animations in a prim create a clickable danceball.
Dance Machine EvilFool Single prim dance machine with synchronized dancers.
Day of the week RichardSolvang Figure out what day of the week a given date is.
Deluxe Door EzharFairlight A door with some extras. See also: the new Timeless Linked Door.
Dialog Module StrifeOnizuka Create and handle dialog boxes through linked messages.
Dump Prim Parameters PierreJosephProudhon Dump prim parameters to a LSL code string that can be fed to llSetPrimitiveParams
Eliza Chatbot DedricMauriac Parady of a Rogerian therapist
Email Extension Module ChristopherOmega Allows scripts to send emails without delay and receive emails without a timer.
Simple Email Parser PlowboyLifestyle Breaks an email header into local variables with some error checking.
Enhanced SLURL HarleenGretzky Ouputs a SLURL using the new teleport app URL, allows you to click the link to teleport without going to the map first.
Event Lottery AmaOmega Randomly choose a winner from a list of people without duplicates.
Experimental Rotation Math Library StrifeOnizuka Collection of functions for working with rotations.
Fade Texture NashBaldwin Smoothly drop texture alpha using exponential fall-off.
Fast Find AmaOmega Fast find number of lines in a notecard (binary search).
Fix Repeats Per Meter NashBaldwin Make a building by roughly positioning walls, then drop this script on each prim. It rescales to grid, positions to grid, and fixes repeats per meter, then deletes self.
Flight Assist MorphWollongong Flight assist HUD controller script
Float to Hex StrifeOnizuka Very useful for floats transporting.
Fractal Generator SeifertSurface Generates fractal "trees". User friendly.
General Menu Engine ZonaxDelorean A menu system engine that lets you define menus then easily use them.
Get Day of Week DoteDoteEdison Alternate method to get day of week from llGetUnixTime.
Get Timestamp Offset SiannBeck Returns llGetTimestamp() with an hour offset. (If someone can tell me how to create a page, I'll add it.)
Give Inventory DedricMauriac Gives inventory and checks permissions
Go Game JonathanShaftoe A fully working Go game board.
IGS (In Game Data Server) ViceroLambert A simple LSL server.
Keyboard while typing MaxCase A simple keyboard while you type.
Link Numbers Getter KankerGreenacre Simple function for keeping track of the links in your object.
Listening Texturer VirusCollector Small script to change a texture to any key you say.
Millisecond Time MinskOud Timezone-aware and millisecond-granuality time and formatting functions.
MitzFader MitzpatrickFitzsimmons Object Alpha Fader Transition Effect
MultiCahnnel Listener AnorcaCalamari Listen on any set of 50 channels
Multidimensional Array API ChristopherOmega Store data in lists as you would in a standard C++/Java multidimensional array.
MultiTitler TigroSpottystripesKatsu A basic titler that enables you to wear more than one titler at once and set them individually
NewbieNag KexGodel Give a notecard to a new resident below a certain age
Nonphysical Move To StormSaber Uses llSetPos to emulate llMoveTo -- but for non-physical objects
Notice Giver Joker Opus Gives notices to anyone within 96 meters
NotecardChecker Ruthven Willenov Checks which notecard was added, deleted or updated
Parametric Surface Rezzer SeifertSurface Rezzes a surface defined by an arbitrary parametric equation of two variables.
Passwall AsiraSakai This script will allow you to set up a solid wall that lets certain people pass through it.
Pose Ball Script, version 4.3.2 SimonRaven and others pose ball script, updated.
Particle Script 1.1 KeknehvPsaltery A very efficient script for the creation and inclusion of particle systems. Albeit not the best if you are just learning, but excellent if a particle system is needed for something else.
Particle Script 1.2 JamesHanner An added feature to the above script.(Has a new key setter instead of just owner and self)
Particle Script 0.5 AmaOmega Create particle systems and play around with the settings.
Particle Script 0.5a EepQuirk An optimized version of the above script.
Polygon Former JontteGremlin Code snippet that will form a triangle between 3 vectors. Can be used, for example, in 3d model loaders.
PortRing Creator Neo Rebus A system to automatically create a teleporter system from a central "base" location to a number of outlying "stations".
Profile Picture Display HarleenGretzky Displays your profile picture on a prim when touched, uses the new search world webpages.
Pseudo-Random Number Generator StrifeOnizuka For use with secure communication through insecure mediums to reducing the risk of the communications protocol being hacked.
Radar SableTill Fairly complete scanner that includes details on distance, time in vicinity and direction
RadioStation AsiraSakai Add lists of radio stations, descriptions, and authorized station changers, and authorized users can change parcel music urls.
Random Hovertext Colour KopiloHallard Sets hovertext on an object and changes the colour to a random colour every 0.5 seconds
Realistic Airplane Flight Script, Li'l Stinker Gnu FPL FritzKakapo Physical stunt light airplane script, intended to resemble real world aerodynamics and physics. Includes comments about which vehicle parameters model which airodynamic behavior. For full permission objects only, not for use in proprietary products.
Regular text to Upside-down TigroSpottystripesKatsu converts regular text spoken in the open chat into upside-down text (unicode)
Rope Constraint ComradePodolsky Links two objects by a physical emulation of a rope-like constraint and uses particles to visually represent it.
Runtime Environment ReadyJack Detailed detection of object environment changes like dropping or wearing. Also detects logins!
Sailboat Script KankerGreenacre Flying Tako sailboat
Self Upgrading Script MarkovBrodsky Keeps only latest version on prim
Self Upgrading Script Enhanced CronStardust Keeps only latest version of the script on prim (Even with multiple adds of the same script!)
Self Upgrading Script Alt DamekTretiak Updates each child-prim with a given script
Serialize ShadowGretzky Implements 'float-safe', reasonably quick serialization and unserialization of list types
Set Text Once EpikTetus Drop it on an object, say "/3 This is Red", the floating text changes and the script deletes itself.
Settings Notecard KonigmannLippmann Loads values from a notecard so scripts can be customized by user.
Simple Cypher AmaOmega A simple password-based substitution cypher.
Simple Disappearing HoverText KonigmannLippmann A simple demonstration of how to remove hover text when an avatar sits on the prim.
SLPrint AmaOmega A function to print formated data, including hexidecimal and fixed-point floats.
LibrarySLurl InaCentaur A function that outputs SLurl given regionName and position in <x,y,z>
Smooth Rotating Door ToyWylie A script for doors that open and close smoothly using llTargetOmega (external link until creation of pages works)
Smooth Sliding Door SimonQuinnell A script for a sliding door that open and close smoothly using llMoveToTarget. Adjusts for prim orientation.
Strided List Functions AakanaarLaSalle Functions for working with strided lists.
String Replace NecroDarkes Replace all strings within a string.
Swarm ApotheusSilverman This implements the widely-available swarm algorithm in SL.
Teleporter AsiraSakai This teleports the object and the person sitting on it within the simulator.
TextureSwitcher StrifeOnizuka Texture switcher that will step through the textures in an object's inventory, displaying them on all sides of the object.
Thermometer CidJacobs Check Temperature.
Time and Date Functions GarrMeDagger Time and Date Functions
TimeElapsed ChromalBrodsky When called twice, will give the time elapsed with millisecond precision.
Timeless Linked Door TimelessPrototype Full-featured door script for doors that are linked to other prims.
Timer Enhancer ChristopherOmega Grants more precise control over timers.
Unescape StrifeOnizuka Unescape escape codes in strings.
Universal Prim Torture Script StrifeOnizuka Upgradable universal prim torture script.
Product Update Server Comet Aero Updates product upon request
Product Update Server 2 Comet Aero & Kri Ayakashi Enhanced version of above. Works with multiple products.
Vendor Script AmaOmega A simple vendor
Vigenere Cipher DolusNaumova A polyalphabetic substitution cipher.
WarpPos KeknehvPsaltery A function that allows one to do instantaneous non-physical movement
NumRs NornAlbion Display numbers on a prim - maximum of 3 per prim
Position HUD GigsTaggart Moves a HUD to a same position in any attach point.
Timestamp Difference BenFassbinder Calculate the difference in seconds between two timestamps.
Wind Turbine CidJacobs Estimates approximate watts stored from wind powered turbines.
XyText XylorBaysklef Display text (up to 6 characters) on a prim
XyText 1.2 KermittQuirk, ThraxisEpsilon Display text (5 or 10 characters per prim)
LibraryInstantMessageAnyone AnorcaCalamari Instant messager script
LibraryMapTele AnorcaCalamari Teleports you anywhere you are allowed
LibraryParticleGarden ZaraVale Randomly rezzes textures in your object, to form a particle garden, the flowers also grows slowly!
LibraryParticleSignboard ZaraVale 1 Prim Signboard that can change via a chat channel
LibraryPrecisionTime SendaoGoodman Precision timer for accurate timing in SL
LibrarySenWarp SendaoGoodman Warppos replacement.
LibrarySenWalk SendaoGoodman Autowalk with variable speed setting.
LibrarySenRez SendaoGoodman This is what I use for most of my rezzers. It eradicates the long wait period on llRezObject by using the parallel script workaround.
LibrarySenRot SendaoGoodman Smooth nonphysical rotation. May cause lag. ;)
LibrarySenKey SendaoGoodman Translate an avatar's key into a playable string of notes
LibraryPreloadTextures SendaoGoodman A preloading auto-changing picture display
Word Scrambler SecondProctor Scrambles anything you want.
RandomVector WarKirbyMagojiro Produces a random vector
clrchanger SecondProctor Changes the color of a whole object from 1 script.
LightPole HeusDens LightPole that goes on/off on touch and depending on sunlight
Xe.DialogerV1.0 XeltonTzedek Simple Dialogging script, used within shout distance
LibrarySafeZoneMelee TharkisOlafson Safezone/Battlezone compliant melee weapon script
Q: What's the difference between the Script Library and the Examples page?
A: The Script Library is for full scripts. Examples is best suited for explaining specific functions or parts of scripts.

Particle Library | Examples | Jasa SEO Murah Jasa SEO Jasa Google Adwords Jasa Adwords Google Adwords Sepatu Safety Sepatu Futsal Cheapes Hostgator Coupon Link Booking Televisori offerte Notebook Offerte Govr Edo Ziedo Portatile Apple RDAnet Lorks Karikatur Bisnis Modal Kecil Bisnis UKM Berita Terbaru Iklan Baris Jasa SEO Murah SEO Indonesia Konsultan SEO SEO Belajar SEO Penumbuh Rambut Kursus SEO Jam Tangan Casio Grosir Baju Bisnis Online Kerupuk Kulit Social Bookmark Kumpulan Puisi WBC Wonogiri Penumbuh Rambut Jam Tangan Murah Jam Tangan Murah Jam Tangan Casio Penumbuh Rambut Kerupuk Kulit Alat Kantor Belanja Online Grosir Eceran Murah dan Aman Jasa SEO Model Jilbab Fine Tableware Permanent Hair Removal island investment development professional makeup artist bali private villa sewa mobil jakarta murah Jual rumah Jakarta Contact Lens Technology
Comments [Hide comments/form]
what if there is a bug in the code the person wrote?
-- BlindWanderer (2004-06-28 00:52:34)
Then you beat him with a stick. Unless it's me, of course.

Or you could point it out via a comment :)
-- EzharFairlight (2004-06-28 10:34:45)
There are _never_ bugs in my code. Actually fixing bugs, as long as it really is a bug, is probably fine and one of the strengths of wiki. My comment above is more about looking at someone elses script and thinking 'geeze why is he doing it that way? he should be doing it this way' and then changing their script. Fixing broken scripts on the other hand is usually a good thing.
-- AmaOmega (2004-06-30 01:38:10)
Im not sure where to put this suggestion, but since this is a repository for scripted code, I thought I'd put it here. What I really think we should do is make TypeUtilities pages that contain dev-made functions specific to that type. For example: the FloatUtilities page would have functions like roundFloat() and signedRandFloat() on it and the VectorUtilities page would have stuff like roundVec() and signedRandVec() on it.
-- ChristopherOmega (2004-07-13 22:50:39)
Sure, go for it, Chris.
-- CatherineOmega (2004-08-01 23:55:27)
I second that motion, and I created the beginnings of such a page. Please, add to it.
-- KeknehvPsaltery (2005-06-17 10:09:34)
mhh we need to have more scripts here!
Those people on the main grid get all the goodies of the scripting library there( i think) as its a large community. We would be greatful ( we as in teen grid) if you put some of the scripts in that forum over here as well. Also it might be easier when the scripts would be here instead because we could easily change the layout here to have categories for all the different scripts and a proper list with descriptions and their creators.
-- KairaOverdrive (2006-02-09 22:44:44)
Posted to the Script Discussion forum asking for permission and people's thoughts on the transfer:
Hey all,

How would everone react to scripts being moved from the forum Script 
Library to the wiki's ScriptLibrary page? Should I ask every contributer 
individually? What do I do about page ownership if the script's author 
isn't registered on the wiki?

Access to these forums is restricted for a significant portion of the SL 
population, teen-grid users, in particular. The duplicaton will also 
emphasize the script's presence (more people will see it), since we have 
easier ways to organize data on the wiki.
-- ChristopherOmega (2006-04-10 14:49:22)
More scripts are fine but they'll need to be classified and organized better--perhaps a databased website would be better so they can be sorted/searched for more easily.
-- EepQuirk (2006-04-11 04:55:00)
Oh please do bring the scripts over from the scripting library to the wiki.
-- ZeeraXi (2006-10-22 12:33:01)
Eep: I believe we anyways starting to need an organized script library right now on this page.

We are approaching upto 70 scripts on that table and its getting quite messy with the descriptions.
-- ZeeraXi (2006-10-22 18:18:57)
I went through a few of these pages changing floating point numbers like "30" to "30.0".
I hope no one minds; it's a very minor optimization that has very little effect on aesthetics.
-- KeknehvPsaltery (2006-10-31 19:50:00)
Does it actually effect speed in non-typecast situations? The math operators accept any type as input and handle the different types internally. So something like "a+b" becomes "<operator-byte='+'><types-byte><input='b'><input='a'>" The <types-byte> is a structure, the first 4 bits for <input='b'>'s type; the second 4 bits for <input='a'>'s type.

All the operators work this way (except the integer specific ones: "!", "~", "<<", ">>", "^" which do not have a <types-byte>). Typecasting can be avoided post-operator if the user mind the inputs types for the operator.

What i'm saying is, if "flt" is a float then "flt / 2" and "flt / 2.0" will be the same size in bytecode; and have the same return type. Are you saying that "flt / 2.0" is faster? I haven't done the test, but it was my understanding they were about the same speed (which is why I didn't have a conniption fit when you went through the library).

As to the changes regarding initialization of floats, vectors & rotations; those changes were totally righteous.

If you want a real challenge, fix the swarming script; it's got logic holes (I looked at the script a few times and determined it was bugged but I don't have the interest in testing any fixes i might do to it, and it's not cool to do major changes to a script and not test it).
-- BlindWanderer (2006-11-02 07:32:08)
Ah, ok. I must have misunderstood some of your comments on optimizations-- so given f(float x), f(3+3.0) is just as fast as f(3.0+3), but f(3+3) is slower, and f(3) is slower than f(3.0)?

About the swarm algorithm, I'd rather re-code the entire thing than have to go through someone else's logic. Basing it off the algorithm that Apotheus Silverman provided in the original thread might be best.
"1. Accelerate toward the halfway point between your two nearest neighbors.
2. Upon collision, momentarily be repulsed by whatever object or ground was collided with.
3. If no neighbors are detected, just keep moving in a straight line at a constant speed. If I go off-world, then so be it."
-- KeknehvPsaltery (2006-11-04 14:32:56)
Attach a comment to this page: