The bug
When killing a mob which can drop weapons, tools or armor, the dropped item is randomly damaged. Rarely the remaining durability of the item is 0, however that durability is not valid anymore, see MC-120664. Normally in Survival the lowest possible durability is 1, after that the item breaks.
Therefore mobs should also drop items with a durability of at least 1.
How to reproduce
Enchant a sword with looting (and optionally sharpness)
Kill multiple zombified piglins
Pick up their dropped golden swords
❌ Some of them have a durability of 0
Linked issues
is duplicated by 34
relates to 2
Attachments
Comments 20
Since the 0 durability on items was considered to be a bug, does that mean that you could summon in or give the player an item with 0 durability? Or will the developers make the minimum one durability, like on normal items? I could check that myself I suppose.
Update: Just confirmed that you can
Update 2: You can also make the value negative
It can go into a minimum value of -999999967
@unknown Tickets that are resolved as won't fix won't get updated. So newer affected versions don't get added to them.
In 1.16.5 can pilligers and Vindicators have a chance to drop 0 durability axes and crossbows.
[media][media]
Also encountered this today, specifically with a bow from a skeleton. Could apply to more mobs/items, might try to check if pigmen or wither skeltons can drop 0 durability swords.