mojira.dev
MC-136352

Tools from creative inventory/crafting don't have Damage:0 set until relog

The bug

Upon dropping an undamaged item it has no Damage:0 tag, so you can't check via commands if the item is not damaged.

How to reproduce

  1. Get a diamond pickaxe from creative mode

  2. Drop it

  3. Run this command:

    /data get entity @e[type=item,limit=1]

    → Inside the Item NBTTag there's no {Damage:0} tag

Exiting and re-entering the world writes the {Damage:0} tag to the item (both if on ground on your inventory).

Linked issues

Comments 5

Confirmed for 1.13.2-pre1.

Confirmed for 1.13.2-pre2.

this bug can make a zombie constantly switch between a damaged diamond armor and a diamond armor without damage tag

preventing creating an itemstack without damage tag may be a better solution

Confirmed for 19w35a

Also, maybe add some labels to the ticket to improve visibility.
Searching for "Damage nbt" didn't reveal this ticket.

Adding NBT to the labels might help.

insane96mcp

slicedlime

Confirmed

Normal

Items

damage, nbt

Minecraft 1.13.1, Minecraft 1.13.2-pre1, Minecraft 1.13.2-pre2, Minecraft 1.13.2, Minecraft 18w43b, ..., Minecraft 18w50a, Minecraft 1.14 Pre-Release 2, Minecraft 1.14 Pre-Release 3, Minecraft 1.14.3 Pre-Release 4, 19w35a

19w37a

Retrieved