public class PipeFlowPower extends PipeFlow implements IFlowPower, IDebuggable
Modifier and Type | Class and Description |
---|---|
static class |
PipeFlowPower.EnumFlow |
class |
PipeFlowPower.Section |
Modifier and Type | Field and Description |
---|---|
static int |
NET_POWER_AMOUNTS |
NET_ID_FULL_STATE, NET_ID_UPDATE, pipe
Constructor and Description |
---|
PipeFlowPower(IPipe pipe) |
PipeFlowPower(IPipe pipe,
net.minecraft.nbt.NBTTagCompound nbt) |
Modifier and Type | Method and Description |
---|---|
boolean |
canConnect(net.minecraft.util.EnumFacing face,
PipeFlow other) |
boolean |
canConnect(net.minecraft.util.EnumFacing face,
net.minecraft.tileentity.TileEntity oTile) |
<T> T |
getCapability(net.minecraftforge.common.capabilities.Capability<T> capability,
net.minecraft.util.EnumFacing facing) |
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.
|
double |
getMaxTransferForRender(float partialTicks) |
boolean |
onFlowActivate(net.minecraft.entity.player.EntityPlayer player,
net.minecraft.util.math.RayTraceResult trace,
float hitX,
float hitY,
float hitZ,
EnumPipePart part) |
void |
onTick() |
void |
readPayload(int id,
net.minecraft.network.PacketBuffer buffer,
net.minecraftforge.fml.relauncher.Side side)
Reads a payload with the specified id.
|
void |
reconfigure()
Makes this pipe reconfigure itself, possibly due to the addition of new modules.
|
long |
tryExtractPower(long maxExtracted,
net.minecraft.util.EnumFacing from)
Attempts to extract power from the
IMjPassiveProvider connected to this pipe on the given side. |
void |
writePayload(int id,
net.minecraft.network.PacketBuffer buffer,
net.minecraftforge.fml.relauncher.Side side)
Writes a payload with the specified id.
|
net.minecraft.nbt.NBTTagCompound |
writeToNbt() |
addDrops, hasCapability, sendCustomPayload, sendPayload
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getClientDebugInfo
public static final int NET_POWER_AMOUNTS
public PipeFlowPower(IPipe pipe)
public PipeFlowPower(IPipe pipe, net.minecraft.nbt.NBTTagCompound nbt)
public net.minecraft.nbt.NBTTagCompound writeToNbt()
writeToNbt
in class PipeFlow
public void writePayload(int id, net.minecraft.network.PacketBuffer buffer, net.minecraftforge.fml.relauncher.Side side)
PipeFlow
writePayload
in class PipeFlow
public void readPayload(int id, net.minecraft.network.PacketBuffer buffer, net.minecraftforge.fml.relauncher.Side side) throws java.io.IOException
PipeFlow
readPayload
in class PipeFlow
java.io.IOException
public boolean canConnect(net.minecraft.util.EnumFacing face, PipeFlow other)
canConnect
in class PipeFlow
public boolean canConnect(net.minecraft.util.EnumFacing face, net.minecraft.tileentity.TileEntity oTile)
canConnect
in class PipeFlow
public void reconfigure()
IFlowPower
reconfigure
in interface IFlowPower
public long tryExtractPower(long maxExtracted, net.minecraft.util.EnumFacing from)
IFlowPower
IMjPassiveProvider
connected to this pipe on the given side.tryExtractPower
in interface IFlowPower
maxExtracted
- The Maximum amount of power that can be extracted.from
- The side (of this pipe) to take power from.public boolean onFlowActivate(net.minecraft.entity.player.EntityPlayer player, net.minecraft.util.math.RayTraceResult trace, float hitX, float hitY, float hitZ, EnumPipePart part)
onFlowActivate
in class PipeFlow
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 PipeFlow
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 double getMaxTransferForRender(float partialTicks)