Home Commands Examples Getting Started With Scripts Global Keywords
BracketHandlers ForgeBracketDumpers ForgeBracketValidators

FluidIngredient

Importing the class

If you need to reference this type directly, like when casting an Array, or as a parameter, you will need to import it. Simply add the import at the top of the file.

script.zs
import crafttweaker.api.fluid.FluidIngredient;

Description

FluidIngredient that facilitates accepting either a single, or multiple IFluidStacks, <Fluid>s or Many<KnownTag<Fluid>>s.

Implements

FluidIngredient implements the following interfaces:

CommandStringDisplayable

Operators

|(other as CTFluidIngredient) as CTFluidIngredient
script.zs
// (CTFluidIngredient | (other as FluidIngredient)) as FluidIngredient
myCTFluidIngredient | myCTFluidIngredient

Parameters:

Return Type: FluidIngredient

Members

matches(fluid as Fluid) as bool
script.zs
// CTFluidIngredient.matches(fluid as Fluid) as bool;
myCTFluidIngredient.matches(myFluid);

Parameters:

fluid Type: Fluid

Return Type: bool

matches(fluidStack as IFluidStack) as bool
script.zs
// CTFluidIngredient.matches(fluidStack as IFluidStack) as bool;
myCTFluidIngredient.matches(myIFluidStack);

Parameters:

fluidStack Type: IFluidStack

Return Type: bool