Skip to content

Creating Cosmetics

Add your own chat colors, tags, name paints, rank colors, glows, tab icons and join/leave messages.

Cosmetics are config, not commands. You add one by adding a section to the right file in cosmetics/ and reloading. You need optimalcosmetics.admin to reload and to hand the cosmetic out.

Type File Value holds
Chat Color chat-colors.yml A format around {context} (the chat message).
Tag tags.yml The tag text itself.
Name Paint name-paints.yml A format around {context} (the player’s name).
Rank Color rank-colors.yml A format around {context} (the player’s rank, without its own colors).
Glow glow.yml Comma-separated color names, cycled every 2 seconds.
Tab Icon tab-icons.yml The symbol.
Join Message join-messages.yml The full join message, with {player}.
Leave Message leave-messages.yml The full quit message, with {player}.

Every top-level key is one cosmetic, and the key is its id. The id is what you type in /cosmeticsadmin give and what ownership is saved under, so pick it once and keep it.

Sunset:
Enabled: true
Rarity: "Epic"
Material: "PLAYER_HEAD"
Base64: "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0..."
Name: "{primary}<b>Name Paint:</b> <GRADIENT:ff9a3c,ff4f81>Sunset</GRADIENT>"
Lore:
- "&7A warm evening gradient."
- ""
Value: "<GRADIENT:ff9a3c,ff4f81>{context}</GRADIENT>"

That goes in name-paints.yml. The Name is the menu icon’s name and what messages show as {cosmetic}. Lore is optional and is shown above the equipped / unequipped / locked lore from Lore-Addons. {primary} and {secondary} become the rarity’s colors.

Full field list: cosmetics reference.

/cosmeticsadmin reload
/cosmeticsadmin give <you> Sunset

Open /cosmetics, click it and equip it. If two types share an id, give it with the type in front: /cosmeticsadmin give <you> NAME_PAINT:Sunset.

Chat colors, name paints and rank colors need {context} where the painted text goes. A value without {context} paints nothing.

Value: "<#00FF00>{context}</#00FF00>"
Value: "<GRADIENT:fa8cb2,d14977,a82255>{context}</GRADIENT>"
Value: "&b&l{context}"

Tags and tab icons are the text itself:

Value: "&8[<#ed6de5><b>Suzuka</b></#ed6de5>&8]"
Value: "⛏"

Glow is one or more color names separated by commas. Every name must be one of the 16 chat colors (BLACK, DARK_BLUE, DARK_GREEN, DARK_AQUA, DARK_RED, DARK_PURPLE, GOLD, GRAY, DARK_GRAY, BLUE, GREEN, AQUA, RED, LIGHT_PURPLE, YELLOW, WHITE), or the load fails naming the cosmetic.

Value: "RED,GOLD,YELLOW"

Join and leave messages are the whole line, with {player} for the name. Wrap it in [center]...[/center] to center it in chat.

Value: "[center]&e{player} joined the server![/center]"

Rarity is any name listed under Rarity-Colors in config.yml (Common when left out). The rarity decides the {primary} / {secondary} colors and the order of the “Rarity” sort. A rarity that is not listed gets gray colors and sorts last.

  • /cosmeticsadmin give <player> <id> - unlock it directly, online or offline.
  • /cosmeticsadmin givevoucher <player> <id> [amount] - a voucher the player right-clicks to unlock it. Uses the cosmetic’s own Voucher block, or the global Voucher template in config.yml.
  • Put it in a case pool - see Creating Cases.
  • Players can resell it on the market.
  • Disable without deleting: Enabled: false hides a cosmetic from the menu, the market and case pools. Players keep ownership, so turning it back on restores it.
  • Order: the “Item” sort shows cosmetics in file order, types in the order of the table above.
  • Material can be left out; it then defaults to NAME_TAG (chat colors, tags, name paints, rank colors), GLOWSTONE (glow) or PAPER (tab icons, join and leave messages). An unknown material fails the load and names the cosmetic and file.
  • Renaming an id is a new cosmetic. Players who owned the old id lose it from the menu, and vouchers for it stop working.
  • Disabling a whole type is done in config.yml under Types, not by deleting its file.