Package com.blamejared.wac.recipe.ritual
Record Class Ritual
java.lang.Object
java.lang.Record
com.blamejared.wac.recipe.ritual.Ritual
- All Implemented Interfaces:
net.minecraft.world.item.crafting.Recipe<RitualRecipeInput>
public record Ritual(net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> ingredients, net.minecraft.world.effect.MobEffectInstance output, int requiredEnchantingPower)
extends Record
implements net.minecraft.world.item.crafting.Recipe<RitualRecipeInput>
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from interface net.minecraft.world.item.crafting.Recipe
CODEC, STREAM_CODEC -
Constructor Summary
ConstructorsConstructorDescriptionRitual(net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> ingredients, net.minecraft.world.effect.MobEffectInstance output, int requiredEnchantingPower) Creates an instance of aRitualrecord class. -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.world.item.ItemStackassemble(RitualRecipeInput input, net.minecraft.core.HolderLookup.Provider registries) booleancanCraftInDimensions(int width, int height) final booleanIndicates whether some other object is "equal to" this one.net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> net.minecraft.world.item.ItemStackgetResultItem(net.minecraft.core.HolderLookup.Provider registries) net.minecraft.world.item.crafting.RecipeSerializer<?> net.minecraft.world.item.crafting.RecipeType<?> getType()final inthashCode()Returns a hash code value for this object.net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> Returns the value of theingredientsrecord component.booleanmatches(RitualRecipeInput input, net.minecraft.world.level.Level level) net.minecraft.world.effect.MobEffectInstanceoutput()Returns the value of theoutputrecord component.intReturns the value of therequiredEnchantingPowerrecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.world.item.crafting.Recipe
getGroup, getRemainingItems, getToastSymbol, isIncomplete, isSpecial, showNotification
-
Constructor Details
-
Ritual
public Ritual(net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> ingredients, net.minecraft.world.effect.MobEffectInstance output, int requiredEnchantingPower) Creates an instance of aRitualrecord class.- Parameters:
ingredients- the value for theingredientsrecord componentoutput- the value for theoutputrecord componentrequiredEnchantingPower- the value for therequiredEnchantingPowerrecord component
-
-
Method Details
-
matches
- Specified by:
matchesin interfacenet.minecraft.world.item.crafting.Recipe<RitualRecipeInput>
-
assemble
public net.minecraft.world.item.ItemStack assemble(RitualRecipeInput input, net.minecraft.core.HolderLookup.Provider registries) - Specified by:
assemblein interfacenet.minecraft.world.item.crafting.Recipe<RitualRecipeInput>
-
canCraftInDimensions
public boolean canCraftInDimensions(int width, int height) - Specified by:
canCraftInDimensionsin interfacenet.minecraft.world.item.crafting.Recipe<RitualRecipeInput>
-
getResultItem
public net.minecraft.world.item.ItemStack getResultItem(net.minecraft.core.HolderLookup.Provider registries) - Specified by:
getResultItemin interfacenet.minecraft.world.item.crafting.Recipe<RitualRecipeInput>
-
getSerializer
public net.minecraft.world.item.crafting.RecipeSerializer<?> getSerializer()- Specified by:
getSerializerin interfacenet.minecraft.world.item.crafting.Recipe<RitualRecipeInput>
-
getType
public net.minecraft.world.item.crafting.RecipeType<?> getType()- Specified by:
getTypein interfacenet.minecraft.world.item.crafting.Recipe<RitualRecipeInput>
-
getIngredients
public net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> getIngredients()- Specified by:
getIngredientsin interfacenet.minecraft.world.item.crafting.Recipe<RitualRecipeInput>
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
ingredients
public net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> ingredients()Returns the value of theingredientsrecord component.- Returns:
- the value of the
ingredientsrecord component
-
output
public net.minecraft.world.effect.MobEffectInstance output()Returns the value of theoutputrecord component.- Returns:
- the value of the
outputrecord component
-
requiredEnchantingPower
public int requiredEnchantingPower()Returns the value of therequiredEnchantingPowerrecord component.- Returns:
- the value of the
requiredEnchantingPowerrecord component
-