Difference between revisions of "LlSensorRemove"
Jump to navigation
Jump to search
m |
m |
||
Line 20: | Line 20: | ||
llOwnerSay("Detected to: "+llKey2Name(llDetectedKey(0))); //Detects the name of the agent. | llOwnerSay("Detected to: "+llKey2Name(llDetectedKey(0))); //Detects the name of the agent. | ||
llSensorRemove(); //Removes the sensor. | llSensorRemove(); //Removes the sensor. | ||
//This does the sensor search for an agent once. | |||
} | } | ||
no_sensor() | no_sensor() |
Revision as of 18:47, 19 August 2010
LSL Portal | Functions | Events | Types | Operators | Constants | Flow Control | Script Library | Categorized Library | Tutorials |
Summary
Function: llSensorRemove( );30 | Function ID |
0.0 | Forced Delay |
10.0 | Energy |
Removes the sensor setup by llSensorRepeat.
There are no parameters or return value for this function, as only one llSensorRepeat can be specified per prim.
Caveats
Examples
<lsl> default {
state_entry() { llSensorRepeat("", "", AGENT, 5, PI, 1); //Searches the agent in the range. 5 is the range (in meters). } sensor(integer num_detected) { llOwnerSay("Detected to: "+llKey2Name(llDetectedKey(0))); //Detects the name of the agent. llSensorRemove(); //Removes the sensor. //This does the sensor search for an agent once. } no_sensor() { llSensorRepeat("", "", AGENT, 5, PI, 1); //If agent is not in range of sensor, this will search the agent again. }
}
</lsl>