---
name: "getAnimationsQueue"
type: command
status: ok
groups: ["Object Manipulation"]
arma3_since: "2.22"
locality: {"argument": "global", "effect": null, "server_exec": false}
source: https://community.bistudio.com/wiki/getAnimationsQueue
revid: 378279
updated: 2026-03-31T10:03:56Z
---

# getAnimationsQueue

*Command · Object Manipulation · Arma 3 v2.22*

Locality: arguments **global**

## Description

Returns the primary and secondary animations queue of the entity. The primary queue contains the full motion path from current animation ([animationState](../commands/animationState.md)) to a target animation, while the secondary queue contains animations that are queued to be played after the target animation in primaryQueue is reached, e.g. due to using [playMove](../commands/playMove.md) or [playAction](../commands/playAction.md).

## Syntax

```sqf
getAnimationsQueue entity
```

**Parameters:**

- `entity`: [Object](../topics/Object.md) - Man or animal object.

**Returns:** [Array](../topics/Array.md) - in format [primaryQueue, secondaryQueue] where each queue is an [Array](../topics/Array.md) of [String](../topics/String.md)s, the animation state names (all lower case).

## Examples

### Example 1

```sqf
getAnimationsQueue player params ["_primaryQueue", "_secondaryQueue"];
if (_secondaryQueue isNotEqualTo []) then { 
    private _targetAnim = _primaryQueue param [count _primaryQueue - 1, animationState player];
    private _nextAnim = _secondaryQueue#0;
    systemChat format ["Will play '%1' after completing '%2'", _nextAnim, _targetAnim]; 
};
```

### Example 2

```sqf
player playMove _myMove; // push an animation state to the secondary queue
player playAction "WalkF"; // an action that gets mapped to an animation state and pushed to queue
getAnimationsQueue player params ["_primaryQueue", "_secondaryQueue"];
// _secondaryQueue will contain _myMove and the animation that the "WalkF" action maps to
```

## See also

[animationState](../commands/animationState.md) · [getUnitMovesInfo](../commands/getUnitMovesInfo.md)

<sub>Source: [BI Community Wiki — getAnimationsQueue](https://community.bistudio.com/wiki/getAnimationsQueue) (revision 378279).</sub>
