Solved Colored ItemStack display name

Discussion in 'Plugin Development' started by The_Spaceman, Jun 30, 2020.

  1. Offline

    The_Spaceman

    Hello,

    Since minecraft 1.16 HEX colors are supported,
    my question is how rename I an ItemStack with this?

    Ive tried inserting JSON into the ItemMeta#setDisplayName and this does not work.

    How do I insert raw JSON into an ItemStack?
     
  2. Offline

    KarimAKL

    @The_Spaceman Try the new method in the bungee version of ChatColor (included in Spigot), ChatColor#of(Color).
     
  3. Offline

    The_Spaceman

    Nice, thank you.
    Not what I wanted, but exactly what I needed.

    To use HEX colors use '§x§R§R§G§G§B§B'
     
    KarimAKL likes this.

Share This Page