Avatar Title Changer

Thread Started By YoungMoney

2922
0
  • 54 Vote(s) - 3.13 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Rate Thread
#1
// Changes avatar hovering title on command in local chat, starting with /change. Put the script in a small box and texture the box with a 100% transparent texture. Attach the box to your upper body (head or schoulder).



Code:
// Avatar Title Changer
// author: unknown




string default_text = "Type /change to change the hovering text!";
string text;
list colors =

[<1.0,1.0,1.0>,<0.5,0.5,0.5>,<1,0,0.0,0.0>,<0.0,1.0,0.0>,<0.0,0.0,1.0>,<1.0,1.0,0.0>,
<1.0,0.0,1.0>,<0.0,1.0,1.0>];

default
{
    state_entry()
    {
        text = default_text;
        llListen(0, "", NULL_KEY, "");
        llSetText(text, <0,1,0>, 1.5);
        llSetTimerEvent(0.5);    
    }
    
    on_rez(integer start_param)
    {
        text = default_text;
        llSetText(text, <0,1,0>, 1.5);
    }
    
    listen(integer channel, string name, key id, string message)
    {
        if (llToLower(llGetSubString(message, 0, 6)) == "/change" && id == llGetOwner())
        {
            text = llDeleteSubString(message, 0, 6);
            llSetText(text, <0,1,0>, 1.5);
        }
    }
    
    timer()
    {
        integer random = llFloor(llFrand(llGetListLength(colors)));
        llSetText(text, llList2Vector(colors,random), 1.5);
    }
}
Reply




Forum Jump:

1 Guest(s)
Share this:

About Second Life Copybot

Second Life CopyBot Forum is a place where you can get items for Second Life and other vitual worlds for free. With our CopyBot viewers you can export and import any content from these virtual worlds and modify them in 3D software such as Blender, 3D studio Macx etc...