Page tree
Skip to end of metadata
Go to start of metadata


Introduced in

Version:3.6

Description

Description:Returns the outline definition used in a setTriggerAreaPolygonal.

Syntax

Syntax:trigger triggerAreaPolygonal absolute
Parameters:
  • trigger: Object
  • absolute: Boolean - If true, then the points will be returned as absolute map positions, if false, then they are relative to the trigger position itself.
Return Value:Array of Position-2 - If 'absolute', then the z-values are the PositionASL elevations, if 'relative', then z is always 0.
If the trigger area is not a polygon, then an empty array is returned.

Examples

Examples:
_path = trg1 triggerAreaPolygonal true;
// might return [[2400,2500,20],[2500,2600,21],[2600,2500,20]]
_path = trg2 triggerAreaPolygonal false;
// might return [[-2,0,0],[0,2,0],[2,0,0]]

Additional Information

See also: setTriggerAreaPolygonal, triggerArea
Multiplayer:If the trigger area was set without publicExec'ing the command, then triggerAreaPolygonal will always return just an empty array (the same as if no polygon area had been defined).
If publicExec was used, then the correct area values will be returned, even for non-local triggers.
Problems: 

Notes