diff options
Diffstat (limited to 'src/main/java/moe/nea/funnyteleporters/FunnyRecipeProvider.java')
-rw-r--r-- | src/main/java/moe/nea/funnyteleporters/FunnyRecipeProvider.java | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/src/main/java/moe/nea/funnyteleporters/FunnyRecipeProvider.java b/src/main/java/moe/nea/funnyteleporters/FunnyRecipeProvider.java new file mode 100644 index 0000000..5b7ee14 --- /dev/null +++ b/src/main/java/moe/nea/funnyteleporters/FunnyRecipeProvider.java @@ -0,0 +1,27 @@ +package moe.nea.funnyteleporters; + +import net.fabricmc.fabric.api.datagen.v1.FabricDataOutput; +import net.fabricmc.fabric.api.datagen.v1.provider.FabricRecipeProvider; +import net.minecraft.data.server.recipe.RecipeExporter; +import net.minecraft.data.server.recipe.ShapelessRecipeJsonBuilder; +import net.minecraft.item.Items; +import net.minecraft.recipe.book.RecipeCategory; +import net.minecraft.registry.RegistryWrapper; + +import java.util.concurrent.CompletableFuture; + +public class FunnyRecipeProvider extends FabricRecipeProvider { + + public FunnyRecipeProvider(FabricDataOutput output, CompletableFuture<RegistryWrapper.WrapperLookup> registriesFuture) { + super(output, registriesFuture); + } + + @Override + public void generate(RecipeExporter recipeExporter) { + ShapelessRecipeJsonBuilder.create(RecipeCategory.TRANSPORTATION, FunnyRegistry.COLOURED_CHEST) + .input(Items.ENDER_CHEST).input(Items.REDSTONE_BLOCK).input(Items.HOPPER) + .criterion(hasItem(Items.ENDER_CHEST), conditionsFromItem(Items.ENDER_CHEST)) + .offerTo(recipeExporter); + + } +} |