So I've been trying to create a basic Titler for my group to use. My intention is to have a Titler that allows you to change both the text and color on the /55 channel. Currently, the script works perfectly in changing the text by using the /55 channel. However, I cannot figure out how to get the script to parse \n for the function, instead of setting it as text. Also, I can't seem to get the script to parse RGB commands either, for changing the title color.
So far, this is the FUNCTIONING script that I've compiled. Any help with adding the ability to add new lines via chat command, or change the color via chat, would be very appreciated. Thank you in advance.
integer CommandIs(string msg,string cmd)
{
return llSubStringIndex(msg,cmd) == 0;
}
ParseAndIssueCommand(string cmd)
{
if(CommandIs(cmd,"Title"))
{
string name = llGetSubString(cmd,6,-1);
if(name == "Title")
llSetText("",<0,1,0>,1.0);
else
llSetText(name,<0,1,0>,1.0);
}
}
default
{
state_entry()
{
llListen(55,"",llGetOwner(),"");
}
on_rez(integer start_param)
{
llResetScript();
}
listen(integer channel, string name, key id, string msg)
{
ParseAndIssueCommand(msg);
}
}