Add Flood Gate Texture

Provided by laz2727, many thanks!
This commit is contained in:
CovertJaguar 2013-07-24 05:16:50 -07:00
parent 2bd4e6ef84
commit f457df7ced
5 changed files with 15 additions and 15 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 513 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 270 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 505 B

View file

@ -91,8 +91,8 @@ public class BlockFloodGate extends BlockContainer {
@Override
@SideOnly(Side.CLIENT)
public void registerIcons(IconRegister par1IconRegister) {
textureTop = par1IconRegister.registerIcon("buildcraft:pump_top");
textureBottom = par1IconRegister.registerIcon("buildcraft:pump_bottom");
textureSide = par1IconRegister.registerIcon("buildcraft:pump_side");
textureTop = par1IconRegister.registerIcon("buildcraft:floodgate_top");
textureBottom = par1IconRegister.registerIcon("buildcraft:floodgate_bottom");
textureSide = par1IconRegister.registerIcon("buildcraft:floodgate_side");
}
}

View file

@ -30,7 +30,7 @@ import net.minecraftforge.fluids.IFluidHandler;
public class TileFloodGate extends TileBuildCraft implements IFluidHandler {
public static final int[] REBUID_DELAY = new int[8];
public static final int[] REBUILD_DELAY = new int[8];
public static final int MAX_LIQUID = FluidContainerRegistry.BUCKET_VOLUME * 2;
private final TreeMap<Integer, Deque<BlockIndex>> pumpLayerQueues = new TreeMap<Integer, Deque<BlockIndex>>();
private final Set<BlockIndex> visitedBlocks = new HashSet<BlockIndex>();
@ -40,14 +40,14 @@ public class TileFloodGate extends TileBuildCraft implements IFluidHandler {
private int tick = Utils.RANDOM.nextInt();
static {
REBUID_DELAY[0] = 128;
REBUID_DELAY[1] = 256;
REBUID_DELAY[2] = 512;
REBUID_DELAY[3] = 1024;
REBUID_DELAY[4] = 2048;
REBUID_DELAY[5] = 4096;
REBUID_DELAY[6] = 8192;
REBUID_DELAY[7] = 16384;
REBUILD_DELAY[0] = 128;
REBUILD_DELAY[1] = 256;
REBUILD_DELAY[2] = 512;
REBUILD_DELAY[3] = 1024;
REBUILD_DELAY[4] = 2048;
REBUILD_DELAY[5] = 4096;
REBUILD_DELAY[6] = 8192;
REBUILD_DELAY[7] = 16384;
}
public TileFloodGate() {
@ -65,10 +65,10 @@ public class TileFloodGate extends TileBuildCraft implements IFluidHandler {
if (tick % 16 == 0) {
FluidStack fluidtoFill = tank.drain(FluidContainerRegistry.BUCKET_VOLUME, false);
if (fluidtoFill != null && fluidtoFill.amount == FluidContainerRegistry.BUCKET_VOLUME && fluidtoFill.getFluid() != null) {
if (tick % REBUID_DELAY[rebuildDelay] == 0) {
if (tick % REBUILD_DELAY[rebuildDelay] == 0) {
rebuildDelay++;
if (rebuildDelay >= REBUID_DELAY.length)
rebuildDelay = REBUID_DELAY.length - 1;
if (rebuildDelay >= REBUILD_DELAY.length)
rebuildDelay = REBUILD_DELAY.length - 1;
rebuildQueue();
}
BlockIndex index = getNextIndexToFill(true);