Loot table
Make the recipe output the result of a loot table
Loot table requirement is used to generate item outputs based on a vanilla, modded or custom loot table.
This requirement is OUTPUT only, you don't have to specify a mode
property.
This requirement will block the end of the recipe if the generated items can't be put in a slot (because all slots are full for example).
The requirement type of loot table requirement is : "custommachinery:loot_table"
.
Properties
The loot table requirement has 2 mandatory properties and 1 optional property.
Mandatory properties
Optional property
Example
A loot table requirement that will make the recipe output either 28 diamonds or a stone in the #forge:stones tag.
In data/custommachinery/loot_tables/test_loot_table.json
Notes
Minecraft loot tables are a very complex system, which is made to be used in many ways (block and mobs drops, dungeon chests, plant harvest etc...) and that would be a hell to support and test all possibilities of loot tables. So some things may break, other may not work.
Loot tables have a type
property, when possible use "type": "custommachinery:custom_machine"
. It may not be needed thought.
If you have any issues with the loot table requirement and you seek support in the github issues or in the discord, please include the loot table file and describe the most precisely possible what it should do. I am not a loot tables expert and I can't spend hours on the wiki just to understand what your loot table does.