{"name":"switchableUnits","title":"switchableUnits","type":"command","url":"https://community.bistudio.com/wiki/switchableUnits","revid":376986,"updated":"2026-01-01T07:13:49Z","groups":["Multiplayer","Team Switch","Object Detection"],"status":"ok","games":{"arma1":"1.00","arma2":"1.00","arma2oa":"1.50","tkoh":"1.00","arma3":"0.50"},"since":"arma1 1.00","arma3_since":"0.50","locality":{"effect":"local"},"description":"Returns a list of playable units available for switching to\n\n- Command is relative to the client on which it is executed and will only show playable units for the same side as player's group + player himself\n- In singleplayer where playable units from all sides will be accessible via this command\n- Dead and player-controlled units are automatically removed from the resulting array\n- In order to get all *playable* units regardless of their side, see the playableUnits command","syntaxes":[{"syntax":"switchableUnits","params":[],"returns":{"type":"Array of Objects","type_expr":"Array<Object>"},"form":"nullary"}],"examples":[{"code":["_availableUnits = switchableUnits;"]}],"multiplayer":"In Multiplayer, switchableUnits are only available when respawn type is set to SIDE or GROUP, the mission contains units marked playable and player is able to switch to any of those units. On dedicated servers, this command returns an empty array,.","see_also":["Team Switch","playableUnits","allPlayers","teamSwitch"]}