Mojira Archive
MC-187281

Function reward removing the item an advancement detected creates a ghost item

The bug

When a function reward of an advancement that triggers on inventory_changed removes the item, the advancement detected, the item is left behind has a ghost item on the client.
Presumably, that happens because of when in the tick the advancement triggers. It is likely, that the advancement triggers before the item is being send to the client, and then the inventory updates are send in the wrong order.

How to reproduce

  1. Download the example datapack: Advancement Ghost Item Bug.zip
  2. Put the datapack into your world's datapack directory
  3. Give yourself a vine
  4. Make sure you are in survival mode (in creative the ghost item will behave like a regular item)
    You now have a ghost vine in your inventory

Unresolved

[Mod] NeunEinser

2020-06-04, 12:49 PM

2024-06-03, 01:21 PM

20

20

Confirmed

Normal

Platform

Advancements, Commands, Data Packs, Networking

20w22a - 1.20.620w22a, 1.16 Pre-release 1, 1.16 Pre-release 2, 1.16 Release Candidate 1, 1.16, 1.16.1, 1.16.2, 1.16.4, 20w51a, 1.16.5, 1.20.1, 23w40a, 1.20.4, 1.20.6

-