Modifier and Type | Method and Description |
---|---|
default FluidStack |
IForgePacketBuffer.readFluidStack()
Reads a FluidStack from this buffer.
|
Modifier and Type | Method and Description |
---|---|
default void |
IForgePacketBuffer.writeFluidStack(FluidStack stack)
Writes a FluidStack to the packet buffer, easy enough.
|
Modifier and Type | Field and Description |
---|---|
static FluidStack |
FluidStack.EMPTY |
Modifier and Type | Method and Description |
---|---|
FluidStack |
FluidStack.copy() |
FluidStack |
IFluidTank.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
FluidStack |
IFluidTank.drain(int maxDrain,
IFluidHandler.FluidAction action) |
FluidStack |
IFluidBlock.drain(World world,
BlockPos pos,
IFluidHandler.FluidAction action)
Attempt to drain the block.
|
FluidStack |
IFluidTank.getFluid() |
static FluidStack |
FluidStack.loadFluidStackFromNBT(CompoundNBT nbt)
This provides a safe method for retrieving a FluidStack - if the Fluid is invalid, the stack
will return as null.
|
static FluidStack |
FluidStack.readFromPacket(PacketBuffer buf) |
private static FluidStack |
FluidUtil.tryFluidTransfer_Internal(IFluidHandler fluidDestination,
IFluidHandler fluidSource,
FluidStack drainable,
boolean doTransfer)
Internal method for filling a destination fluid handler from a source fluid handler using a specific fluid.
|
static FluidStack |
FluidUtil.tryFluidTransfer(IFluidHandler fluidDestination,
IFluidHandler fluidSource,
FluidStack resource,
boolean doTransfer)
Fill a destination fluid handler from a source fluid handler using a specific fluid.
|
static FluidStack |
FluidUtil.tryFluidTransfer(IFluidHandler fluidDestination,
IFluidHandler fluidSource,
int maxAmount,
boolean doTransfer)
Fill a destination fluid handler from a source fluid handler with a max amount.
|
Modifier and Type | Method and Description |
---|---|
static LazyOptional<FluidStack> |
FluidUtil.getFluidContained(ItemStack container)
Helper method to get the fluid contained in an itemStack
|
Modifier and Type | Method and Description |
---|---|
static boolean |
FluidStack.areFluidStackTagsEqual(FluidStack stack1,
FluidStack stack2)
Determines if the NBT Tags are equal.
|
boolean |
FluidAttributes.canBePlacedInWorld(ILightReader reader,
BlockPos pos,
FluidStack state) |
boolean |
FluidStack.containsFluid(FluidStack other)
Determines if the Fluids are equal and this stack is larger.
|
boolean |
FluidAttributes.doesVaporize(ILightReader reader,
BlockPos pos,
FluidStack fluidStack)
Determines if this fluid should vaporize in dimensions where water vaporizes when placed.
|
FluidStack |
IFluidTank.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
int |
IFluidTank.fill(FluidStack resource,
IFluidHandler.FluidAction action) |
ItemStack |
FluidAttributes.getBucket(FluidStack stack) |
int |
FluidAttributes.getColor(FluidStack stack) |
int |
FluidAttributes.getDensity(FluidStack stack) |
ITextComponent |
FluidAttributes.getDisplayName(FluidStack stack)
Returns the localized name of this fluid.
|
SoundEvent |
FluidAttributes.getEmptySound(FluidStack stack) |
static ItemStack |
FluidUtil.getFilledBucket(FluidStack fluidStack) |
SoundEvent |
FluidAttributes.getFillSound(FluidStack stack) |
ResourceLocation |
FluidAttributes.getFlowingTexture(FluidStack stack) |
int |
FluidAttributes.getLuminosity(FluidStack stack) |
Rarity |
FluidAttributes.getRarity(FluidStack stack) |
IFluidState |
FluidAttributes.getStateForPlacement(ILightReader reader,
BlockPos pos,
FluidStack state) |
ResourceLocation |
FluidAttributes.getStillTexture(FluidStack stack) |
int |
FluidAttributes.getTemperature(FluidStack stack) |
java.lang.String |
FluidAttributes.getTranslationKey(FluidStack stack)
A FluidStack sensitive version of getTranslationKey
|
int |
FluidAttributes.getViscosity(FluidStack stack) |
boolean |
FluidStack.isFluidEqual(FluidStack other)
Determines if the FluidIDs and NBT Tags are equal.
|
boolean |
FluidStack.isFluidStackIdentical(FluidStack other)
Determines if the FluidIDs, Amounts, and NBT Tags are all equal.
|
private boolean |
FluidStack.isFluidStackTagEqual(FluidStack other) |
boolean |
IFluidTank.isFluidValid(FluidStack stack) |
boolean |
FluidAttributes.isGaseous(FluidStack stack) |
int |
IFluidBlock.place(World world,
BlockPos pos,
FluidStack fluidStack,
IFluidHandler.FluidAction action)
Attempts to place the block at a given position.
|
private static FluidStack |
FluidUtil.tryFluidTransfer_Internal(IFluidHandler fluidDestination,
IFluidHandler fluidSource,
FluidStack drainable,
boolean doTransfer)
Internal method for filling a destination fluid handler from a source fluid handler using a specific fluid.
|
static FluidStack |
FluidUtil.tryFluidTransfer(IFluidHandler fluidDestination,
IFluidHandler fluidSource,
FluidStack resource,
boolean doTransfer)
Fill a destination fluid handler from a source fluid handler using a specific fluid.
|
static boolean |
FluidUtil.tryPlaceFluid(PlayerEntity player,
World world,
Hand hand,
BlockPos pos,
IFluidHandler fluidSource,
FluidStack resource)
Tries to place a fluid resource into the world as a block and drains the fluidSource.
|
static FluidActionResult |
FluidUtil.tryPlaceFluid(PlayerEntity player,
World world,
Hand hand,
BlockPos pos,
ItemStack container,
FluidStack resource)
ItemStack version of
#tryPlaceFluid(PlayerEntity, World, BlockPos, IFluidHandler, FluidStack) . |
void |
FluidAttributes.vaporize(PlayerEntity player,
World worldIn,
BlockPos pos,
FluidStack fluidStack)
Called instead of placing the fluid block if
Dimension.doesWaterVaporize() and #doesVaporize(FluidStack) are true. |
Constructor and Description |
---|
FluidStack(FluidStack stack,
int amount) |
Modifier and Type | Method and Description |
---|---|
FluidStack |
IFluidHandler.drain(FluidStack resource,
IFluidHandler.FluidAction action)
Drains fluid out of internal tanks, distribution is left entirely to the IFluidHandler.
|
FluidStack |
IFluidHandler.drain(int maxDrain,
IFluidHandler.FluidAction action)
Drains fluid out of internal tanks, distribution is left entirely to the IFluidHandler.
|
FluidStack |
IFluidHandler.getFluidInTank(int tank)
Returns the FluidStack in a given tank.
|
Modifier and Type | Method and Description |
---|---|
FluidStack |
IFluidHandler.drain(FluidStack resource,
IFluidHandler.FluidAction action)
Drains fluid out of internal tanks, distribution is left entirely to the IFluidHandler.
|
int |
IFluidHandler.fill(FluidStack resource,
IFluidHandler.FluidAction action)
Fills fluid into internal tanks, distribution is left entirely to the IFluidHandler.
|
boolean |
IFluidHandler.isFluidValid(int tank,
FluidStack stack)
This function is a way to determine which fluids can exist inside a given handler.
|
Modifier and Type | Field and Description |
---|---|
protected FluidStack |
FluidTank.fluid |
Modifier and Type | Field and Description |
---|---|
protected java.util.function.Predicate<FluidStack> |
FluidTank.validator |
Modifier and Type | Method and Description |
---|---|
FluidStack |
VoidFluidHandler.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
FluidStack |
FluidHandlerItemStackSimple.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
FluidStack |
FluidTank.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
FluidStack |
FluidHandlerItemStack.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
FluidStack |
EmptyFluidHandler.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
FluidStack |
VoidFluidHandler.drain(int maxDrain,
IFluidHandler.FluidAction action) |
FluidStack |
FluidHandlerItemStackSimple.drain(int maxDrain,
IFluidHandler.FluidAction action) |
FluidStack |
FluidTank.drain(int maxDrain,
IFluidHandler.FluidAction action) |
FluidStack |
FluidHandlerItemStack.drain(int maxDrain,
IFluidHandler.FluidAction action) |
FluidStack |
EmptyFluidHandler.drain(int maxDrain,
IFluidHandler.FluidAction action) |
FluidStack |
FluidHandlerItemStackSimple.getFluid() |
FluidStack |
FluidTank.getFluid() |
FluidStack |
FluidHandlerItemStack.getFluid() |
FluidStack |
VoidFluidHandler.getFluidInTank(int tank) |
FluidStack |
FluidHandlerItemStackSimple.getFluidInTank(int tank) |
FluidStack |
FluidTank.getFluidInTank(int tank) |
FluidStack |
FluidHandlerItemStack.getFluidInTank(int tank) |
FluidStack |
EmptyFluidHandler.getFluidInTank(int tank) |
Modifier and Type | Method and Description |
---|---|
boolean |
FluidHandlerItemStackSimple.canDrainFluidType(FluidStack fluid) |
boolean |
FluidHandlerItemStack.canDrainFluidType(FluidStack fluid) |
boolean |
FluidHandlerItemStackSimple.canFillFluidType(FluidStack fluid) |
boolean |
FluidHandlerItemStack.canFillFluidType(FluidStack fluid) |
FluidStack |
VoidFluidHandler.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
FluidStack |
FluidHandlerItemStackSimple.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
FluidStack |
FluidTank.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
FluidStack |
FluidHandlerItemStack.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
FluidStack |
EmptyFluidHandler.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
int |
VoidFluidHandler.fill(FluidStack resource,
IFluidHandler.FluidAction action) |
int |
FluidHandlerItemStackSimple.fill(FluidStack resource,
IFluidHandler.FluidAction action) |
int |
FluidTank.fill(FluidStack resource,
IFluidHandler.FluidAction action) |
int |
FluidHandlerItemStack.fill(FluidStack resource,
IFluidHandler.FluidAction doFill) |
int |
EmptyFluidHandler.fill(FluidStack resource,
IFluidHandler.FluidAction action) |
boolean |
FluidTank.isFluidValid(FluidStack stack) |
boolean |
VoidFluidHandler.isFluidValid(int tank,
FluidStack stack) |
boolean |
FluidHandlerItemStackSimple.isFluidValid(int tank,
FluidStack stack) |
boolean |
FluidTank.isFluidValid(int tank,
FluidStack stack) |
boolean |
FluidHandlerItemStack.isFluidValid(int tank,
FluidStack stack) |
boolean |
EmptyFluidHandler.isFluidValid(int tank,
FluidStack stack) |
protected void |
FluidHandlerItemStackSimple.setFluid(FluidStack fluid) |
void |
FluidTank.setFluid(FluidStack stack) |
protected void |
FluidHandlerItemStack.setFluid(FluidStack fluid) |
Modifier and Type | Method and Description |
---|---|
FluidTank |
FluidTank.setValidator(java.util.function.Predicate<FluidStack> validator) |
Constructor and Description |
---|
FluidTank(int capacity,
java.util.function.Predicate<FluidStack> validator) |
Modifier and Type | Method and Description |
---|---|
FluidStack |
FluidBucketWrapper.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
FluidStack |
FluidBucketWrapper.drain(int maxDrain,
IFluidHandler.FluidAction action) |
FluidStack |
FluidBucketWrapper.getFluid() |
FluidStack |
FluidBucketWrapper.getFluidInTank(int tank) |
Modifier and Type | Method and Description |
---|---|
boolean |
FluidBucketWrapper.canFillFluidType(FluidStack fluid) |
FluidStack |
FluidBucketWrapper.drain(FluidStack resource,
IFluidHandler.FluidAction action) |
int |
BlockWrapper.fill(FluidStack resource,
IFluidHandler.FluidAction action) |
int |
FluidBucketWrapper.fill(FluidStack resource,
IFluidHandler.FluidAction action) |
boolean |
FluidBucketWrapper.isFluidValid(int tank,
FluidStack stack) |
protected void |
FluidBucketWrapper.setFluid(FluidStack fluidStack) |