{"name":"isWeaponDeployed","title":"isWeaponDeployed","type":"command","url":"https://community.bistudio.com/wiki/isWeaponDeployed","revid":321095,"updated":"2022-05-13T13:54:06Z","groups":["Weapons"],"status":"ok","games":{"arma3":"1.42"},"since":"arma3 1.42","arma3_since":"1.42","locality":{"argument":"global"},"description":"Returns true if weapon is currently deployed.","syntaxes":[{"syntax":"isWeaponDeployed unit","params":[{"name":"unit","type":"Object","type_expr":"Object"}],"returns":{"type":"Boolean","type_expr":"Boolean"},"form":"unary","right":{"text":"unit"}},{"syntax":"isWeaponDeployed [unit, onGround]","since":"arma3 2.06","params":[{"name":"unit","type":"Object","type_expr":"Object"},{"name":"onGround","type":"Boolean","optional":true,"description":"true to check if deployed on ground, false to check if deployed on object. Omitted - same as main syntax.","type_expr":"Boolean","text":"onGround: Boolean - (Optional) true to check if deployed on ground, false to check if deployed on object. Omitted - same as main syntax."}],"returns":{"type":"Boolean","type_expr":"Boolean"},"form":"unary","right":{"text":"[unit, onGround]"}}],"examples":[{"code":["_dep = isWeaponDeployed player;"]},{"code":["_depOnObj = isWeaponDeployed [player, false];"]}],"see_also":["isWeaponRested","canDeployWeapon"],"notes":[{"user":"AgentRev","date":"2015-07-01T16:44:00Z","text":"You can force a unit out of bipod or resting with:\n\n```sqf\n_unit playMove \"\";\n```"},{"user":"Beno 83au","date":"2017-03-04T03:58:00Z","text":"playMove, as well as switchMove, appears to not work when forcing a player out of being deployed. A more reliable method is:\n\n```sqf\n_player setPos (_player modelToWorld [0,0,0]);\n```"}]}