Automatic Crafting - gnembon/fabric-carpet GitHub Wiki
Carpet offers two different methods to automate the occasionally tedious task of crafting stuff. One implements hopper (and dropper) support for the crafting table, as if it were any other container block. The other adds a feature to droppers to interact with crafting tables.
Auto Crafting Table
This implementation by Skyrising makes it so that when a hopper or dropper points into a crafting table, it treats it as any other container and inputs items into it, with the exception that only one item can be put into each slot automatically (the behavior with player interaction is preserved). Any result of a crafting recipe can be sucked out of the table with a hopper under it.
See this video and this video for a more complete and lengthy one, including some cool tutorials. This is the more used of the two automatic crafting methods described here.
Features
- Hopper/dropper support for pushing items in and taking stuff out.
- Technically, the crafting table becomes a block entity (or tile entity) and as such, can't be moved. Enabling the carpet rule
movableBlockEntities
makes it movable again. - Comparator support: it reads the fill level of the 9 slots used for crafting and ignores the output slot.
How to add autoCraftingTable
Because of some compatibility issues, the autoCraftingTable mod is it's own separate carpet add-on. Download the mod here and throw it into the mods folder. Make sure to also have the Carpet mod for the same version in there. Once in the game, enable it with /carpet autoCraftingTable true
and make sure to also set its default to true with /carpet setDefault autoCraftingTable true
.
Auto Crafting Dropper
This implementation by gnembon turns a dropper facing into a crafting table into a crafting dropper. A crafting dropper, when powered, will try to craft an item out of the shape it has in it's inventory and spawn it inside the crafting table, where it will glitch out in a random direction. A crafting dropper behaves different from a regular dropper in two regards: hoppers put one item in each slot, instead of stacking them, and comparators read the fill level as percentage of slots with items, not percentage of actual container capacity filled.
See this video for a very brief showcase of features and this video for a more complete and talky one.
Features
- Crafting table remains completely vanilla. Some may think it enables sucking items out it with a hopper, but in reality, items are just spawned inside the table and instantly sucked in by hoppers under it, much like honey bottles and honeycomb from a beehive or nest.
- Changes comparator and hopper interaction of the dropper when it's pointing into a crafting table. Hoppers input one item per slot and comparators read how many slots have items, instead of the usual how many total items there are in the dropper.
- When multiple recipes are stacked inside a single dropper, powering it will output one of the available ones, randomly.
How to add autoCraftingDropper
This carpet rule is part of Carpet Extra. Download the mod here, throw it into your mods folder together with Carpet mod and enable it in-game with /carpet autoCraftingDropper true
. Make sure to also set its default to true with /carpet setDefault autoCraftingDropper true
.