Uses of Interface
net.minecraftforge.fluids.capability.IFluidHandler
Package
Description
-
Uses of IFluidHandler in net.minecraftforge.common.capabilities
Modifier and TypeFieldDescriptionstatic final Capability<IFluidHandler>
ForgeCapabilities.FLUID_HANDLER
-
Uses of IFluidHandler in net.minecraftforge.fluids
Modifier and TypeMethodDescriptionprivate static IFluidHandler
FluidUtil.getFluidBlockHandler
(Fluid fluid, Level level, BlockPos pos) Internal method for getting a fluid block handler for placing a fluid.Modifier and TypeMethodDescriptionstatic LazyOptional<IFluidHandler>
FluidUtil.getFluidHandler
(Level level, BlockPos blockPos, @Nullable Direction side) Helper method to get an IFluidHandler for at a block position.Modifier and TypeMethodDescriptionstatic boolean
FluidUtil.interactWithFluidHandler
(@NotNull Player player, @NotNull InteractionHand hand, @NotNull IFluidHandler handler) Used to handle the common case of a player holding a fluid item and right-clicking on a fluid handler.static @NotNull FluidActionResult
FluidUtil.tryEmptyContainer
(@NotNull ItemStack container, IFluidHandler fluidDestination, int maxAmount, @Nullable Player player, boolean doDrain) Takes a filled container and tries to empty it into the given tank.static @NotNull FluidActionResult
FluidUtil.tryEmptyContainerAndStow
(@NotNull ItemStack container, IFluidHandler fluidDestination, IItemHandler inventory, int maxAmount, @Nullable Player player, boolean doDrain) Takes an Fluid Container Item, tries to empty it into the fluid handler, and stows it in the given inventory.static @NotNull FluidActionResult
FluidUtil.tryFillContainer
(@NotNull ItemStack container, IFluidHandler fluidSource, int maxAmount, @Nullable Player player, boolean doFill) Fill a container from the given fluidSource.static @NotNull FluidActionResult
FluidUtil.tryFillContainerAndStow
(@NotNull ItemStack container, IFluidHandler fluidSource, IItemHandler inventory, int maxAmount, @Nullable Player player, boolean doFill) Takes an Fluid Container Item and tries to fill it from the given tank.static @NotNull 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.static @NotNull 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.private static @NotNull 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 boolean
FluidUtil.tryPlaceFluid
(@Nullable Player player, Level level, InteractionHand hand, BlockPos pos, IFluidHandler fluidSource, FluidStack resource) Tries to place a fluid resource into the level as a block and drains the fluidSource. -
Uses of IFluidHandler in net.minecraftforge.fluids.capability
Modifier and TypeInterfaceDescriptioninterface
ItemStacks handled by anIFluidHandler
may change, so this class allows users of the fluid handler to get the container after it has been used.Modifier and TypeFieldDescriptionprivate final LazyOptional<IFluidHandler>
FluidHandlerBlockEntity.holder
-
Uses of IFluidHandler in net.minecraftforge.fluids.capability.templates
Modifier and TypeClassDescriptionclass
class
FluidHandlerItemStack is a template capability provider for ItemStacks.static class
Destroys the container item when it's emptied.static class
Swaps the container item for a different one when it's emptied.class
FluidHandlerItemStackSimple is a template capability provider for ItemStacks.static class
Destroys the container item when it's emptied.static class
Swaps the container item for a different one when it's emptied.class
Flexible implementation of a Fluid Storage object.class
VoidFluidHandler is a template fluid handler that can be filled indefinitely without ever getting full. -
Uses of IFluidHandler in net.minecraftforge.fluids.capability.wrappers
Modifier and TypeClassDescriptionclass
Wrapper around any block, only accounts for fluid placement, otherwise the block acts a void.static class
class
class
class
Wrapper for vanilla and forge buckets.