# 🏹 Create a Kit

## What a Kit Is

A kit is a saved inventory: armour, hotbar, contents and offhand, stored once and given to both players when a match starts. Kits live on the server, not inside a mode, so one kit can be used by as many modes as you like. Each one is saved to its own file under plugins/PhoenixDuels/kits/.

A mode only uses a kit if its loadout is set to **Premade Kit**; the other loadout types hand players their own inventory instead. See [create-a-mode](create-a-mode/ "mention").

<figure><img src="../.gitbook/assets/kits/kits.png" alt="" width="563"><figcaption><p>Editor</p></figcaption></figure>

## Creating a Kit

The kits screen lists every kit on the server. Click **Add Kit** to create one, and it opens straight into the kit's own screen.

<figure><img src="../.gitbook/assets/kits/add-kit.png" alt="" width="563"><figcaption><p>Editor > Kits</p></figcaption></figure>

<figure><img src="../.gitbook/assets/kits/kit-entry.png" alt="" width="563"><figcaption><p>Editor > Kits</p></figcaption></figure>

Turning **Reordering** on switches the list into sort mode: click one kit, then another, and the two swap places. The order set here is the order kits appear in anywhere players pick one.

<figure><img src="../.gitbook/assets/kits/reordering.png" alt="" width="563"><figcaption><p>Editor > Kits</p></figcaption></figure>

> **Warning:**
The Lite edition is limited to 5 kits. Kits beyond that are not loaded on startup.

## Identifier

The unique id of the kit, and what a mode stores when it links to it. It cannot contain spaces and cannot match another kit. Changing it later is safe from the editor, but any mode already linked to the old id has to be pointed at the new one.

<figure><img src="../.gitbook/assets/kits/identifier.png" alt="" width="563"><figcaption><p>Editor > Kits > Kit</p></figcaption></figure>

## Display

The name and icon players see wherever the kit is shown. This is display only; the identifier is what everything else refers to.

<figure><img src="../.gitbook/assets/kits/display.png" alt="" width="563"><figcaption><p>Editor > Kits > Kit</p></figcaption></figure>

## Kit Items

This is the kit itself. Left-click opens the items editor, and the lore shows how many items are currently stored. Shift + right-click skips the editor and copies your own inventory straight onto the kit, replacing whatever was there.

<figure><img src="../.gitbook/assets/kits/kit-items.png" alt="" width="563"><figcaption><p>Editor > Kits > Kit</p></figcaption></figure>

### Kit Items Editor

The editor mirrors a player inventory rather than a plain chest:

* The **top row** holds the equipment. The four slots on the left are boots, leggings, chestplate and helmet, in that order, and the slot on the right is the offhand, labelled Extra Slot.
* The **middle three rows** are the inventory contents.
* The **bottom row** is the hotbar, in the order the player will see it.

Empty slots are shown as coloured panes so the shape stays readable. Drag and drop an item onto any slot to set it, and drag it back out to clear it.

<figure><img src="../.gitbook/assets/kits/kit-items-editor.png" alt="" width="563"><figcaption><p>Kit Items Editor</p></figcaption></figure>

**Import from Inventory** fills the whole kit from what you are currently carrying, which is the fastest way to build one: gear yourself up in creative, then import.

<figure><img src="../.gitbook/assets/kits/import-from-inventory.png" alt="" width="563"><figcaption><p>Kit Items Editor</p></figcaption></figure>

**Clear All Items** empties the kit. There is no undo, so re-import or rebuild it afterwards.

<figure><img src="../.gitbook/assets/kits/clear-all-items.png" alt="" width="563"><figcaption><p>Kit Items Editor</p></figcaption></figure>

## Custom Kit Layouts

When this is on, players may reorder this kit for themselves through the [kit-editor.md](../features/kit-editor.md "mention"), keeping the same items but arranging them the way they play. Turn it off for a kit whose exact arrangement matters, such as one built around a specific hotbar slot.

<figure><img src="../.gitbook/assets/kits/custom-kit-layouts.png" alt="" width="563"><figcaption><p>Editor > Kits > Kit</p></figcaption></figure>

> **Warning:**
Custom Kit Layouts requires PhoenixDuels Premium. Creating and editing kits itself is available on every edition.

## Extended Kit

Lets players add their own extra items on top of this kit from its layout screen, picked from the [Player Kits](../add-ons/player-kits/) categories. The kit's own items always stay in the kit. The button only appears when the Player Kits add-on is installed, and the kit needs Custom Kit Layouts on.

* **Enabled** turns it on for this kit. It is off on every kit by default.
* **Allowed Categories** lists every category; click one to allow or block it. With none picked, every category is allowed, including ones added later. The last allowed category cannot be blocked.
* **Max Extra Items** caps how many extra items a player can add, from 1 to 41. The default is 9.

Changing the categories or the cap later applies at the next match: extra items over the cap or from a blocked category are left out.

> **Warning:**
Extended Kit requires PhoenixDuels Premium and the Player Kits add-on.

## Permission Requirement

Holds a permission node for this kit, together with a toggle for whether it is required. Left-click switches the toggle, right-click sets the node.

<figure><img src="../.gitbook/assets/kits/permission-requirement.png" alt="" width="563"><figcaption><p>Editor > Kits > Kit</p></figcaption></figure>

## Using the Kit in a Mode

Open the mode you want, set its **Loadout** to Premade Kit with a left-click, then right-click the same item to pick which kit it uses. The loadout shows the linked kit's id next to the type, or No kit linked if you have not chosen one yet. A mode left in that state has nothing to hand out at the start of a match, so always finish the link.

<figure><img src="../.gitbook/assets/kits/loadout-type.png" alt="" width="563"><figcaption><p>Editor > Modes > Mode</p></figcaption></figure>

Source: https://www.phoenixplugins.com/docs/phoenix-duels/main-features/create-a-kit