> For the complete documentation index, see [llms.txt](https://ajneb97.gitbook.io/complexturrets/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://ajneb97.gitbook.io/complexturrets/turrets-tutorial-items.md).

# Turrets Tutorial: Items

{% hint style="info" %}
1.16 Item IDs: <https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Material.html>\
1.8 Item IDs: <https://github.com/Attano/Spigot-1.8/blob/master/org/bukkit/Material.java>
{% endhint %}

{% hint style="info" %}
You can use the following option in all items:\
`custom_model_data: <value>`

Custom Model Component Data (1.21.4+):\
`custom_model_component_data:` \
&#x20; `strings:`\
&#x20; `- "<value1>"`\
&#x20; `flags:`\
&#x20; `- "<value1>"`\
&#x20; `- "<value2>"`\
&#x20; `floats: []` \
&#x20; `colors: []`

Item Model (<https://minecraft.wiki/w/Items_model_definition>, 1.21.4+):\
`item_model: "<namespace>:<id>"`
{% endhint %}

## Main Items

### Block Item

It's the block players will receive from the `/ct give <turret> <player>` command. You can use the following variables in the lore of the item: `%upgrade_level%, %min_damage%, %max_damage%, %min_heal%, %max_heal%, %speed%, %range%, %health%, %splash_radius%, %max_targets%, %accuracy%, %max_ammo%, %action_<action>_probability%, %action_<action>_duration%, %critical_chance%`

You can also use `%fire_rate%` which will show how many shots the turret do in 1 second.

```
block:
    id: "COAL_BLOCK"
    name: "&aBurst Turret &6Block"
    lore:
    - "&7Fast speed turret with no extra abilities."
    - ""
    - "&8» &7Level: &e%upgrade_level%"
    - "&8» &7Damage: &a%min_damage%&7-&a%max_damage%"
    - "&8» &7Cooldown: &a%speed% seconds"
    - "&8» &7Range: &a%range% blocks"
```

### Ammunition Item

It's the item players will receive from the `/ct giveammo <turret> <player> <amount>` command. These items must be placed inside the turret ammunition inventory.

```
ammunition:
    id: "GHAST_TEAR"
    name: "&6Burst Turret &7Ammunition"
    lore:
    - "&7Place this item in your turret inventory"
    - "&7to start shooting."
```

## Inventory Items

### Upgrade Item

This is the item the player needs to click to upgrade the turret inside the turret inventory. You can use the same variables as the ones in [Block Item](/complexturrets/turrets-tutorial-items.md#block-item) but adding a `current` or `next` before. You can also use the `%money_cost%` variable and the `%item_cost%` variable.

```
upgrade:
    id: "EMERALD"
    name: "&aBurst Turret &eUpgrade"
    lore:
    - "&7Level: &e&l%current_level%&8 ➜ &e&l%next_level%"  
    - "&7Damage: &a%current_min_damage%&7-&a%current_max_damage%&8 ➜ &a%next_min_damage%&7-&a%next_max_damage%"
    - "&7Cooldown: &a%current_speed%(s)&8 ➜ &a%next_speed%(s)"
    - "&7Range: &a%current_range% blocks&8 ➜ &a%next_range% blocks"
    - "&7Health: &a%current_health%&8 ➜ &a%next_health%"
    - ""
    - "&7Cost: &6$%money_cost%"
    - ""
    - "&8[Click to Upgrade to Level &e&l%next_level%&8]"  
```

### Last Upgrade Item

The same item as before but when the turret is at the max level.

```
last_upgrade:
    id: "REDSTONE"
    name: "&aBurst Turret &eUpgrade"
    lore:
    - "&7Level: &e&l%current_level%"  
    - "&7Damage: &a%current_min_damage%&7-&a%current_max_damage%"
    - "&7Cooldown: &a%current_speed%(s)"
    - "&7Range: &a%current_range% blocks"
    - "&7Health: &a%current_health%"
    - ""
    - "&7No more Upgrades available" 
```
