RuthvenWillenov

plugin group message for lucky chair

Jun 14th, 2017
119
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. key group;
  2. string url = "secondlife:///app/group/";
  3. default
  4. {
  5.     state_entry()
  6.     {
  7.         list dets = llGetObjectDetails(llGetKey(),[OBJECT_GROUP]);
  8.         group = llList2Key(dets,0);
  9.     }
  10.     changed(integer change)
  11.     {
  12.         if(change & CHANGED_LINK)
  13.         {
  14.             key av = llAvatarOnSitTarget();
  15.             if(av)
  16.             {
  17.                 if(!llSameGroup(av))
  18.                 {
  19.                     llSleep(0.5);//to give the chair time to send it's default message first
  20.                     llRegionSayTo(av,0,"Please join " + url + (string)group + "/about to use this chair");
  21.                 }
  22.             }
  23.         }
  24.     }
  25. }
Add Comment
Please, Sign In to add comment