User:Fred Gandt/Scripts/Continued 4

From Second Life Wiki
Jump to navigation Jump to search
I get in-world very rarely these days. The knock-on effect of this, is that I am not in the best position to keep these scripts updated. Please message me in-world (forwarded to email) if you discover any bugs (that can't be simply fixed), and I'll do my best to find a solution.

My Contributions

If unsure about how to use these scripts

I have implemented a version number system to make it more obvious if a script is updated. The V# is a comment at the top of each script.

If you have any comments about the content of this page please post them HERE

All my scripts are written for compilation as MONO

More Scripts

Legal Stuff

The legal stuff about contributing to this wiki. (worth reading)

PJIRA Issue Tracker

The issues I have filed on the PJIRA

Tuition

Tuition scripts, notes, videos and screenshots etc. (hardly any content yet)

Free Scripts

Text Scroller

A simple text display unit that scrolls text from right to left (like those LED signs) in a continuous loop. Touch to start and stop the scrolling. It is not very sophisticated.

Create The Object

  • Create a fresh new prim and drop this script onto/into it. The prim will form the shape needed plus change the texturing etc. (you can do what you like to the texturing afterwards).

<syntaxhighlight lang="lsl2">// V2 //

default {

   state_entry() {
       llSetPrimitiveParams( [
           7, <0.5, 0.01, 0.25>, // Set the size
           8, <0.0, 0.0, 0.0, 1.0>, // Set to ZERO_ROTATION
           9, 0, 0, <0.375, 0.875, 0.0>, 0.0, <0.0, 0.0, 0.0>, <1.0, 1.0, 0.0>, <0.0, 0.0, 0.0>, // Shape the prim
           17, -1, "5748decc-f629-461c-9a36-a35a221fe21f", <1.0, 1.0, 0.0>, <0.0, 0.0, 0.0>, 0.0, // Apply the blank texture
           18, -1, <1.0, 0.65, 0.1>, 1.0, // Color the prim (kinda orange)
           20, -1, 1, // Make fullbright
           25, -1, 0.05 // Slight glow
       ] );
       llRemoveInventory( llGetScriptName() ); // Remove the script when done
   }

}</syntaxhighlight>

  • When the script has worked its magic, Snap the prim to the grid with a grid size of .5 meters.
  • Shift-Drag-Copy the prim, snapping each to the grid positively along the X axis until you have 10 prims in a continuous strip.

You can actually make the object as long or short as you like. 1 prim will work. 100 prims will work (although large linksets have been a problem for link_messages in the past). Just follow the same basic build plan.

  • Select each of the prims from the end that has the greatest X axis position, one at a time (negatively along the X axis) until ALL are selected.

  • Link the set.

Display Script

  • Check "Edit Linked parts" and select one prim at a time, dropping this script in each.
  • DO NOT CREATE A FRESH SCRIPT IN EACH PRIM. DROP THE SAME SCRIPT FROM YOUR INVENTORY INTO EACH PRIM.

<syntaxhighlight lang="lsl2">// V1 //

string font = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890(){}[]<>

More Scripts...

If you have any comments about the content of this page please post them HERE