{"name":"countSide","title":"countSide","type":"command","url":"https://community.bistudio.com/wiki/countSide","revid":379324,"updated":"2026-10-30T23:51:22Z","groups":["Sides","Object Detection"],"status":"ok","games":{"ofp":"1.00","ofpe":"1.00","arma1":"1.00","arma2":"1.00","arma2oa":"1.50","tkoh":"1.00","arma3":"0.50"},"since":"ofp 1.00","arma3_since":"0.50","locality":{"argument":"global"},"description":"Returns how many units in the given array belong to given side.","syntaxes":[{"syntax":"side countSide array","params":[{"name":"side","type":"Side","type_expr":"Side"},{"name":"array","type":"Array of Objects or Groups","description":"Array of Objects or Groups\n\n> [!NOTE]\n> If the object in passed array is a Group, the leader of the group will be counted.","type_expr":"Array<Object | Group>","text":"array: Array of Objects or Groups\n\n> [!NOTE]\n> If the object in passed array is a Group, the leader of the group will be counted."}],"returns":{"type":"Number","type_expr":"Number"},"form":"binary","left":{"text":"side"},"right":{"text":"array"}}],"examples":[{"code":["_num = west countSide list _triggerOne;"]},{"code":["_numCivPlayable = civilian countSide playableUnits;"]}],"see_also":["countFriendly","countEnemy","countUnknown","count","countType","playersNumber","units","allUnits"],"notes":[{"user":"AgentRev","date":"2014-10-19T01:00:00Z","text":"This command considers captive units as civilians, regardless of their group's side."}]}