Twistted Hand Posted February 21, 2018 Share Posted February 21, 2018 I am in need of help. Ive been trying to script this thing for a while now. Im trying to set up a HUD button you can press and it will detect in chat and update a titler on another prim. Any help would be appricated. Link to comment Share on other sites More sharing options...
Rolig Loon Posted February 21, 2018 Share Posted February 21, 2018 Use the HUD script to send a chat message on a unique channel with llRegionSay, and use the script in your titler to receive the message on that same channel and use it as the text in llSetText. If you are a beginning scripter, take a look in the LSL wiki for example scripts (or scriptlets) in the descriptions of those functions. Link to comment Share on other sites More sharing options...
Twistted Hand Posted February 21, 2018 Author Share Posted February 21, 2018 Im not sure im getting it right. This is what i have. default { touch_start(integer total_number) { llSay(-55343,"Does this Work?"); } } and the listen... integer CommandIs(string msg,string cmd) { return llSubStringIndex(msg,cmd) == 0; } ParseAndIssueCommand(string cmd) { if (CommandIs(cmd,"")) { string name = llGetSubString(cmd,20,-1); if (name == "") llSetText("",<0,1,0>,1.0); else llSetText(name,<0,1,0>,1.0); } } default { state_entry() { llListen(-55343,"",llGetOwner(),""); } on_rez(integer start_param) { llResetScript(); } listen(integer channel, string name, key id, string msg) { ParseAndIssueCommand(msg); } } // END // Link to comment Share on other sites More sharing options...
Scaler Rexen Posted February 21, 2018 Share Posted February 21, 2018 (edited) You've honestly got so much extra stuff. I will write you a more simple example and explain it. The message sender yours is good. default { touch_start(integer total_number) { llSay(-55343,"Does this Work?"); // Send the text on channel -55343 } } And secondly the receiver. default { on_rez(integer p) { llResetScript(); // Reset the script on attach / rez. } state_entry() { llListen(-55343,"","",""); // Allow the object to hear a command/message on channel -55343. } listen(integer channel, string name, key id, string message) { llSetText(message,<1,1,1>,1); // This takes the variable 'message' from the listen event which is filled with what was said on that channel spcified above placing it above with llSetText(); } } The receiver does not filter out anything it takes any message from anyone and puts it above as long as it's on your channel. Edited February 21, 2018 by Scaler Rexen Link to comment Share on other sites More sharing options...
Recommended Posts
Please take a moment to consider if this thread is worth bumping.
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now