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



Introduced in

Version:1.00

Description

Description:Returns the position where a line originating at the specified location, and with a defined direction, would intersect with the ground (or a water surface). Any objects (such as buildings, and so on) are ignored.

Syntax

Syntax:origin getGroundIntercept direction
Parameters:
Return Value:PositionASL - Ground intercept position. V1.24+: if no ground is intercepted (vector points at the sky), [0,0,0] is returned.

Alternative Syntax

Syntax:origin getGroundIntercept [direction, considerSnow] (V3.6+)
Parameters:
Return Value:PositionASL - Ground intercept position. V1.24+: if no ground is intercepted (vector points at the sky), [0,0,0] is returned.

Examples

Examples:
_intercept = player getGroundIntercept (player weaponDirection (primaryWeapon player))
_intercept = player getGroundIntercept [player weaponDirection (primaryWeapon player), true]

Additional Information

See also: getGroundInterceptASL, lineIntersects
Multiplayer: 
Problems: 

Notes