Skip to Content
PhantomBans is a premium plugin. Get it from the store or join the Discord.

Menus

Every in-game menu is fully editable. On first start PhantomBans creates a plugins/PhantomBans/menus/ folder with one file per menu, so you can restyle any button, move it, reskin it with a resource pack, or lay out your own filler design.

For how the menus are used in-game, see In-Game Menus.

The files

FileMenu
common.ymlShared chrome used by every menu: border filler, brand banner, target head, close button, and the previous / page / next controls for list menus.
punish.ymlThe /punish menu.
history.ymlA player’s punishment history.
staffhistory.ymlPunishments issued by a staff member.
lookup.ymlThe /lookup summary.
reports.ymlThe report queue.
appeals.ymlThe appeal queue.
staffnotes.ymlThe staff notes menu.
duration.ymlThe temp-ban / temp-mute duration picker.
reason.ymlThe reason picker (fed by preset-reasons in config.yml).
template.ymlThe punishment-template ladder picker.
confirmation.ymlThe confirm / cancel prompt.

Because the shared chrome lives in common.yml, editing the border, brand banner, close button, or page controls there changes every menu at once.

Item keys

Every item in every menu accepts the same keys:

KeyMeaning
materialBukkit material name, for example DIAMOND_SWORD or PLAYER_HEAD. Defaults to STONE.
nameMiniMessage display name.
loreA list of MiniMessage lines.
glowtrue to add an enchant shimmer.
amountStack size (default 1).
custom-model-dataA resource-pack model id. 0 or absent means none.
slotThe inventory slot (0-53).
slotsA list of slots, for items that fill several (fillers, reason and template grids).
close: slot: 8 material: BARRIER custom-model-data: 0 glow: true name: '<red><bold>Close</bold></red>' lore: - '<gray>Close this menu.</gray>'

Menu titles and row counts are configurable too, at the top of each file:

title: '<gradient:#9B30FF:#FF3A6E>Punish » {player}</gradient>' rows: 6

Colours and gradients render exactly as you write them. The default menu italic is suppressed, so a gradient set at the start of a name or lore line carries through the whole line. An explicit <italic> still works.

Filler designs

Each menu file has a fillers: block. Add as many named entries as you like, each with its own material, to build layered pane designs:

fillers: border: material: BLACK_STAINED_GLASS_PANE slots: border # the outer edge accent: material: PURPLE_STAINED_GLASS_PANE slots: [3, 5] # explicit slots

slots takes one of:

  • border - the outer edge of the menu
  • fill - every slot
  • a list like [3, 5, 21] - exactly those slots

Fillers are painted first, so your buttons always sit on top. Remove the fillers: block from a menu to fall back to the single border pane defined in common.yml.

Dynamic items

Some menus build their items from live data. Those still take all the keys above, plus a little extra:

  • History rows (history.yml, staffhistory.yml) pick their material from a materials: map by punishment type, with a default:

    entry: materials: BAN: BARRIER MUTE: PAPER KICK: LEATHER_BOOTS WARN: ORANGE_DYE default: BOOK name: '<color:#9B30FF><bold>#{id} {type}</bold></color>' removed-line: '<red>Removed by {removed_by} on {removed_at}</red>' evidence-line: '<color:#1AFFB2>Evidence: {evidence_url}</color>'

    The {removed} and {evidence} lore lines only appear when they apply.

  • Risk tiles (lookup.yml, punish.yml) pick their material from a materials: map by score tier: low, medium, high, critical.

  • Duration buttons (duration.yml) are a buttons: map where each entry has a slot and a duration (parsed, and available as {duration} in the lore). Add, remove, or reorder them freely.

  • Reason and template grids (reason.yml, template.yml) use a top-level slots: list for where the entries are placed.

Placeholders

Names and lore accept placeholders in curly braces. The useful ones per menu:

MenuPlaceholders
Any player menu title{player}
common.yml target head{name}, {uuid}
Pagination{page}, {pages}, {total}
punish.yml{ip} (ip ban), {warnings}, {alts}, {score}, {level} (risk)
history / staffhistory entry{id}, {type}, {status}, {reason}, {staff}, {target}, {date}, {duration}, {expiry}, {server}
lookup.yml{first_seen}, {last_seen}, {play_time}, {ip}, {country}, {proxy}, {score}, {level}, {value} (stat tiles)
reports.yml{id}, {target}, {reporter}, {reason}, {submitted}
appeals.yml{id}, {player}, {punishment}, {message}, {submitted}
staffnotes.yml{id}, {note}, {author}, {date}

Apply your changes

After editing any menu file, run:

/phantombans reload

A slot outside the menu is skipped with a console warning instead of breaking the menu, so a typo is safe. If you set a material that does not exist, the item falls back to STONE with a warning.

The menu-version line in each file is managed by the plugin. Do not edit it.

Last updated on