-
Bug
-
Resolution: Invalid
-
None
-
1.16 Pre-release 1, 1.16 Pre-release 2
-
Unconfirmed
-
Advancements
The bug
Although the thrown_item_picked_up_by_entity advancement trigger now works for players, it is triggered when a player drops an item and the same player picks it back up.
The bug is caused by the fix for MC-185095.
How to reproduce
- Download and then install the data pack below for easier reproduction.
- Observe the following advancements and functions below:
{ "criteria": { "thrown_item_picked_up_by_entity": { "trigger": "thrown_item_picked_up_by_entity" } }, "rewards": { "function": "game:thrown_item_picked_up_by_entity" } }
advancement revoke @s only game:thrown_item_picked_up_by_entity tellraw @s ["",{"selector":"@s"}," picked up an item"]
- Drop any item and then pick it back up.
→ You will notice that the advancement is granted even if you are the same player that dropped the item.
Fix
A suggested fix would be to check if the UUID of the player that picks up the item matches that of the Thrower NBT tag of the item entity if any. If it does, then the advancement trigger should not be triggered for the player that drops the item.
- is duplicated by
-
MC-193208 Advancement trigger minecraft:thrown_item_picked_up_by_entity triggers with the same player
- Resolved