mojira.dev
MC-135164

Mobs do not stop holding blocks/items after dropping them upon death, leading to visual duplication

The bug

Note how in the attached picture, the zombie, which is dying, has dropped its iron sword, however it still appears to be holding said sword.

Similar arguments could be given for blocks held by endermen, heads of mobs killed by charged creepers, sheep wool, skeletons' bones, and so on. However, these should likely have their own tickets.

An easy way to fix this is to make mobs only drop items after the corpse disappears, like experience used to, eliminating this discrepancy.

How to reproduce

  1. Run:

    /summon minecraft:zombie ~ ~ ~ {HandDropChances:[100f],HandItems:[{id:diamond_sword,Count:1b}],Health:1}
  2. Hit the zombie.
    → ✔ Zombie dies and drops the sword as expected...
    → ❌  but the zombie still holds the sword while it's already dropped

Linked issues

Attachments

Comments 11

Please do not mark unreleased versions as affected.
You don't have access to them yet.

Experience is now dropped at the time of death - perhaps loot drops could now be moved to the same time experience used to drop?

Is this fixed in 20w51a?

I am unable to reproduce this in 20w51a.

1 more comments

Definitely seems fixed as of 21w03a

Resolving as 'Cannot Reproduce' for now. A fix version can be added afterwards in case someone finds out the exact version where this got fixed.

I can confirm that, at least for the provided zombie example, 1.16.3-rc1 was the version to fix this issue. It does not affect 1.16.3 nor any 1.16.4 prereleases, despite what the affects versions might say, implying either the fix was retroactive in some sense or that there was another similar example being tested (which should go in a dedicated ticket).

Still fixed in 21w07a - can this be re-resolved?

muzikbike

(Unassigned)

Confirmed

Rendering

duplication

Minecraft 1.13, Minecraft 18w30b, Minecraft 18w31a, Minecraft 18w32a, Minecraft 18w33a, ..., 20w29a, 20w30a, 1.16.2 Pre-release 1, 1.16.3, 1.16.4 Pre-release 2

1.16.3 Release Candidate 1

Retrieved