Difference between revisions of "No sensor"

From Second Life Wiki
Jump to navigation Jump to search
m
m
Line 8: Line 8:
|caveats=*The script must have a [[sensor]] event, without it [[no_sensor]] will not be triggered. An empty [[sensor]] event is enough to satisfy this condition and cause [[no_sensor]] to be triggered.
|caveats=*The script must have a [[sensor]] event, without it [[no_sensor]] will not be triggered. An empty [[sensor]] event is enough to satisfy this condition and cause [[no_sensor]] to be triggered.
|examples=
|examples=
<lsl>
<lsl>//List all avatars in range.
//List all avatars in range.
default {
default {
     on_rez(integer i) {
     on_rez(integer i) {
Line 23: Line 22:
           llOwnerSay("No avatars in range.");
           llOwnerSay("No avatars in range.");
     }
     }
}
}</lsl>
</lsl>


|helpers
|helpers

Revision as of 11:33, 25 May 2008

Description

Event: no_sensor( ){ ; }

Result of a call to llSensor or llSensorRepeat.


Caveats

  • The script must have a sensor event, without it no_sensor will not be triggered. An empty sensor event is enough to satisfy this condition and cause no_sensor to be triggered.
All Issues ~ Search JIRA for related Bugs

Examples

<lsl>//List all avatars in range. default {

    on_rez(integer i) {
         llSensor("", "", AGENT, 100000, 10000);
    }
    sensor(integer num) {
         integer i = 0;
         do {
              llOwnerSay(llDetectedName(i) + " is " + (string)llVecDist(llGetPos(), llDetectedPos(i)) + "m away.");
         }while(++i < num);
    }
    no_sensor() {
         llOwnerSay("No avatars in range.");
    }

}</lsl>

See Also

Functions

•  llSensor
•  llSensorRepeat

Deep Notes

Signature

event void no_sensor(  );