TDXDevelopment
TDX VotePlusConfiguration

guis/

One YAML per inventory menu layout.

The guis/ folder holds one YAML per inventory menu. You can re-skin one menu without touching the others. Apply changes with /voteplus reload, no restart needed.

vote-main.yml
my-votes.yml
streaks.yml
leaderboard.yml
leaderboard-history.yml
milestones.yml
party.yml
claim.yml
FileMenuOpened by
vote-main.ymlThe main vote menu/vote
my-votes.ymlTotal, monthly, weekly and daily counts/vote my
streaks.ymlCurrent streak, best streak, streak window/vote streaks
leaderboard.ymlTop voters, with a period switch/vote top
leaderboard-history.ymlPast months and their winnersThe history button in the leaderboard
milestones.ymlEvery milestone with progressThe milestones button in the main menu
party.ymlVote party progressThe vote party button in the main menu
claim.ymlQueued offline votes/vote claim

A file that is missing is written again from the default on the next start or reload, so deleting one is the way to reset a menu. Older installs that still have a gui_menus/ folder get it renamed to guis/ automatically.

Anatomy of a menu file

Every file has the same shape: a title, a size, a filler item and an items map.

plugins/TDXVotePlus/guis/vote-main.yml
title: "<dark_gray>Vote for Rewards!"
size: 54

filler:
  material: BLACK_STAINED_GLASS_PANE
  name: " "

items:
  header:
    slot: 4
    material: OAK_SIGN
    glow: true
    name: "<#FFD93D><bold>Welcome, {player}!</bold>"
    lore:
      - "<#E0F0FF>▪ Total votes:    <#FFD93D>{total_votes}"
      - "<#E0F0FF>▪ This month:     <#FFD93D>{monthly_votes}"

  leaderboard_button:
    slot: 8
    material: GOLD_INGOT
    name: "<#FFD93D><bold>Leaderboard</bold>"
    lore:
      - "<#5EEEA0>» Click to open"
    action: "open_menu:leaderboard"
KeyNotes
titleMiniMessage title of the inventory.
sizeSlots, a multiple of 9 up to 54. Default 27.
fillerItem placed in every slot nothing else uses. Set material: AIR to leave slots empty.
itemsMap of items. The key is only a label for you, the slot decides where the item goes. If two items share a slot, the later one wins.

Item keys

KeyDefaultNotes
slot-10 to size - 1, counted from the top left. -1 defines the item without placing it.
materialPAPERBukkit material name, any case. An unknown name falls back to paper.
amount1Stack size.
nameMiniMessage display name.
loreList of MiniMessage lines.
glowfalseEnchant glint without showing an enchantment.
actionnoneWhat a click does, see below.

There is no slots list and no custom-model-data key. To fill several slots with the same item, use filler or repeat the item.

Actions

ActionWhat a click does
noneNothing.
closeCloses the menu.
refreshRebuilds the current menu.
list_sitesCloses the menu and posts the vote site links in chat.
"open_menu:<id>"Opens another menu: vote-main, my-votes, streaks, leaderboard, leaderboard-history, milestones, party or claim.
"command:<command>"Closes the menu and runs the command as the player. Write it without the leading slash.
"console:<command>"Runs the command from console.
"url:<address>"Closes the menu and sends the player a clickable link.

The long form works too:

action:
  type: open_menu
  target: leaderboard

Tokens

Inside any name or lore line these expand for the player viewing the menu:

TokenReplaced with
{player}The viewer's name
{total_votes}Lifetime votes
{monthly_votes}Votes this month
{weekly_votes}Votes this week, Sunday to Saturday
{daily_votes}Votes today
{streak_current}Current streak
{streak_best}Best streak
{next_reset}Countdown to the monthly reset
{site_count}Number of configured vote sites
{milestone_count}Number of milestones
{next_milestone}Name of the next milestone the viewer can reach
{next_milestone_current}The viewer's value for that milestone
{next_milestone_threshold}Its threshold
{milestone_progress_bar}Progress bar for that milestone
{party_counter}Vote party counter
{party_threshold}Vote party threshold
{party_percent}Party progress, 0 to 100
{party_remaining}Votes still needed
{party_progress_bar}Party progress bar
{total_parties}Parties fired so far
{server}The server name

Only these {tokens} are expanded. PlaceholderAPI tokens such as %vault_eco_balance% are not resolved in menu text. The comment in vote-main.yml said otherwise before v1.3.4, which was wrong.

Slots the plugin fills itself

Some menus are lists, and the plugin stamps the entries in. Do not put your own items in these slots, they will be overwritten:

MenuReserved slots
leaderboard4 (period switch), 10 to 16 and 19 to 25 (the 14 entries), 47 to 49 (info and refresh buttons)
leaderboard-history10 to 34, up to 21 months
milestones10 to 16, 19 to 25, 28 to 34, 37 to 43, up to 28 milestones
claim4 (header), the same 28-slot grid for queued votes, and 49 (Claim All)

The colours of locked, reached and claimed milestones, the streak status text on window_card in streaks.yml, and the leaderboard entries are drawn by the plugin and cannot be restyled from these files. Everything else, including every button, can be moved, renamed or removed.