Eng:Scratch for Second Life

Scratch for Second Life (S4SL) is a modification of an internal build of Scratch 1.1 created by Eric Rosenbaum of the Scratch Team. It is designed as a script editor for controlling pets in the popular MMOG Second Life. Users can create scripts using blocks in S4SL and then copy them as code that can be executed by Second Life, known as Linden Script. It reached version 0.1 and it is no longer in development.

Interface
The layout of the program is very similar to the left side of Scratch 1.1, albeit with no share button and two buttons, Paste Script and Copy Linden Script, replacing the regular content of the Sprite Header Pane. The whole right side of the program, including the Stage and Sprites, has been removed, although it is still accessiblealthough graphically glitchedby resizing the program window.

Blocks
Because S4SL has a very different and more specific use than regular Scratch, it also has very different blocks although some are the same. Some of the blocks that have the same name have different functionality in Second Life, however.

Control
Hat blocks Stack blocks C blocks
 * when I am touched
 * when I collide
 * when I receive
 * forever
 * wait secs
 * broadcast
 * repeat
 * if
 * if else

Motion
Stack blocks Reporter blocks
 * move meters
 * turn degrees
 * up meters
 * down meters
 * roll degrees
 * pitch degrees
 * go home
 * set home to here
 * point toward nearest avatar
 * point toward owner
 * point in direction
 * direction

Sensing
Reporter blocks
 * distance to nearest avatar
 * distance to owner
 * number of avatars nearby

Looks
Stack blocks Reporter blocks
 * say
 * set text
 * change color by
 * set color to
 * change ghost by
 * set ghost to
 * change size by
 * set size to
 * size

Numbers
Reporter blocks Boolean blocks
 * +
 * -
 * *
 * /
 * pick random to
 * <
 * >
 * =
 * and
 * or
 * not

Sound
Stack blocks
 * play sound [drop-down]
 * play sound

Variables
Reporter blocks Stack blocks
 * 
 * change by
 * set to

Pen
Stack blocks
 * clear
 * pen down
 * pen up
 * change pen color by
 * set pen color to (number block)