Find out the nearest entity parsed in an array to a position.
Compares the distance between entity’s in the parsed array.
_position | <MARKER, OBJECT, LOCATION, GROUP, TASK or POSITION> |
_array | ARRAY of <MARKER, OBJECT, LOCATION, GROUP, TASK and/or POSITION> |
_radius | Maximum distance from _position <NUMBER> |
_code | Condition to meet, object is stored in _x variable <CODE> |
_nearestVeh = [player, vehicles] call CBA_fnc_getNearest _nearestGroups = [[0,0,0], allGroups, 50, {count (units _x) > 1}] call CBA_fnc_getNearest
Nearest given entity or List of entities within given distance
Rommel