Compatibility
Minecraft: Java Edition
Platforms
Supported environments
75% of ad revenue goes to creators
Support creators and Modrinth ad-free with Modrinth+Creators
Details
Simply Put
Art's CLA lets server admins (or, the player in single-player worlds) use a loot table to have chickens lay any item or block in its item state. This won't place blocks to build random constructions (although, that does sound interesting).
Basis for the Code
This datapack is a modification of helmo2019's Chickens Lay Anything. My additions only add some abuse protection.
Adding the Loot Table
Adding a loot table is done by adding a loot table, which can be added by another datapack that add chickenslayanything:laid_by_chicken. The file is located at:
data/
chickenslayanything/
loot_table/
laid_by_chicken.json
Making the Chickens do the Work
To have the chickens start laying useful items, they just need to be on a hopper and not too close to other chickens.
Abuse Reduction
Since chickens are easy to breed, allowing them to lay valuable items could easily be abused. To prevent this, the chickens have to be at least 16 blocks apart, or they just lay eggs.
Allowing chickens to drop items all over isn't generally problematic, but loot tables that produce a large number of items could begin to cause random lag spikes from entity processing. This is addressed by ensuring the drops aren't left on the surface - they have to be on a hopper.