Package de.cech12.bucketlib.api.crafting
Class FluidIngredient
java.lang.Object
net.minecraft.world.item.crafting.Ingredient
net.minecraftforge.common.crafting.ingredients.AbstractIngredient
de.cech12.bucketlib.api.crafting.FluidIngredient
- All Implemented Interfaces:
Predicate<net.minecraft.world.item.ItemStack>
public class FluidIngredient
extends net.minecraftforge.common.crafting.ingredients.AbstractIngredient
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.world.item.crafting.Ingredient
net.minecraft.world.item.crafting.Ingredient.ItemValue, net.minecraft.world.item.crafting.Ingredient.TagValue, net.minecraft.world.item.crafting.Ingredient.Value -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<FluidIngredient>protected final net.minecraft.world.level.material.Fluidstatic final net.minecraftforge.common.crafting.ingredients.IIngredientSerializer<FluidIngredient>protected final net.minecraft.tags.TagKey<net.minecraft.world.level.material.Fluid>Fields inherited from class net.minecraft.world.item.crafting.Ingredient
CODEC_NONEMPTY, EMPTY, VANILLA_CODEC -
Constructor Summary
ConstructorsConstructorDescriptionFluidIngredient(Optional<net.minecraft.resources.ResourceLocation> fluidOptional, Optional<net.minecraft.tags.TagKey<net.minecraft.world.level.material.Fluid>> tagOptional) FluidIngredient(net.minecraft.tags.TagKey<net.minecraft.world.level.material.Fluid> tag) FluidIngredient(net.minecraft.world.level.material.Fluid fluid) -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.world.item.ItemStack[]getItems()protected voidbooleanisEmpty()booleanisSimple()net.minecraftforge.common.crafting.ingredients.IIngredientSerializer<? extends net.minecraft.world.item.crafting.Ingredient>booleantest(net.minecraft.world.item.ItemStack itemStack) Methods inherited from class net.minecraftforge.common.crafting.ingredients.AbstractIngredient
fromNetwork, fromValues, of, of, of, of, ofMethods inherited from class net.minecraft.world.item.crafting.Ingredient
checkInvalidation, equals, getStackingIds, invalidateAll, isVanilla, markValid, toNetwork, toString
-
Field Details
-
fluid
protected final net.minecraft.world.level.material.Fluid fluid -
tag
protected final net.minecraft.tags.TagKey<net.minecraft.world.level.material.Fluid> tag -
CODEC
-
SERIALIZER
public static final net.minecraftforge.common.crafting.ingredients.IIngredientSerializer<FluidIngredient> SERIALIZER
-
-
Constructor Details
-
FluidIngredient
-
FluidIngredient
public FluidIngredient(net.minecraft.world.level.material.Fluid fluid) -
FluidIngredient
public FluidIngredient(net.minecraft.tags.TagKey<net.minecraft.world.level.material.Fluid> tag)
-
-
Method Details
-
test
public boolean test(net.minecraft.world.item.ItemStack itemStack) -
getItems
@Nonnull public net.minecraft.world.item.ItemStack[] getItems()- Overrides:
getItemsin classnet.minecraft.world.item.crafting.Ingredient
-
isEmpty
public boolean isEmpty()- Overrides:
isEmptyin classnet.minecraft.world.item.crafting.Ingredient
-
isSimple
public boolean isSimple()- Specified by:
isSimplein classnet.minecraftforge.common.crafting.ingredients.AbstractIngredient
-
invalidate
protected void invalidate()- Overrides:
invalidatein classnet.minecraft.world.item.crafting.Ingredient
-
serializer
@Nonnull public net.minecraftforge.common.crafting.ingredients.IIngredientSerializer<? extends net.minecraft.world.item.crafting.Ingredient> serializer()- Specified by:
serializerin classnet.minecraftforge.common.crafting.ingredients.AbstractIngredient
-