---
name: "addItem"
type: command
status: ok
groups: ["Unit Inventory"]
arma3_since: "0.50"
locality: {"argument": "global", "effect": "global", "server_exec": false}
source: https://community.bistudio.com/wiki/addItem
revid: 369269
updated: 2024-09-03T18:42:43Z
---

# addItem

*Command · Unit Inventory · Arma 3 v0.50*

Locality: arguments **global** · effect **global**

## Description

Creates new item and tries to add it into inventory. Inventory must have enough space to accomodate new item or command will fail.The item can also be a weapon or a magazine.

## Syntax

```sqf
unit addItem item
```

**Parameters:**

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

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

## Examples

### Example 1

```sqf
// identical to bluforUnit linkItem "NVGoggles"
// addItem then assignItem makes the item go through through inventory storage and fail if storage space was missing
bluforUnit addItem "NVGoggles";
bluforUnit assignItem "NVGoggles";

opforUnit addItem "NVGoggles_OPFOR";
opforUnit assignItem "NVGoggles_OPFOR";

independentUnit addItem "NVGoggles_INDEP";
independentUnit assignItem "NVGoggles_INDEP";
```

## See also

[removeItem](../commands/removeItem.md) · [assignItem](../commands/assignItem.md) · [unassignItem](../commands/unassignItem.md) · [assignedItems](../commands/assignedItems.md) · [linkItem](../commands/linkItem.md) · [unlinkItem](../commands/unlinkItem.md) · [removeAllAssignedItems](../commands/removeAllAssignedItems.md) · [addItemToUniform](../commands/addItemToUniform.md) · [addItemToVest](../commands/addItemToVest.md) · [addItemToBackpack](../commands/addItemToBackpack.md)

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