Package net.minecraft.recipe
Class AbstractCookingRecipe
java.lang.Object
net.minecraft.recipe.AbstractCookingRecipe
- Direct Known Subclasses:
BlastingRecipe
,CampfireCookingRecipe
,SmeltingRecipe
,SmokingRecipe
public abstract class AbstractCookingRecipe extends Object implements Recipe<Inventory>
-
Field Summary
Fields Modifier and Type Field Description protected int
cookTime
protected float
experience
protected String
group
protected Identifier
id
protected Ingredient
input
protected ItemStack
output
protected RecipeType<?>
type
-
Constructor Summary
Constructors Constructor Description AbstractCookingRecipe(RecipeType<?> type, Identifier id, String group, Ingredient input, ItemStack output, float experience, int cookTime)
-
Method Summary
Modifier and Type Method Description ItemStack
craft(Inventory inv)
boolean
fits(int width, int height)
int
getCookTime()
float
getExperience()
String
getGroup()
Identifier
getId()
ItemStack
getOutput()
DefaultedList<Ingredient>
getPreviewInputs()
RecipeType<?>
getType()
boolean
matches(Inventory inv, World world)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minecraft.recipe.Recipe
getRecipeKindIcon, getRemainingStacks, getSerializer, isIgnoredInRecipeBook, method_31584
-
Field Details
-
type
-
id
-
group
-
input
-
output
-
experience
protected final float experience -
cookTime
protected final int cookTime
-
-
Constructor Details
-
AbstractCookingRecipe
public AbstractCookingRecipe(RecipeType<?> type, Identifier id, String group, Ingredient input, ItemStack output, float experience, int cookTime)
-
-
Method Details
-
matches
-
craft
-
fits
@Environment(CLIENT) public boolean fits(int width, int height) -
getPreviewInputs
- Specified by:
getPreviewInputs
in interfaceRecipe<Inventory>
-
getExperience
public float getExperience() -
getOutput
-
getGroup
-
getCookTime
public int getCookTime() -
getId
-
getType
-