YATS/Forge Documentation
 All Classes Namespaces Files Functions Variables Enumerator Pages
net.minecraftforge.liquids.ITankContainer Interface Reference

Public Member Functions

int fill (ForgeDirection from, LiquidStack resource, boolean doFill)
 
int fill (int tankIndex, LiquidStack resource, boolean doFill)
 
LiquidStack drain (ForgeDirection from, int maxDrain, boolean doDrain)
 
LiquidStack drain (int tankIndex, int maxDrain, boolean doDrain)
 
ILiquidTank[] getTanks (ForgeDirection direction)
 
ILiquidTank getTank (ForgeDirection direction, LiquidStack type)
 

Member Function Documentation

LiquidStack net.minecraftforge.liquids.ITankContainer.drain ( ForgeDirection  from,
int  maxDrain,
boolean  doDrain 
)

Drains liquid out of internal tanks, distribution is left to the ITankContainer.

Parameters
fromOrientation the liquid is drained to.
maxDrainMaximum amount of liquid to drain.
doDrainIf false draining will only be simulated.
Returns
LiquidStack representing the liquid and amount actually drained from the ITankContainer
LiquidStack net.minecraftforge.liquids.ITankContainer.drain ( int  tankIndex,
int  maxDrain,
boolean  doDrain 
)

Drains liquid out of the specified internal tank.

Parameters
tankIndexthe index of the tank to drain
maxDrainMaximum amount of liquid to drain.
doDrainIf false draining will only be simulated.
Returns
LiquidStack representing the liquid and amount actually drained from the ITankContainer
int net.minecraftforge.liquids.ITankContainer.fill ( ForgeDirection  from,
LiquidStack  resource,
boolean  doFill 
)

Fills liquid into internal tanks, distribution is left to the ITankContainer.

Parameters
fromOrientation the liquid is pumped in from.
resourceLiquidStack representing the maximum amount of liquid filled into the ITankContainer
doFillIf false filling will only be simulated.
Returns
Amount of resource that was filled into internal tanks.
int net.minecraftforge.liquids.ITankContainer.fill ( int  tankIndex,
LiquidStack  resource,
boolean  doFill 
)

Fills liquid into the specified internal tank.

Parameters
tankIndexthe index of the tank to fill
resourceLiquidStack representing the maximum amount of liquid filled into the ITankContainer
doFillIf false filling will only be simulated.
Returns
Amount of resource that was filled into internal tanks.
ILiquidTank net.minecraftforge.liquids.ITankContainer.getTank ( ForgeDirection  direction,
LiquidStack  type 
)

Return the tank that this tank container desired to be used for the specified liquid type from the specified direction

Parameters
directionthe direction
typethe liquid type, null is always an acceptable value
Returns
a tank or null for no such tank
ILiquidTank [] net.minecraftforge.liquids.ITankContainer.getTanks ( ForgeDirection  direction)
Parameters
directiontank side: UNKNOWN for default tank set
Returns
Array of LiquidTanks contained in this ITankContainer for this direction

The documentation for this interface was generated from the following file: