Package vazkii.botania.common.crafting
Class ManaInfusionRecipe
java.lang.Object
vazkii.botania.common.crafting.ManaInfusionRecipe
- All Implemented Interfaces:
net.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>,ManaInfusionRecipe
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from interface vazkii.botania.api.recipe.ManaInfusionRecipe
TYPE_IDFields inherited from interface net.minecraft.world.item.crafting.Recipe
CODEC, STREAM_CODEC -
Constructor Summary
ConstructorsConstructorDescriptionManaInfusionRecipe(net.minecraft.world.item.ItemStack output, net.minecraft.world.item.crafting.Ingredient input, int mana, @Nullable String group, @Nullable StateIngredient catalyst) -
Method Summary
Modifier and TypeMethodDescriptiongetGroup()net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> protected net.minecraft.world.item.crafting.IngredientgetInput()intprotected net.minecraft.world.item.ItemStackGet the catalyst that must be under the Mana Pool for this recipe, ornullif it can be anything.net.minecraft.world.item.ItemStackgetResultItem(net.minecraft.core.HolderLookup.Provider registries) Get the recipe output, used for display (in JEI or the HUD).net.minecraft.world.item.crafting.RecipeSerializer<ManaInfusionRecipe> net.minecraft.world.item.ItemStackbooleanmatches(net.minecraft.world.item.ItemStack stack) Attempts to match the recipe.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface vazkii.botania.api.recipe.ManaInfusionRecipe
assemble, canCraftInDimensions, getRecipeOutput, getType, isSpecial, matchesMethods inherited from interface net.minecraft.world.item.crafting.Recipe
getRemainingItems, isIncomplete, showNotification
-
Constructor Details
-
ManaInfusionRecipe
public ManaInfusionRecipe(net.minecraft.world.item.ItemStack output, net.minecraft.world.item.crafting.Ingredient input, int mana, @Nullable @Nullable String group, @Nullable @Nullable StateIngredient catalyst)
-
-
Method Details
-
getSerializer
- Specified by:
getSerializerin interfacenet.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
-
matches
public boolean matches(net.minecraft.world.item.ItemStack stack) Description copied from interface:ManaInfusionRecipeAttempts to match the recipe.- Specified by:
matchesin interfaceManaInfusionRecipe- Parameters:
stack- The whole stack that is in the Mana Pool (when actually crafting) or in the player's hand (for the HUD).- Returns:
- Whether this recipe matches the given stack.
-
getRecipeCatalyst
Description copied from interface:ManaInfusionRecipeGet the catalyst that must be under the Mana Pool for this recipe, ornullif it can be anything.- Specified by:
getRecipeCatalystin interfaceManaInfusionRecipe- Returns:
- The catalyst ingredient.
-
getManaToConsume
public int getManaToConsume()- Specified by:
getManaToConsumein interfaceManaInfusionRecipe- Returns:
- How much mana this recipe consumes from the pool.
-
getResultItem
public net.minecraft.world.item.ItemStack getResultItem(net.minecraft.core.HolderLookup.Provider registries) Description copied from interface:ManaInfusionRecipeGet the recipe output, used for display (in JEI or the HUD). IfManaInfusionRecipe.getRecipeOutput(net.minecraft.core.RegistryAccess, net.minecraft.world.item.ItemStack)isn't overridden, this is also the actual result of the crafting recipe.- Specified by:
getResultItemin interfaceManaInfusionRecipe- Specified by:
getResultItemin interfacenet.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>- Returns:
- The output stack of the recipe.
-
getIngredients
public net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> getIngredients()- Specified by:
getIngredientsin interfacenet.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
-
getGroup
- Specified by:
getGroupin interfacenet.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
-
getToastSymbol
public net.minecraft.world.item.ItemStack getToastSymbol()- Specified by:
getToastSymbolin interfacenet.minecraft.world.item.crafting.Recipe<net.minecraft.world.item.crafting.RecipeInput>
-
getInput
protected net.minecraft.world.item.crafting.Ingredient getInput() -
getOutput
protected net.minecraft.world.item.ItemStack getOutput()
-