public class TilePipeHolder extends TileBC_Neptune implements IPipeHolder, net.minecraft.util.ITickable, IDebuggable
IPipeHolder.IWriter, IPipeHolder.PipeMessageReceiver
Modifier and Type | Field and Description |
---|---|
PipeEventBus |
eventBus |
protected static IdAllocator |
IDS |
static int |
NET_UPDATE_MULTI |
static int |
NET_UPDATE_PIPE_BEHAVIOUR |
static int |
NET_UPDATE_PIPE_FLOW |
static int |
NET_UPDATE_PLUG_DOWN |
static int |
NET_UPDATE_PLUG_EAST |
static int |
NET_UPDATE_PLUG_NORTH |
static int |
NET_UPDATE_PLUG_SOUTH |
static int |
NET_UPDATE_PLUG_UP |
static int |
NET_UPDATE_PLUG_WEST |
static int[] |
NET_UPDATE_PLUGS |
static int |
NET_UPDATE_WIRES |
WireManager |
wireManager |
caps, DEBUG, deltaManager, itemManager, NET_ADV_DEBUG, NET_ADV_DEBUG_DISABLE, NET_GUI_DATA, NET_GUI_DELTA_CLEAR, NET_GUI_DELTA_SINGLE, NET_GUI_TICK, NET_REDRAW, NET_REN_DELTA_CLEAR, NET_REN_DELTA_SINGLE, NET_RENDER_DATA, tankManager
Constructor and Description |
---|
TilePipeHolder() |
Modifier and Type | Method and Description |
---|---|
boolean |
canPlayerInteract(net.minecraft.entity.player.EntityPlayer player) |
boolean |
fireEvent(PipeEvent event) |
<T> T |
getCapability(net.minecraftforge.common.capabilities.Capability<T> capability,
net.minecraft.util.EnumFacing facing) |
<T> T |
getCapabilityFromPipe(net.minecraft.util.EnumFacing side,
net.minecraftforge.common.capabilities.Capability<T> capability)
Gets the given capability going outwards from the pipe.
|
void |
getDebugInfo(java.util.List<java.lang.String> left,
java.util.List<java.lang.String> right,
net.minecraft.util.EnumFacing side)
Get the debug information from a tile entity as a list of strings, used for the F3 debug menu.
|
IdAllocator |
getIdAllocator() |
IPipe |
getNeighbourPipe(net.minecraft.util.EnumFacing side) |
Pipe |
getPipe() |
net.minecraft.util.math.BlockPos |
getPipePos() |
net.minecraft.tileentity.TileEntity |
getPipeTile() |
net.minecraft.world.World |
getPipeWorld() |
PipePluggable |
getPluggable(net.minecraft.util.EnumFacing side) |
int |
getRedstoneInput(net.minecraft.util.EnumFacing side)
Get the redstone input from a given side.
|
int |
getRedstoneOutput(net.minecraft.util.EnumFacing side) |
WireManager |
getWireManager() |
boolean |
hasFastRenderer() |
void |
invalidate() |
void |
onChunkUnload() |
void |
onLoad() |
void |
onNeighbourBlockChanged(net.minecraft.block.Block block,
net.minecraft.util.math.BlockPos nehighbour) |
void |
onPlacedBy(net.minecraft.entity.EntityLivingBase placer,
net.minecraft.item.ItemStack stack) |
void |
readFromNBT(net.minecraft.nbt.NBTTagCompound nbt) |
void |
readPayload(int id,
PacketBufferBC buffer,
net.minecraftforge.fml.relauncher.Side side,
net.minecraftforge.fml.common.network.simpleimpl.MessageContext ctx) |
PipePluggable |
replacePluggable(net.minecraft.util.EnumFacing side,
PipePluggable with) |
void |
scheduleNetworkGuiUpdate(IPipeHolder.PipeMessageReceiver... parts)
Schedules a GUI network update, that is only the players who currently have a pipe element open in a GUI will be
updated.
|
void |
scheduleNetworkUpdate(IPipeHolder.PipeMessageReceiver... parts) |
void |
scheduleRenderUpdate() |
void |
sendGuiMessage(IPipeHolder.PipeMessageReceiver to,
IPipeHolder.IWriter writer) |
void |
sendMessage(IPipeHolder.PipeMessageReceiver to,
IPipeHolder.IWriter writer)
Sends a custom message from a pluggable or pipe centre to the server/client (depending on which side this is
currently on).
|
boolean |
setRedstoneOutput(net.minecraft.util.EnumFacing side,
int value)
Set the redstone input for a given side.
|
void |
update() |
void |
validate() |
void |
writePayload(int id,
PacketBufferBC buffer,
net.minecraftforge.fml.relauncher.Side side) |
net.minecraft.nbt.NBTTagCompound |
writeToNBT(net.minecraft.nbt.NBTTagCompound nbt) |
addDrops, canEditOther, canInteractWith, cannotUpdate, canPlayerEdit, createAndSendGuiMessage, createAndSendGuiMessage, createAndSendMessage, createAndSendMessage, createMessage, createNetworkUpdate, disableDebugging, doesExistInWorld, enableDebugging, getCurrentState, getCurrentStateForBlock, getDebugRenderer, getLocalState, getLocalTile, getNeighbourState, getNeighbourTile, getOffsetState, getOffsetTile, getOwner, getPermBlock, getUpdatePacket, getUpdateTag, handleUpdateTag, hasCapability, isBeingDebugged, markChunkDirty, migrateOldNBT, onActivated, onDataPacket, onExplode, onPlayerClose, onPlayerOpen, onRemove, onSlotChange, receivePayload, redrawBlock, sendDebugState, sendNetworkGuiTick, sendNetworkGuiUpdate, sendNetworkUpdate, sendNetworkUpdate, setWorldCreate, shouldRefresh
addInfoToCrashReport, canRenderBreaking, create, deserializeNBT, getBlockMetadata, getBlockType, getDisplayName, getDistanceSq, getKey, getMaxRenderDistanceSquared, getPos, getRenderBoundingBox, getTileData, getWorld, hasWorld, isInvalid, markDirty, mirror, onlyOpsCanSetNbt, receiveClientEvent, register, restrictNBTCopy, rotate, serializeNBT, setPos, setWorld, shouldRenderInPass, updateContainingBlockInfo
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getNeighbourTile, getOwner, onPlayerClose, onPlayerOpen
getClientDebugInfo
protected static final IdAllocator IDS
public static final int NET_UPDATE_MULTI
public static final int NET_UPDATE_PIPE_BEHAVIOUR
public static final int NET_UPDATE_PIPE_FLOW
public static final int NET_UPDATE_PLUG_DOWN
public static final int NET_UPDATE_PLUG_UP
public static final int NET_UPDATE_PLUG_NORTH
public static final int NET_UPDATE_PLUG_SOUTH
public static final int NET_UPDATE_PLUG_WEST
public static final int NET_UPDATE_PLUG_EAST
public static final int NET_UPDATE_WIRES
public static final int[] NET_UPDATE_PLUGS
public final WireManager wireManager
public final PipeEventBus eventBus
public IdAllocator getIdAllocator()
getIdAllocator
in class TileBC_Neptune
IdAllocator
that allocates all ID's for this class, and its parent classes. All subclasses
should override this if they allocate their own ids after calling
IdAllocator.makeChild(String)
public net.minecraft.nbt.NBTTagCompound writeToNBT(net.minecraft.nbt.NBTTagCompound nbt)
writeToNBT
in class TileBC_Neptune
public void readFromNBT(net.minecraft.nbt.NBTTagCompound nbt)
readFromNBT
in class TileBC_Neptune
public void onPlacedBy(net.minecraft.entity.EntityLivingBase placer, net.minecraft.item.ItemStack stack)
onPlacedBy
in class TileBC_Neptune
public void invalidate()
invalidate
in class net.minecraft.tileentity.TileEntity
public void validate()
validate
in class net.minecraft.tileentity.TileEntity
public void onChunkUnload()
onChunkUnload
in class net.minecraft.tileentity.TileEntity
public void onLoad()
onLoad
in class net.minecraft.tileentity.TileEntity
public void onNeighbourBlockChanged(net.minecraft.block.Block block, net.minecraft.util.math.BlockPos nehighbour)
onNeighbourBlockChanged
in class TileBC_Neptune
public void update()
update
in interface net.minecraft.util.ITickable
public void writePayload(int id, PacketBufferBC buffer, net.minecraftforge.fml.relauncher.Side side)
writePayload
in class TileBC_Neptune
public void readPayload(int id, PacketBufferBC buffer, net.minecraftforge.fml.relauncher.Side side, net.minecraftforge.fml.common.network.simpleimpl.MessageContext ctx) throws java.io.IOException
readPayload
in class TileBC_Neptune
ctx
- The context. Will be null if this is a generic update payloadjava.io.IOException
- if something went wrongpublic net.minecraft.world.World getPipeWorld()
getPipeWorld
in interface IPipeHolder
public net.minecraft.util.math.BlockPos getPipePos()
getPipePos
in interface IPipeHolder
public net.minecraft.tileentity.TileEntity getPipeTile()
getPipeTile
in interface IPipeHolder
public Pipe getPipe()
getPipe
in interface IPipeHolder
public boolean canPlayerInteract(net.minecraft.entity.player.EntityPlayer player)
canPlayerInteract
in interface IPipeHolder
public PipePluggable getPluggable(net.minecraft.util.EnumFacing side)
getPluggable
in interface IPipeHolder
public PipePluggable replacePluggable(net.minecraft.util.EnumFacing side, PipePluggable with)
public IPipe getNeighbourPipe(net.minecraft.util.EnumFacing side)
getNeighbourPipe
in interface IPipeHolder
public <T> T getCapabilityFromPipe(net.minecraft.util.EnumFacing side, @Nonnull net.minecraftforge.common.capabilities.Capability<T> capability)
IPipeHolder
PipePluggable.getInternalCapability(Capability)
first, and the look at the neighbouring tile.getCapabilityFromPipe
in interface IPipeHolder
public void scheduleRenderUpdate()
scheduleRenderUpdate
in interface IPipeHolder
public void scheduleNetworkUpdate(IPipeHolder.PipeMessageReceiver... parts)
scheduleNetworkUpdate
in interface IPipeHolder
parts
- The parts that want to send a network update.public void scheduleNetworkGuiUpdate(IPipeHolder.PipeMessageReceiver... parts)
IPipeHolder
scheduleNetworkGuiUpdate
in interface IPipeHolder
parts
- The parts that want to send a network update.public void sendMessage(IPipeHolder.PipeMessageReceiver to, IPipeHolder.IWriter writer)
IPipeHolder
sendMessage
in interface IPipeHolder
public void sendGuiMessage(IPipeHolder.PipeMessageReceiver to, IPipeHolder.IWriter writer)
sendGuiMessage
in interface IPipeHolder
public WireManager getWireManager()
getWireManager
in interface IPipeHolder
public boolean fireEvent(PipeEvent event)
fireEvent
in interface IPipeHolder
public int getRedstoneInput(net.minecraft.util.EnumFacing side)
IRedstoneStatementContainer
getRedstoneInput
in interface IRedstoneStatementContainer
side
- The side - use "null" for maximum input.public boolean setRedstoneOutput(net.minecraft.util.EnumFacing side, int value)
IRedstoneStatementContainer
setRedstoneOutput
in interface IRedstoneStatementContainer
side
- The side - use "null" for all sides.public int getRedstoneOutput(net.minecraft.util.EnumFacing side)
public <T> T getCapability(@Nonnull net.minecraftforge.common.capabilities.Capability<T> capability, net.minecraft.util.EnumFacing facing)
getCapability
in interface net.minecraftforge.common.capabilities.ICapabilityProvider
getCapability
in class TileBC_Neptune
public void getDebugInfo(java.util.List<java.lang.String> left, java.util.List<java.lang.String> right, net.minecraft.util.EnumFacing side)
IDebuggable
getDebugInfo
in interface IDebuggable
side
- The side the block was clicked on, may be null if we don't know, or is the "centre" sidepublic boolean hasFastRenderer()
hasFastRenderer
in class net.minecraft.tileentity.TileEntity