-
Bug
-
Resolution: Fixed
-
24w39a
-
None
-
Confirmed
-
(Unassigned)
-
Low
-
Platform
Shapeless recipes accept anything in empty tag ingredients. (As long as there is something).
For example, the following recipe:
{ "type": "minecraft:crafting_shapeless", "category": "building", "ingredients": [ "minecraft:diorite", "#c:cobblestones/doesntexist" ], "result": { "count": 2, "id": "minecraft:diamond" } }
with the following tag file for the tag:
{
"values": []
}
causes a warning to be printed in the chat:
Recipe minecraft:test_recipe can't be placed due to empty ingredients and will be ignored
However, the recipe will accept any two items and give two diamonds as a result.
How to reproduce:
The attached data pack contains a shapeless recipe that accepts stone and an empty tag and returns smooth stone, and an empty item tag.
- Add the attached data pack to a world.
- Place any two items in a crafting grid.
→ Smooth stone appears in the crafting output.
Expected result:
The recipe wouldn't validate due to the empty tag in the ingredients list.
Observed result:
A message is printed in the log saying that the recipe didn't validate, but putting any two items in a crafting grid outputs smooth stone.
Possible cause:
Looks like the PlacementInfo for the recipe is `PlacementInfo.NOT_PLACEABLE`, but that doesn't prevent the shapeless recipe from matching as long as the item count is equal to the ingredient count.