Mojira Archive
MC-183460

Using the "reset" color in JSON text does not reset the color to default for enchanted item names and other cases

The bug

When attempting to use reset in JSON text as a color for enchanted item names and other cases, it does not reset the color to default. This does not happen in 1.15.2.

How to reproduce

Use the following command to give yourself an enchanted Stick with a customized name:

/give @s stick{display:{Name:'{"text":"Wooden Stake","color":"reset","italic":false}'},Enchantments:[{}]}

The name of the enchanted item is still aqua instead of the default color.

Other information

The bug also affects the following cases:

  • commands for Signs which should have black text at the end
    /give @s oak_sign{BlockEntityTag:{Text2:'[{"text":"blue ","color":"blue"},{"text":"black","color":"reset"}]'}}
    
  • commands for Chests or Trapped Chests which should have gray text at the end
    /give @s chest{BlockEntityTag:{CustomName:'[{"text":"blue ","color":"blue"},{"text":"gray","color":"reset"}]'}}
    
  • most JSON text in general
    [{"text":"Golden ","color":"gold"},{"text":"Pickaxe","color":"reset"}]
    

Workaround

Instead of using the reset color for the last text, an empty string can be added at the beginning of a text list:

["",{"text":"Blue","color":"blue"}," and Default"]

However, it only works for other JSON text and not for item names.