categories
The category files in categories/ - display name, menu title, entries and potion entries.
Every .yml file directly inside categories/ is one category. After editing, run
/indexadmin reload. For a walkthrough, see Creating Categories.
File layout
Section titled “File layout”Display-Name: "&d&lPotions Category"Title: "Potions Category"
Entries: - {Material: POTION, Potion-Type: AWKWARD, Name: "Awkward Potion"} - {Material: POTION, Potion-Type: HEALING, Name: "Potion of Healing"} - {Material: SPLASH_POTION, Potion-Type: HEALING, Name: "Splash Potion of Healing"} - {Material: TIPPED_ARROW, Potion-Type: POISON, Name: "Tipped Arrow Poison"}| Key | Required | Description |
|---|---|---|
| (file name) | - | The category id, e.g. potions for potions.yml. Used by Category: in the main menu and by %optimalindex_category_<id>%. Keep it lower case. |
Display-Name |
yes | The category’s name, used for {category} in menus and messages. |
Title |
yes | The title of the category’s menu. Takes {player}, {viewer}, {target}, {category}, {collected}, {category-total} and {category-percentage}. It is set when the menu opens. |
Entries |
yes | The ordered list of entries. The menu shows them in this order. |
Files in subfolders are not read.
Entries
Section titled “Entries”An entry is one of two forms.
Material name. Any obtainable item name (OAK_LOG, diamond_sword). The entry is named
<lang:...> with the item’s translation key, so each client shows the item in its own language.
Entries: - OAK_LOG - OAK_WOOD - STRIPPED_OAK_LOGSection. Sets your own name and, optionally, a potion type.
| Key | Required | Description |
|---|---|---|
Material |
yes | The item. |
Name |
yes | The entry’s name ({item} in menus and in DISCOVERED). Formatting codes work. |
Potion-Type |
no | A potion type such as SWIFTNESS, LONG_SWIFTNESS or STRONG_SWIFTNESS. Only allowed on POTION, SPLASH_POTION, LINGERING_POTION and TIPPED_ARROW. |
Entries: - {Material: LINGERING_POTION, Potion-Type: LONG_SWIFTNESS, Name: "Lingering Potion of Swiftness (Extended)"} - {Material: DRAGON_EGG, Name: "&5&lDragon Egg"}Potion-typed entries render in the potion’s colour in the menu.
Entry keys
Section titled “Entry keys”Every entry has a key, used by /indexadmin discover and /indexadmin reset and stored in the
database:
| Entry | Key |
|---|---|
OAK_LOG |
oak_log |
{Material: SPLASH_POTION, Potion-Type: LONG_SWIFTNESS, …} |
splash_potion:long_swiftness |
{Material: TIPPED_ARROW, Potion-Type: HEALING, …} |
tipped_arrow:healing |
A held item matches exactly one key. A potion with a base type only matches the entry with that
type, and a plain POTION entry only matches a potion without one.
- One entry across categories. The same key in several files is one entry. It counts once towards
the index total and fills every category it is in. In the section form it must have the same
Nameeverywhere, or the load fails. - No duplicates in one file. Listing the same key twice in one category fails the load.
- Obtainable items only. Air and items that cannot exist in an inventory fail the load, as does an unknown material name.
- Load errors stop the reload. The console names the file and the offending entry.
Shipped categories
Section titled “Shipped categories”| File | Display name |
|---|---|
building.yml |
Building Category |
colorful.yml |
Colorful Category |
natural.yml |
Natural Category |
functional.yml |
Functional Category |
redstone.yml |
Redstone Category |
tools.yml |
Tools & Utilities Category |
combat.yml |
Combat Category |
food.yml |
Food & Drinks Category |
ingredients.yml |
Ingredients Category |
potions.yml |
Potions Category |
The folder is only generated when it is missing, so deleting a shipped category file keeps it deleted.
Remove its button from guis/main-menu.yml too, or the load fails.
