Pylon Fluid Tank
A common pattern is a 'fluid tank' which can only store one fluid at a time, but can store many types of fluids. PylonFluidTank implements this pattern.
You must call setCapacity for this block to work.
As with PylonFluidBufferBlock, you do not need to handle saving buffers or implement any of the PylonFluidBlock methods for this; this is all done automatically.
Properties
Functions
Checks if a new amount of fluid is greater than zero and fits inside the tank.
Returns the amount of the given fluid that the machine wants to receive next tick.
Returns a map of fluid types - and their corresponding amounts - that can be supplied by the block for this fluid tick. deltaSeconds is the time since the last fluid tick.
amount is always at most getRequestedFluids().get(fluid) and will never be zero or less.
amount is always at least getSuppliedFluids().get(fluid) and will never be zero or less.
Removes from the tank only if the new amount of fluid is greater than zero and fits in the tank.
Sets the capacity of the fluid tank
Sets the type of fluid in the fluid tank