User:Toy Wylie/RLV Documentation/sendchat

From Second Life Wiki
< User:Toy Wylie‎ | RLV Documentation
Revision as of 12:41, 7 July 2010 by Toy Wylie (talk | contribs) (added note about @emote)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search


@sendchat

Type

Restriction

Implemented

Implemented since RLV version 1.0b

Usage

@sendchat=<y/n>

Purpose

When prevented, everything typed on channel 0 will be discarded. However, emotes and messages beginning with a slash ('/') will go through, truncated to strings of 30 and 15 characters long respectively (likely to change later). Messages with special signs like ()"-*=_^ are prohibited, and will be discarded. When a period ('.') is present, the rest of the message is discarded. Use the @emote exception command to allow full-length emoting.


See Also

Example

<lsl>integer restricted = FALSE;

default {

   touch_start(integer total_number)
   {
       if (llDetectedKey(0) != llGetOwner()) return;

       restricted = 1-restricted;

       if(restricted)
       {
           llOwnerSay("@sendchat=n");
           llSay(0, "Chat blocked, say something ;)");
       }
       else
       {
           llOwnerSay("@sendchat=y");
           llSay(0, "Chat unrestricted.");
       }
   }

}

</lsl>