Tankbuster
Note that this function returns a 2D position, that is, an array containing an x and a y value, but no z (no altitude).
Results appear below as you type; use the arrow keys to move through them.
Selects a position that provides overwatch onto another position.
[target, maxDistance, minDistance, minHeightAbove, searchCentre] call BIS_fnc_findOverwatch
Parameters:
target: Position3D - not an objectmaxDistance: Number - (Optional, default 500) maximum distance from target in metersminDistance: Number - (Optional, default 100) minimum distance from target in metersminHeightAbove: Number - (Optional, default 50) minimum height in relation to target in meterssearchCentre: Position3D - (Optional, default target) position to start looking from, if different from target posReturns: Position - target position if no result were found
[getPosATL enemyTank, 300, 75, 20, getPosATL player] call BIS_fnc_findOverwatch;
Note that this function returns a 2D position, that is, an array containing an x and a y value, but no z (no altitude).
Further note that when this function fails to find an overwatch position and returns the target, the x and y components will be exactly the same, but the z might not be.