Difference between revisions of "LlMapDestination"

From Second Life Wiki
Jump to navigation Jump to search
m
m
Line 12: Line 12:
* if '''simname''' is omitted, map will open centered on object, but '''pos''' will not be highlighted
* if '''simname''' is omitted, map will open centered on object, but '''pos''' will not be highlighted
|constants
|constants
|examples=<lsl>
|examples=<lsl>//Click the object this script is in and your map opens up in the middle of Oasis.
//Click the object this script is in and your map opens up in the middle of Oasis.
default
default
{
{
Line 20: Line 19:
           llMapDestination("Oasis", <128, 128, 0>, ZERO_VECTOR);
           llMapDestination("Oasis", <128, 128, 0>, ZERO_VECTOR);
     }
     }
}
}</lsl>
</lsl>
|helpers
|helpers
|also_functions=
|also_functions=
Line 39: Line 37:
|cat3=Avatar
|cat3=Avatar
|cat4=Touch
|cat4=Touch
|bugs=
|issues=
{{Bug|VWR-2060|'''pos''' is sometimes replaced with incorrect data (workaround included)}}
{{Bug|VWR-2060|'''pos''' is sometimes replaced with incorrect data (workaround included)}}
}}
}}

Revision as of 20:23, 30 June 2008

Summary

Function: llMapDestination( string simname, vector pos, vector look_at );
1.0 Forced Delay
10.0 Energy

Opens world map centered on simname with pos highlighted.
Only works for scripts attached to avatar, or during touch events.

• string simname Region name
• vector pos Region coordinates
• vector look_at not used

(NOTE: look_at currently does nothing)

Caveats

  • This function causes the script to sleep for 1.0 seconds.
  • if simname is omitted, map will open centered on object, but pos will not be highlighted

Examples

<lsl>//Click the object this script is in and your map opens up in the middle of Oasis. default {

    touch_start(integer num)
    {
         llMapDestination("Oasis", <128, 128, 0>, ZERO_VECTOR);
    }
}</lsl>

Notes

  • pos will work with Region coordinates not inside simname. (like those returned by llRequestInventoryData)
  • if called from an event other than touch, it only works for the owner.
  • if called from touch, it may only work for the first or last touch in the event queue (example: num_touched > 1)

See Also

Functions

•  llRequestInventoryData

Deep Notes

Signature

function void llMapDestination( string simname, vector pos, vector look_at );