T - The subclass of TankInventoryTileEntity, will be in
most cases just the extension class.public abstract class TickingTankInventoryTileEntity<T extends org.cyclops.cyclopscore.tileentity.TankInventoryTileEntity>
extends org.cyclops.cyclopscore.tileentity.TankInventoryTileEntity
implements org.cyclops.cyclopscore.tileentity.CyclopsTileEntity.ITickingTile
TickComponent that are able to tick.
And these components will contain a collection of ITickAction
that can perform specific actions depending on the condition of the TickComponent.TickComponent| Modifier and Type | Field and Description |
|---|---|
protected org.cyclops.cyclopscore.tileentity.CyclopsTileEntity.ITickingTile |
tickingTileComponent |
sendUpdateOnTankChanged, tankSizeinventory, slotSides| Constructor and Description |
|---|
TickingTankInventoryTileEntity(int inventorySize,
java.lang.String inventoryName,
int tankSize,
java.lang.String tankName,
net.minecraftforge.fluids.Fluid acceptedFluid)
Make a new TickingTankInventoryTileEntity.
|
TickingTankInventoryTileEntity(int inventorySize,
java.lang.String inventoryName,
int tankSize,
java.lang.String tankName,
net.minecraftforge.fluids.Fluid acceptedFluid,
int stackSize)
Make a new TickingTankInventoryTileEntity.
|
| Modifier and Type | Method and Description |
|---|---|
protected int |
addTicker(TickComponent<T,ITickAction<T>> ticker)
Add a new ticker.
|
int |
getCurrentState()
Get the current (numerical) state.
|
abstract int |
getNewState()
Get the new (numerical) state for this tile entity.
|
java.util.LinkedList<TickComponent<T,ITickAction<T>>> |
getTickers()
Get the tickers this TileEntity has.
|
abstract void |
onStateChanged()
What needs to happen when the (numerical) state is changed.
|
void |
readFromNBT(net.minecraft.nbt.NBTTagCompound data) |
void |
updateTileEntity() |
void |
writeToNBT(net.minecraft.nbt.NBTTagCompound data) |
canDrain, canFill, drain, drain, drain, drain, fill, fill, getTank, getTankInfo, isSendUpdateOnTankChanged, newTank, onSendUpdate, setSendUpdateOnTankChangedaddSlotsToSide, getInventory, getSlotsForFacecanAccess, canExtractItem, canInsertItem, clear, closeInventory, decrStackSize, getDisplayName, getField, getFieldCount, getInventoryStackLimit, getName, getSizeInventory, getStackInSlot, hasCustomName, isItemValidForSlot, isSendUpdateOnInventoryChanged, isUseableByPlayer, onInventoryChanged, openInventory, removeStackFromSlot, setField, setInventorySlotContents, setSendUpdateOnInventoryChangedaddCapabilityInternal, addCapabilitySided, afterSendUpdate, beforeSendUpdate, canInteractWith, destroy, getBlock, getCapabilities, getCapability, getDescriptionPacket, getNBTTagCompound, getRotation, getUpdateBackoffTicks, hasCapability, isRotatable, isTicking, onDataPacket, onLoad, onUpdateReceived, readGeneratedFieldsFromNBT, sendImmediateUpdate, sendUpdate, setRotatable, setRotation, shouldRefresh, writeGeneratedFieldsToNBTaddInfoToCrashReport, addMapping, canRenderBreaking, createAndLoadEntity, deserializeNBT, func_183000_F, getBlockMetadata, getBlockType, getDistanceSq, getMaxRenderDistanceSquared, getPos, getRenderBoundingBox, getTileData, getWorld, hasFastRenderer, hasWorldObj, invalidate, isInvalid, markDirty, onChunkUnload, receiveClientEvent, restrictNBTCopy, serializeNBT, setPos, setWorldObj, shouldRenderInPass, updateContainingBlockInfo, validateprotected final org.cyclops.cyclopscore.tileentity.CyclopsTileEntity.ITickingTile tickingTileComponent
public TickingTankInventoryTileEntity(int inventorySize,
java.lang.String inventoryName,
int tankSize,
java.lang.String tankName,
net.minecraftforge.fluids.Fluid acceptedFluid,
int stackSize)
inventorySize - Amount of slots in the inventory.inventoryName - Internal name of the inventory.tankSize - Size (mB) of the tank.tankName - Internal name of the tank.acceptedFluid - Type of Fluid to accept.stackSize - The maximum stacksize each slot can have.public TickingTankInventoryTileEntity(int inventorySize,
java.lang.String inventoryName,
int tankSize,
java.lang.String tankName,
net.minecraftforge.fluids.Fluid acceptedFluid)
inventorySize - Amount of slots in the inventory.inventoryName - Internal name of the inventory.tankSize - Size (mB) of the tank.tankName - Internal name of the tank.acceptedFluid - Type of Fluid to accept.protected int addTicker(TickComponent<T,ITickAction<T>> ticker)
ticker - The ticker to (try) run every tick.public java.util.LinkedList<TickComponent<T,ITickAction<T>>> getTickers()
public void readFromNBT(net.minecraft.nbt.NBTTagCompound data)
readFromNBT in class org.cyclops.cyclopscore.tileentity.TankInventoryTileEntitypublic void writeToNBT(net.minecraft.nbt.NBTTagCompound data)
writeToNBT in class org.cyclops.cyclopscore.tileentity.TankInventoryTileEntitypublic void updateTileEntity()
updateTileEntity in class org.cyclops.cyclopscore.tileentity.CyclopsTileEntitypublic abstract int getNewState()
public abstract void onStateChanged()
public int getCurrentState()