> For the complete documentation index, see [llms.txt](https://ajneb97.gitbook.io/minewords/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/minewords/inventory.yml-tutorial.md).

# Inventory.yml Tutorial

Here you can modify aspects of the inventories of MineWords.

## Inventories

There are different inventories on the plugin:

* **main\_inventory:** Main inventory opened using the `/minewords` command. Categories will appear here. You can even create more inventories like this one.
* **category\_\<category>:** You must create an inventory per category, replacing the `<category>` tag with the name of the category. For example, `category_easy` represents the inventory for the `easy` category (easy.yml file). If you create a new category file, for example `"very_hard.yml"`, then you must add a new inventory on the inventory.yml file called `category_very_hard`.

{% hint style="info" %}
The main\_inventory inventory must not be removed from the inventory.yml file. You can create your own inventories following the same format under the inventories path. if you need to.
{% endhint %}

## Inventories Properties <a href="#inventories-properties" id="inventories-properties"></a>

Each inventory has 3 properties show below:

```yaml
inventories:
  main_inventory:
    slots: 27
    title: "&4&lMineWords &8- &4Categories"
    0-8;9;17;18-26:
      item:
        id: BLACK_STAINED_GLASS_PANE
        name: " "
    11:
      type: "category: easy"
    12:
      type: "category: normal"
    13:
      type: "category: hard"
    15:
      type: word_of_the_day
```

### **Slots**

Defines the amount of slots this inventory will have. You can only use 9, 18, 27, 36, 45 or 54.

### **Title**

Defines the title of this inventory.

### **Item Slot**

Position of an item in the inventory. For a much simpler way of placing items on inventories you can use some formats:

#### **Format 1**

```yaml
<slot>:
  <item>
```

This will set an item on the slot 0.

```yaml
0:
  item: 
    id: BLACK_STAINED_GLASS_PANE
    name: " "
```

#### **Format 2**

```yaml
<slot1>;<slot2>;<slotN>:
  <item>
```

This will set the same item on slots 0, 8 and 16.

```yaml
0;8;16:
  item: 
    id: BLACK_STAINED_GLASS_PANE
    name: " "
```

#### **Format 3**

```
<slot1>-<slotN>:
  <item>
```

This will set the same item from slots 0 to 8 (0, 1, 2, 3, 4, 5, 6, 7, 8).

```yaml
0-8:
  item: 
    id: BLACK_STAINED_GLASS_PANE
    name: " "
```

#### **Combining formats**

This will set the same item on slots 0 to 7, 9, and 17 to 26.

```yaml
0-7;9;17-26:
  item: 
    id: BLACK_STAINED_GLASS_PANE
    name: " "
```

## Item Slots Properties <a href="#item-slots-properties" id="item-slots-properties"></a>

On these item slots you can create your own items.

### **Item**

This is the item itself. Use the guide from [**HERE** ](#item)to create them.

```yaml
0-8;9;17;18-26:
  item:
    id: "BLACK_STAINED_GLASS_PANE"
    name: " "
```

### **Open Inventory**

Add this option to open another created inventory when the player clicks on this item.

```yaml
36:
      item:
        id: ARROW
        name: "&7Go back"
      open_inventory: main_inventory
```

### **Click Actions**

Adds a list of actions to be executed when clicking on the item. List of actions [**HERE**](/minewords/actions.md).

```yaml
36:
   item:
     id: "ARROW"
     name: "&7Go Back to an external Inventory"
   click_actions:
   - "message: &aOpening the main server menu" 
   - "console_command: chestcommands open %player% menu_server"
```

### **Type: Category**

You can place a [**category display item**](/minewords/levels-categories-tutorial.md#category-items) on the GUI by using the `type: category` option. If you do so, all other item properties are ignored. \
Format: `type: "category: <category_name>"`

```yaml
22:
   type: "category: easy"
```

### Type: Level

You can place a [**level display item**](/minewords/levels-categories-tutorial.md#level-items) on the GUI by using the `type: level` option. If you do so, all other item properties are ignored. \
Format: `type: "level: <level_number>"`

{% hint style="warning" %}
You can only use this type of item inside a `category_<category>` inventory.
{% endhint %}

```yaml
11:
   type: "level: 2"
```

### Type: Word of the Day

The item will be replaced by the [**word of the day display item**](/minewords/word-of-the-day-tutorial.md).

```yaml
15:
   type: word_of_the_day
```
