-
Bug
-
Resolution: Unresolved
-
None
-
1.21.2 Pre-Release 3, 1.21.2 Pre-Release 4, 1.21.2 Pre-Release 5, 1.21.2 Release Candidate 1, 1.21.2 Release Candidate 2, 1.21.2, 24w44a, 1.21.3, 24w45a, 24w46a, 1.21.4 Pre-Release 1
-
None
-
Community Consensus
-
Commands, Items
-
Important
-
Platform
If the player's inventory contains an item with a block tag in its can_place_on or can_destroy fields, and the /reload command is run (even if only the vanilla datapack is present), any subsequent copy of that item given to the player will be treated as different and be unable to stack with the original item, despite the two appearing identical from a data perspective.
Once the player's inventory is updated (by opening a container, etc.) the two items become stackable again.
Steps to reproduce:
/give @s stone[can_place_on={predicates: [{blocks:"#minecraft:dirt"}]}]
- /reload
- Again,
/give @s stone[can_place_on={predicates: [{blocks:"#minecraft:dirt"}]}]
- Note the items do not enter the same inventory slot and cannot stack, despite no changes being made to the command.
- For flavor,
/data get entity @s Inventory
and compare the two items' data - the data will appear identical but the stacks still will not combine.
- Open a chest, shift-click both items into it; now they stack.