Difference between revisions of "LlSetTouch"

From Second Life Wiki
Jump to navigation Jump to search
(New page: THIS FUNCTION DOES NOT EXIST LlSetTouch would be a nice function to limit the touch to certain specified avatars. syntax: llSetTouch(key id); Note: This limits the possibility to to...)
 
Line 8: Line 8:
Useful to prevent simultaneous clicks by different Avatars on the same moment on the same object.
Useful to prevent simultaneous clicks by different Avatars on the same moment on the same object.


example:
''example:''


default
default

Revision as of 19:55, 23 September 2007

THIS FUNCTION DOES NOT EXIST LlSetTouch would be a nice function to limit the touch to certain specified avatars.

syntax: llSetTouch(key id);


Note: This limits the possibility to touch an object to the passed key id. Useful to prevent simultaneous clicks by different Avatars on the same moment on the same object.

example:

default {

state_entry()
 {
   llSetTouch(llGetOwner()); // only the boss may click!
 }
touch(integer num_detected);
{ 
  llSay(0, "Hi BOSS"); 
}

}