---
name: "getAttackTarget"
type: command
status: ok
groups: ["Object Manipulation"]
arma3_since: "2.00"
locality: {"argument": null, "effect": null, "server_exec": false}
source: https://community.bistudio.com/wiki/getAttackTarget
revid: 309248
updated: 2022-05-04T10:46:28Z
---

# getAttackTarget

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

## Description

Returns the target given unit is engaging.

## Syntax

```sqf
getAttackTarget unit
```

**Parameters:**

- `unit`: [Object](../topics/Object.md)

**Returns:** [Object](../topics/Object.md)

## Examples

### Example 1

```sqf
private _unitsTarget = getAttackTarget _unit;
```

## See also

[assignedTarget](../commands/assignedTarget.md)

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