//Just somthing useful I grabbed off the net!  Cheers!
//1.    Create a box. You will need a place to build – e.g. a sandbox.
//a.    Drag a box to ground with your mouse
//b.    In the editing pane, type a descriptive name (like “mytitle”) in the name textbox in the general tab – this //is the pane shown on the right of this figure.
//c.    Now squeeze up the box into a vertical bar:
//i.    Click on box, edit
//ii.    Hold down shift and ctrl, with mouse move red and green knobs until the box is vertical bar.
//iii.    Click on the texture tab in the editing pane. Change transparency box to 90% -- uh, oh – what happened, now you can’t see it. To see it hold down ctrl and alt and press T – it shows hidden objects. Look where the vertical bar is – you can now see it.
//d.    Now, click on the Content Tab, click on New Script button, click on the “New Script”, replacing the code that is already the “New Script as a place holder.with the code at the end of this article.
//e.    Try out – type in the text box – title red yourname …..(e.g. title red john) – as shown in the figure.
//f.    Now return the title to your inventory. Click on it, and select “take” – it will appear under objects in your inventory.
//g.    Open your inventory and right click on the object – title – and right click and then “attach to” and “skull” – this works fine, but you may want to put it elsewhere. – Note, if you attach to your arm, your name will float and move around continuously. With it attached to your skull, it will simply float over your head.
//h.    Notice it may be too high (probably will be), click on the vertical bar (which you will have to have selected ctrl-alt-T to be able to see, right click edit and move the name down to just above your head.
//i.    Voila- you are done. When you don’t want to have your name, just detect it, or type title off in the text box.
//j.    You can change what the title says at any time – e.g. “title blue John Bourne, Ph.D
//k.    Note that the object will continue to retain this information until you change it.



string command = "";
string person = "";
key owner;

default
{
state_entry()
{
owner = llGetOwner();
llListen(0,"",owner,"");
}

attach(key attached)
{
if (attached != NULL_KEY)
{
llInstantMessage(owner,"To set a title: title ");
llInstantMessage(owner,"To remove title: title off");
llInstantMessage(owner," can be: white, black, red, green, blue, pink, cyan, purple, yellow, orange");
llResetScript();
}
}

listen(integer channel, string name, key id, string message)
{
list strings = llParseString2List(message,[" "],[]);
string command=llList2String(strings,0);
string string1=llList2String(strings,1);
if(command=="title")
{
vector color=<0,0,0>;
if(string1=="blue")
{
color=<0,0,1>;
}
else if(string1=="orange")
{
color=<1,0.5,0>;
}
else if(string1=="cyan")
{
color=<0,1,1>;
}
else if(string1=="pink")
{
color=<1,0,1>;
}
else if(string1=="green")
{
color=<0,1,0>;
}
else if(string1=="red")
{
color=<1,0,0>;
}
else if(string1=="white")
{
color=<1,1,1>;
}
else if(string1=="yellow")
{
color=<1,1,0.1>;
}
else if(string1=="purple")
{
color=<0.7,0,0.7>;
}
else if(string1=="gblue")
{
color=<0,0.5,1>;
}
else
{
color=<0,0,0>;
}
string title = "";
integer i;
for(i=2; i<=12; i++)
{
if(llStringLength(llList2String(strings,i)))
{
title = title + llList2String(strings,i) + " ";
}
}
if(title == "off")
{
llSetText("",<0,0,0>,1.0);
} else {
llSetText(title, color, 1.0);
}
}
}
}