Package alexiil.mc.lib.attributes.fluid
package alexiil.mc.lib.attributes.fluid
The base package for
fluid
management.
As vanilla minecraft doesn't use fluids as much as items there are a few key differences between how this package
works verses alexiil.mc.lib.attributes.item
:
- Instead of
ItemStack
we haveFluidVolume
(with an amount) andFluidKey
(without an amount) - Slots are called "tanks"
- Tanks/Slots do not have a pre-defined maximum amount (and neither do fluids themselves as that depends wholly on the container).
- The units for fluids are fractional amounts based on 1+0/1 being equal to 1 bucket, stored in
FluidAmount
.
-
InterfaceDescriptionA
FixedFluidInvView
that can have it's contents changed.A view of a fixed inventory for fluids, where the number of tanks never changes, and every tank is "simple": The fluid will stay in the tank until it is removed or changed by something else.Stack return function forFluidContainerRegistry.FluidFillHandler.insert(ItemStack, FluidVolume, Simulation, StackReturnFunc)
Defines an object that can have fluids extracted from it.Defines an object that can have fluids inserted into it.Deprecated, for removal: This API element is subject to removal in a future version.Deprecated, for removal: This API element is subject to removal in a future version.Combined interface forFluidInsertable
andFluidExtractable
.A modifiable version ofGroupedFluidInvView
, except that all modification methods are provided byFluidExtractable
andFluidInsertable
.Items that implementBucketItem
should implement this interface to ensure that LBA gets the correctItemStack
from filling this with a fluid.A type ofFixedFluidInv
that wraps an existingFixedFluidInv
and provides custom control over the actual modification of the wrappedFixedFluidInv
.A rule for a set of tanks.A rule that is applied once for everyFluidKey
that matches theFluidFilter
that was used inLimitedGroupedFluidInv.getRule(FluidFilter)
. -
ClassDescriptionCentral storage for fluid
Attribute
instances.MapsItem
instances to empty and full containers.Fill handler for an emptyItemStack
.4 base methods for interacting aReference
of anItemStack
with aFixedFluidInv
,FluidTransferable
, orFluidInsertable
&FluidExtractable
pair.Various utilities for dealing with fluids contained in singleItemStack
s.Statistics associated with a singleFluidFilter
in a given inventory.Stores various options for LBA-fluids.A delegating accessor of a single slot in aFixedFluidInv
.A delegating view of a single slot in aFixedFluidInvView
.
FluidContainerRegistry
.