# How to add weapon

## How to add a weapon? (for ESX)

{% hint style="danger" %}
It's important to have type="WEAPON" and also ammo count and don't forget about the label.
{% endhint %}

```lua
 {
     name = 'WEAPON_PISTOL',
     label = 'Pistol',  --IMPORTANT
     price = 15.0,
     amount = 1,
     ammo = 50, --IMPORTANT
     type = 'WEAPON',  --IMPORTANT
     weight = 2.0, --If using weight system
 }, 
```

## How to add a weapon? (For QBCore)

{% hint style="danger" %}
QBCore has weapons as an item so there is no need to add "type = 'weapon'" like displayed above.
{% endhint %}

```lua
 {
     name = 'WEAPON_PISTOL',
     label = 'Pistol',
     price = 15.0,
     amount = 1,
     weight = 2.0, 
 }, 
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://documentation.rcore.cz/paid-resources/rcore_shops/how-to-add-weapon.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
