inAreaArrayIndexes

From Bohemia Interactive Community
Revision as of 19:40, 20 February 2023 by Lou Montana (talk | contribs) (Some wiki formatting)
Jump to navigation Jump to search
Hover & click on the images for description
Only available in Development branch(es) until its release with Arma 3 patch v2.14.

Description

Description:
Returns positions' indices that are within the provided area.
Groups:
TriggersMarkersLocationsPositionsGroups

Syntax

Syntax:
positions inAreaArrayIndexes area
Parameters:
positions: Array of Objects and/or Positions and/or Locations and/or Strings and/or Groups, where:
area: Array or Object or Location or String, where:
  • Array - in format [center, a, b, angle, isRectangle, c] or polygon in format [point1, point2, point2, ...]
  • Object - trigger
  • Location - location
  • String - marker
Return Value:
Array of Numbers - indices of positions's matching elements

Examples

Example 1:
private _players = call BIS_fnc_listPlayers; private _indices = _players inAreaArrayIndexes _marker; { private _player = _players select _x; ["You are in the marker!"] remoteExec ["hint", _player]; } forEach _indices;

Additional Information

See also:
inAreaArray inArea triggerArea

Notes

Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note