Arma 3 Scripting

Command in Weapons

isWeaponDeployed

Also available as Markdown and JSON, or read the original wiki page.

Description

Returns true if weapon is currently deployed.

Syntax

Syntax 1

isWeaponDeployed unit

Parameters:

Returns: Boolean

Syntax 2

since arma3 2.06

isWeaponDeployed [unit, onGround]

Parameters:

Returns: Boolean

Examples

Example 1

_dep = isWeaponDeployed player;

Example 2

_depOnObj = isWeaponDeployed [player, false];

See also

isWeaponRested · canDeployWeapon

Community notes

AgentRev

You can force a unit out of bipod or resting with:

_unit playMove "";
Beno 83au

playMove, as well as switchMove, appears to not work when forcing a player out of being deployed. A more reliable method is:

_player setPos (_player modelToWorld [0,0,0]);