---
name: "getHit"
type: command
status: ok
groups: ["Object Manipulation"]
arma3_since: "1.32"
locality: {"argument": "global", "effect": null, "server_exec": false}
source: https://community.bistudio.com/wiki/getHit
revid: 340840
updated: 2023-05-10T13:56:15Z
---

# getHit

*Command · Object Manipulation · Arma 3 v1.32*

Locality: arguments **global**

## Description

Returns selection damage. Same as [getHitPointDamage](../commands/getHitPointDamage.md), only the argument is selection part instead of hit point.

> [!NOTE]
> Some part names are in Czech; see the translation table.

## Syntax

```sqf
vehicle getHit selection
```

**Parameters:**

- `vehicle` : [Object](../topics/Object.md) - vehicle to be queried
- `selection`: [String](../topics/String.md) - selection part name

**Returns:** [Number](../topics/Number.md) - before Arma 3 v1.94, [Nothing](../topics/Nothing.md) was returned when an invalid *selection* was provided (now returns `0`)

## Examples

### Example 1

```sqf
hint str (player getHit "head");
```

### Example 2

```sqf
private _engineDamage = _car getHit "motor";
```

## See also

[setHit](../commands/setHit.md) · [getHitPointDamage](../commands/getHitPointDamage.md) · [setHitPointDamage](../commands/setHitPointDamage.md) · [setDamage](../commands/setDamage.md) · [damage](../commands/damage.md) · [getHitIndex](../commands/getHitIndex.md) · [setHitIndex](../commands/setHitIndex.md)

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