2021-10-24 18:49:48 +02:00
|
|
|
package de.ellpeck.actuallyadditions.data;
|
|
|
|
|
2021-11-13 17:30:53 +01:00
|
|
|
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
|
|
|
|
import de.ellpeck.actuallyadditions.mod.crafting.CrushingRecipe;
|
2024-03-04 22:03:46 +01:00
|
|
|
import de.ellpeck.actuallyadditions.mod.util.NoAdvRecipeOutput;
|
2024-03-03 01:20:53 +01:00
|
|
|
import net.minecraft.data.PackOutput;
|
2024-03-04 20:21:48 +01:00
|
|
|
import net.minecraft.data.recipes.RecipeOutput;
|
2024-03-02 21:23:08 +01:00
|
|
|
import net.minecraft.data.recipes.RecipeProvider;
|
|
|
|
import net.minecraft.resources.ResourceLocation;
|
2024-03-04 20:21:48 +01:00
|
|
|
import net.minecraft.world.item.ItemStack;
|
2024-03-02 21:23:08 +01:00
|
|
|
import net.minecraft.world.item.Items;
|
|
|
|
import net.minecraft.world.item.crafting.Ingredient;
|
2021-10-24 18:49:48 +02:00
|
|
|
|
2024-03-04 22:03:46 +01:00
|
|
|
import javax.annotation.Nonnull;
|
|
|
|
|
2021-10-24 18:49:48 +02:00
|
|
|
public class CrushingRecipeGenerator extends RecipeProvider {
|
2024-03-03 01:20:53 +01:00
|
|
|
public CrushingRecipeGenerator(PackOutput packOutput) {
|
|
|
|
super(packOutput);
|
2021-10-24 18:49:48 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
@Override
|
2024-03-03 01:20:53 +01:00
|
|
|
public String getName() {
|
|
|
|
return "Crushing " + super.getName();
|
2021-10-24 18:49:48 +02:00
|
|
|
}
|
|
|
|
|
2024-03-03 01:20:53 +01:00
|
|
|
@Override
|
2024-03-04 22:03:46 +01:00
|
|
|
protected void buildRecipes(@Nonnull RecipeOutput output) {
|
|
|
|
var recipeOutput = new NoAdvRecipeOutput(output);
|
|
|
|
|
|
|
|
|
2024-03-04 20:21:48 +01:00
|
|
|
CrushingRecipe recipe = new CrushingRecipe(Ingredient.of(Items.BONE), new ItemStack(Items.BONE_MEAL, 6), 1.0f, ItemStack.EMPTY, 0.0f);
|
2024-03-04 22:03:46 +01:00
|
|
|
recipeOutput.accept(new ResourceLocation(ActuallyAdditions.MODID, "crushing/iron_crusher"), recipe, null);
|
2021-10-24 18:49:48 +02:00
|
|
|
}
|
|
|
|
}
|