mojira.dev
MC-86130

Shields changes its base color when damaged & repaired / Crafting different in colors results in damage

When shields have no pattern(s) applied, they use the damage value to determine color instead of the Base field in BlockEntityTag. This field is also used to track the durability of the shield, which has two effects:

  • Changing the durability of the shield (by taking damage or repairing it) changes the color

  • Crafting a new shield creates one that has lost 0 to 15 points of durability

A simple fix would be to always add the BlockEntityTag when crafting a new shield and always set the damage value to 0, and for shields without BlockEntityTag (e.g. obtained through /give), to always display their color as black.

Linked issues

MC-86148 Shield Change Color Resolved MC-86150 Crafted shields have durability lost depending on their color Resolved MC-86154 Shiel Crafts not 100% health Resolved MC-86158 Shields changes its color when takes damage due to DV. Also they are damaged when crafted depending of the color. Resolved MC-86176 The shield change his color when mob attack the player Resolved

Comments 16

Could not recreate. Could you provide screenshots?

EDIT: Can confirm with what Tom Udding said. You must /give @p shield for it to work

Only works with black shields (/give @p shield), if you use that shield it will color shift.

Can confirm that it works with shields obtained by give command. If you give yourself a shield with a damage value, it takes the color of that value.

If you use /give it does so. I failed to realize that that was what was causing it.

it works without /give

6 more comments

I've made yellow and white shields, and each has spontaneously turned into a "black shield" with a display color that changes every time it takes a hit (melee or projectile).

seems back in 16w36a, black shields that change color when hit

Jack

Erik Broes

Confirmed

Minecraft 15w33c, Minecraft 15w34a, Minecraft 15w34b, Minecraft 15w35b, Minecraft 16w36a

Minecraft 15w36a, Minecraft 16w38a

Retrieved