llEvade
function
Function syntax
llEvade(key target,// UUID of the group, avatar, or object to evade.list options// No options currently available (should be empty list).
);- Energy
- 10
Characters will (roughly) try to hide from their pursuers if there is a good hiding spot along their fleeing path. Hiding means no direct line of sight from the head of the character (center of the top of its physics bounding box) to the head of its pursuer and no direct path between the two on the navmesh.
llEvade(NULL_KEY, []);Caveats
Section titled “Caveats”-
Must use
llCreateCharacteror script will shout an error “You must callllCreateCharacterbeforellEvade.”. -
If the target is an object, it must be unlinked or be the root prim of a linkset.
Examples
Section titled “Examples”Example 1
18 collapsed lines
vector start_position;
default{ on_rez(integer start_param) { llResetScript(); }
state_entry() { llDeleteCharacter(); llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
start_position = llGetPos(); llWanderWithin(start_position, <10.0, 10.0, 2.0>, [] ); }
touch_start(integer num_detected) { llEvade(llDetectedKey(0), []); llSetTimerEvent(20.0); }9 collapsed lines
timer() { // do not keep running away... llSetTimerEvent(0.0);
llWanderWithin(start_position, <10.0, 10.0, 2.0>, [] ); }}History
Section titled “History”Date of Release 31/07/2012
See also
Section titled “See also”Functions
Section titled “Functions”llCreateCharacterllDeleteCharacterllEvadellExecCharacterCmdllGetClosestNavPointllFleeFromllNavigateTollPatrolPointsllPursuellUpdateCharacterllWanderWithin
Events
Section titled “Events”Original wiki source
Some wiki templates and tables need their original context. View this article on the Second Life Wiki. Technical wording and examples are retained from the source; historical guidance may differ from current behavior.