Arma 3 Scripting

BIS_fnc_nearestRoad

  • Arma 3 v0.76

Function · Markdown · JSON · original wiki page

Description

Find the nearest road segment to certain position, within given radius.

Syntax

[centre, radius, blacklist] call BIS_fnc_nearestRoad

Parameters:

Returns: Object - nearest road object, objNull if not found

Examples

Example 1

private _nearestRoad = [getPosATL player, 500] call BIS_fnc_nearestRoad;

Example 2

private _nearestRoad = [getPosATL vehicle player, 50, getPosATL vehicle player nearRoads 20] call BIS_fnc_nearestRoad;

See also

nearRoads · isOnRoad · roadAt · roadsConnectedTo