Package dev.architectury.fluid
Class FluidStack
java.lang.Object
dev.architectury.fluid.FluidStack
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic longcopy()copyWithAmount(long amount) static FluidStackcreate(FluidStack stack, long amount) static FluidStackstatic FluidStackcreate(Supplier<net.minecraft.world.level.material.Fluid> fluid, long amount, @Nullable net.minecraft.nbt.CompoundTag tag) static FluidStackcreate(net.minecraft.world.level.material.Fluid fluid, long amount) static FluidStackcreate(net.minecraft.world.level.material.Fluid fluid, long amount, @Nullable net.minecraft.nbt.CompoundTag tag) static FluidStackempty()booleanlong@Nullable net.minecraft.nbt.CompoundTaggetChildTag(String childName) net.minecraft.world.level.material.FluidgetFluid()net.minecraft.network.chat.ComponentgetName()net.minecraft.nbt.CompoundTaggetOrCreateChildTag(String childName) net.minecraft.nbt.CompoundTag@Nullable net.minecraft.world.level.material.FluidSupplier<net.minecraft.world.level.material.Fluid>@Nullable net.minecraft.nbt.CompoundTaggetTag()voidgrow(long amount) inthashCode()booleanhasTag()static voidinit()booleanisEmpty()booleanisFluidEqual(FluidStack other) booleanisFluidStackEqual(FluidStack other) booleanisTagEqual(FluidStack other) static FluidStackread(net.minecraft.nbt.CompoundTag tag) static FluidStackread(net.minecraft.network.FriendlyByteBuf buf) voidremoveChildTag(String childName) voidsetAmount(long amount) voidsetTag(@Nullable net.minecraft.nbt.CompoundTag tag) voidshrink(long amount) net.minecraft.nbt.CompoundTagwrite(net.minecraft.nbt.CompoundTag tag) voidwrite(net.minecraft.network.FriendlyByteBuf buf)
-
Method Details
-
empty
-
create
public static FluidStack create(net.minecraft.world.level.material.Fluid fluid, long amount, @Nullable @Nullable net.minecraft.nbt.CompoundTag tag) -
create
-
create
public static FluidStack create(Supplier<net.minecraft.world.level.material.Fluid> fluid, long amount, @Nullable @Nullable net.minecraft.nbt.CompoundTag tag) -
create
public static FluidStack create(Supplier<net.minecraft.world.level.material.Fluid> fluid, long amount) -
create
-
bucketAmount
public static long bucketAmount() -
getFluid
public net.minecraft.world.level.material.Fluid getFluid() -
getRawFluid
@Nullable public @Nullable net.minecraft.world.level.material.Fluid getRawFluid() -
getRawFluidSupplier
-
isEmpty
public boolean isEmpty() -
getAmount
public long getAmount() -
setAmount
public void setAmount(long amount) -
grow
public void grow(long amount) -
shrink
public void shrink(long amount) -
hasTag
public boolean hasTag() -
getTag
@Nullable public @Nullable net.minecraft.nbt.CompoundTag getTag() -
setTag
public void setTag(@Nullable @Nullable net.minecraft.nbt.CompoundTag tag) -
getOrCreateTag
public net.minecraft.nbt.CompoundTag getOrCreateTag() -
getChildTag
-
getOrCreateChildTag
-
removeChildTag
-
getName
public net.minecraft.network.chat.Component getName() -
getTranslationKey
-
copy
-
hashCode
public int hashCode() -
equals
-
isFluidStackEqual
-
isFluidEqual
-
isTagEqual
-
read
-
read
-
write
public void write(net.minecraft.network.FriendlyByteBuf buf) -
write
public net.minecraft.nbt.CompoundTag write(net.minecraft.nbt.CompoundTag tag) -
copyWithAmount
-
init
@Internal public static void init()
-