Fixed firebox geothermal lava pumping
This commit is contained in:
parent
7c62716a5f
commit
ad974aab79
5 changed files with 16 additions and 4 deletions
|
@ -15,6 +15,7 @@ import net.minecraft.world.IBlockAccess;
|
|||
import net.minecraft.world.World;
|
||||
import resonantinduction.core.Reference;
|
||||
import calclavia.lib.prefab.block.BlockTile;
|
||||
import calclavia.lib.utility.FluidUtility;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
|
@ -74,6 +75,12 @@ public class BlockFirebox extends BlockTile
|
|||
if (tileEntity instanceof TileFirebox)
|
||||
{
|
||||
TileFirebox tile = (TileFirebox) tileEntity;
|
||||
|
||||
if (FluidUtility.playerActivatedFluidItem(world, x, y, z, player, side))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
return interactCurrentItem(tile, 0, player);
|
||||
}
|
||||
|
||||
|
@ -83,6 +90,9 @@ public class BlockFirebox extends BlockTile
|
|||
@Override
|
||||
public Icon getBlockTexture(IBlockAccess access, int x, int y, int z, int side)
|
||||
{
|
||||
if (side == 0)
|
||||
return blockIcon;
|
||||
|
||||
boolean isElectric = access.getBlockMetadata(x, y, z) == 1;
|
||||
boolean isBurning = false;
|
||||
TileEntity tile = access.getBlockTileEntity(x, y, z);
|
||||
|
@ -104,6 +114,9 @@ public class BlockFirebox extends BlockTile
|
|||
@SideOnly(Side.CLIENT)
|
||||
public Icon getIcon(int side, int meta)
|
||||
{
|
||||
if (side == 0)
|
||||
return blockIcon;
|
||||
|
||||
boolean isElectric = meta == 1;
|
||||
boolean isBurning = false;
|
||||
|
||||
|
|
|
@ -270,7 +270,7 @@ public class TileFirebox extends TileElectricalInventory implements IPacketRecei
|
|||
@Override
|
||||
public FluidStack drain(ForgeDirection from, FluidStack resource, boolean doDrain)
|
||||
{
|
||||
if (resource == null || !resource.isFluidEqual(tank.getFluid()))
|
||||
if (resource == null || resource.getFluid() == FluidRegistry.LAVA)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
|
|
@ -26,7 +26,6 @@ import codechicken.multipart.TMultiPart;
|
|||
*/
|
||||
public abstract class PartMechanical extends JCuboidPart implements JNormalOcclusion, TFacePart, IMechanical
|
||||
{
|
||||
|
||||
private IMechanicalNetwork network;
|
||||
|
||||
/** The mechanical connections this connector has made */
|
||||
|
|
|
@ -198,7 +198,7 @@ public class PartPipe extends PartFramedConnection<EnumPipeMaterial, IFluidPipe,
|
|||
@Override
|
||||
protected boolean canConnectTo(TileEntity tile, ForgeDirection dir)
|
||||
{
|
||||
return tile instanceof IFluidHandler && (((IFluidHandler) tile).canFill(dir.getOpposite(), null) || ((IFluidHandler) tile).canDrain(dir.getOpposite(), null));
|
||||
return tile instanceof IFluidHandler;// && (((IFluidHandler) tile).canFill(dir.getOpposite(), null) || ((IFluidHandler) tile).canDrain(dir.getOpposite(), null));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -14,7 +14,7 @@ import calclavia.lib.prefab.tile.IRotatable;
|
|||
|
||||
public class TilePump extends TileMechanical implements IFluidHandler, IRotatable, IPressure
|
||||
{
|
||||
private final long maximumPower = 10000;
|
||||
private final long maximumPower = 100000;
|
||||
|
||||
@Override
|
||||
public void updateEntity()
|
||||
|
|
Loading…
Add table
Reference in a new issue