Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- string desc="
- ";
- //==============================
- integer shown=FALSE;
- show()
- {
- llSetLinkAlpha(LINK_SET,1,ALL_SIDES);
- llSetText(desc,<1,1,1>,1);
- shown=TRUE;
- // llSay(0,"show");
- }
- hide()
- {
- llSetLinkAlpha(LINK_SET,0,ALL_SIDES);
- llSetText("",<1,1,1>,0);
- shown=FALSE;
- // llSay(0,"hide");
- }
- default
- {
- state_entry()
- {
- integer channel=(integer)llGetScriptName();
- //llSay(0,"channel: "+(string)channel);
- llListen(channel,"",NULL_KEY,"");
- hide();
- }
- listen(integer channel, string name, key id,string str)
- {
- string first = llGetSubString(str,0,0);
- string last = llGetSubString(str,1,-1);
- // llSay(0,"first: "+first+" last: "+last);
- if(last==llGetObjectName())
- {
- if(first=="+")show();
- if(first=="-")hide();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement