{"name":"allUnits","title":"allUnits","type":"command","url":"https://community.bistudio.com/wiki/allUnits","revid":377076,"updated":"2026-01-01T09:38:35Z","groups":["Object Detection"],"status":"ok","games":{"arma2":"1.00","arma2oa":"1.50","tkoh":"1.00","arma3":"0.50"},"since":"arma2 1.00","arma3_since":"0.50","description":"Returns a list of all units, **except agents, dead units or units waiting for respawn**, outside and inside vehicles that were created on the following sides east, west, independent and civilian.\n\n> [!NOTE]\n> **Arma 3:** To get all units of given side, use `units Side`.","syntaxes":[{"syntax":"allUnits","params":[],"returns":{"type":"Array of objects","type_expr":"Array<Object>"},"form":"nullary"}],"examples":[{"code":["{ _x setDamage 0.5; _x groupChat \"Braaains\"; } forEach allUnits;"]},{"code":["allUnits apply { diag_log _x; };"]}],"see_also":["allGroups","groups","units","vehicles","entities","agents","playableUnits","switchableUnits","allPlayers","allDead","allDeadMen","allUnitsUAV","allCurators","allObjects","allMissionObjects","allSimpleObjects","allMines"],"notes":[{"user":"Pierre MGI","date":"2018-09-06T16:43:00Z","text":"It returns also BIS_SUPP_HQ created by support modules and headquarters Entity from HQ modules."}]}