Added Sandstone pipe and waterproof pipe
This commit is contained in:
parent
343f2b277b
commit
abe7ef1b6a
8 changed files with 99 additions and 1 deletions
|
@ -56,6 +56,8 @@ public class mod_BuildCraftTransport extends NetworkMod implements IItemRenderer
|
|||
MinecraftForgeClient.registerItemRenderer(BuildCraftTransport.pipeItemsStipes.shiftedIndex, this);
|
||||
MinecraftForgeClient.registerItemRenderer(BuildCraftTransport.pipeItemsVoid.shiftedIndex, this);
|
||||
MinecraftForgeClient.registerItemRenderer(BuildCraftTransport.pipeLiquidsVoid.shiftedIndex, this);
|
||||
MinecraftForgeClient.registerItemRenderer(BuildCraftTransport.pipeItemsSandstone.shiftedIndex, this);
|
||||
MinecraftForgeClient.registerItemRenderer(BuildCraftTransport.pipeLiquidsSandstone.shiftedIndex, this);
|
||||
}
|
||||
|
||||
public static void registerTilePipe(Class<? extends TileEntity> clas, String name) {
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 24 KiB After Width: | Height: | Size: 25 KiB |
|
@ -65,6 +65,8 @@ item.PipeItemsStripes=Stripes Transport Pipe
|
|||
item.PipeStructureCobblestone=Cobblestone Structure Pipe
|
||||
item.PipeItemsVoid=Void Transport Pipe
|
||||
item.PipeLiquidsVoid=Void Waterproof Pipe
|
||||
item.PipeItemsSandstone=Sandstone Transport Pipe
|
||||
item.PipeLiquidsSandstone=Sandstone Waterproof Pipe
|
||||
tile.miningWellBlock=Mining Well
|
||||
tile.plainPipeBlock=Mining Pipe
|
||||
tile.autoWorkbenchBlock=Autocrafting Table
|
||||
|
|
|
@ -42,6 +42,7 @@ import net.minecraft.src.buildcraft.transport.pipes.PipeItemsDiamond;
|
|||
import net.minecraft.src.buildcraft.transport.pipes.PipeItemsGold;
|
||||
import net.minecraft.src.buildcraft.transport.pipes.PipeItemsIron;
|
||||
import net.minecraft.src.buildcraft.transport.pipes.PipeItemsObsidian;
|
||||
import net.minecraft.src.buildcraft.transport.pipes.PipeItemsSandstone;
|
||||
import net.minecraft.src.buildcraft.transport.pipes.PipeItemsStone;
|
||||
import net.minecraft.src.buildcraft.transport.pipes.PipeItemsStripes;
|
||||
import net.minecraft.src.buildcraft.transport.pipes.PipeItemsVoid;
|
||||
|
@ -49,6 +50,7 @@ import net.minecraft.src.buildcraft.transport.pipes.PipeItemsWood;
|
|||
import net.minecraft.src.buildcraft.transport.pipes.PipeLiquidsCobblestone;
|
||||
import net.minecraft.src.buildcraft.transport.pipes.PipeLiquidsGold;
|
||||
import net.minecraft.src.buildcraft.transport.pipes.PipeLiquidsIron;
|
||||
import net.minecraft.src.buildcraft.transport.pipes.PipeLiquidsSandstone;
|
||||
import net.minecraft.src.buildcraft.transport.pipes.PipeLiquidsStone;
|
||||
import net.minecraft.src.buildcraft.transport.pipes.PipeLiquidsVoid;
|
||||
import net.minecraft.src.buildcraft.transport.pipes.PipeLiquidsWood;
|
||||
|
@ -87,6 +89,7 @@ public class BuildCraftTransport {
|
|||
public static Item pipeItemsDiamond;
|
||||
public static Item pipeItemsObsidian;
|
||||
public static Item pipeItemsVoid;
|
||||
public static Item pipeItemsSandstone;
|
||||
|
||||
public static Item pipeLiquidsWood;
|
||||
public static Item pipeLiquidsCobblestone;
|
||||
|
@ -94,6 +97,7 @@ public class BuildCraftTransport {
|
|||
public static Item pipeLiquidsIron;
|
||||
public static Item pipeLiquidsGold;
|
||||
public static Item pipeLiquidsVoid;
|
||||
public static Item pipeLiquidsSandstone;
|
||||
|
||||
public static Item pipePowerWood;
|
||||
public static Item pipePowerStone;
|
||||
|
@ -250,6 +254,11 @@ public class BuildCraftTransport {
|
|||
pipeLiquidsVoid = createPipe(DefaultProps.PIPE_LIQUIDS_VOID_ID, PipeLiquidsVoid.class, "Void Waterproof Pipe",
|
||||
pipeWaterproof, pipeItemsVoid, null);
|
||||
|
||||
pipeItemsSandstone = createPipe(DefaultProps.PIPE_ITEMS_SANDSTONE_ID, PipeItemsSandstone.class, "Sandstone Transport Pipe",
|
||||
Block.sandStone, Block.glass, Block.sandStone);
|
||||
|
||||
pipeLiquidsSandstone = createPipe(DefaultProps.PIPE_LIQUIDS_SANDSTONE_ID, PipeLiquidsSandstone.class, "Sandstone Waterproof Pipe",
|
||||
pipeWaterproof, pipeItemsSandstone, null);
|
||||
|
||||
// dockingStationBlock = new
|
||||
// BlockDockingStation(Integer.parseInt(dockingStationId.value));
|
||||
|
|
|
@ -77,6 +77,8 @@ public class DefaultProps {
|
|||
public static int PIPE_STRUCTURE_COBBLESTONE_ID = 4072;
|
||||
public static int PIPE_ITEMS_VOID_ID = 19150;
|
||||
public static int PIPE_LIQUIDS_VOID_ID = 19151;
|
||||
public static int PIPE_ITEMS_SANDSTONE_ID = 19152;
|
||||
public static int PIPE_LIQUIDS_SANDSTONE_ID = 19153;
|
||||
|
||||
public static int WOODEN_PIPE_ID = 145; // LEGACY
|
||||
public static int STONE_PIPE_ID = 146; // LEGACY
|
||||
|
|
|
@ -0,0 +1,21 @@
|
|||
/**
|
||||
* Copyright (c) SpaceToad, 2011
|
||||
* http://www.mod-buildcraft.com
|
||||
*
|
||||
* BuildCraft is distributed under the terms of the Minecraft Mod Public
|
||||
* License 1.0, or MMPL. Please check the contents of the license located in
|
||||
* http://www.mod-buildcraft.com/MMPL-1.0.txt
|
||||
*/
|
||||
|
||||
package net.minecraft.src.buildcraft.transport;
|
||||
|
||||
import net.minecraft.src.TileEntity;
|
||||
import net.minecraft.src.buildcraft.transport.PipeLogic;
|
||||
import net.minecraft.src.buildcraft.transport.TileGenericPipe;
|
||||
|
||||
public class PipeLogicSandstone extends PipeLogic{
|
||||
@Override
|
||||
public boolean isPipeConnected(TileEntity tile) {
|
||||
return (tile instanceof TileGenericPipe);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,26 @@
|
|||
/**
|
||||
* Copyright (c) SpaceToad, 2011
|
||||
* http://www.mod-buildcraft.com
|
||||
*
|
||||
* BuildCraft is distributed under the terms of the Minecraft Mod Public
|
||||
* License 1.0, or MMPL. Please check the contents of the license located in
|
||||
* http://www.mod-buildcraft.com/MMPL-1.0.txt
|
||||
*/
|
||||
|
||||
package net.minecraft.src.buildcraft.transport.pipes;
|
||||
|
||||
import net.minecraft.src.buildcraft.transport.Pipe;
|
||||
import net.minecraft.src.buildcraft.transport.PipeLogicSandstone;
|
||||
import net.minecraft.src.buildcraft.transport.PipeTransportItems;
|
||||
|
||||
public class PipeItemsSandstone extends Pipe{
|
||||
public PipeItemsSandstone(int itemID) {
|
||||
super(new PipeTransportItems(), new PipeLogicSandstone(), itemID);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getMainBlockTexture() {
|
||||
return 8 * 16 + 15;
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,36 @@
|
|||
/**
|
||||
* Copyright (c) SpaceToad, 2011
|
||||
* http://www.mod-buildcraft.com
|
||||
*
|
||||
* BuildCraft is distributed under the terms of the Minecraft Mod Public
|
||||
* License 1.0, or MMPL. Please check the contents of the license located in
|
||||
* http://www.mod-buildcraft.com/MMPL-1.0.txt
|
||||
*/
|
||||
|
||||
package net.minecraft.src.buildcraft.transport.pipes;
|
||||
|
||||
import net.minecraft.src.buildcraft.api.Orientations;
|
||||
import net.minecraft.src.buildcraft.transport.IPipeTransportLiquidsHook;
|
||||
import net.minecraft.src.buildcraft.transport.Pipe;
|
||||
import net.minecraft.src.buildcraft.transport.PipeLogicSandstone;
|
||||
import net.minecraft.src.buildcraft.transport.PipeTransportLiquids;
|
||||
import net.minecraft.src.buildcraft.transport.TileGenericPipe;
|
||||
|
||||
public class PipeLiquidsSandstone extends Pipe implements IPipeTransportLiquidsHook{
|
||||
public PipeLiquidsSandstone(int itemID) {
|
||||
super(new PipeTransportLiquids(), new PipeLogicSandstone(), itemID);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getMainBlockTexture() {
|
||||
return 9 * 16 + 15;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int fill(Orientations from, int quantity, int id, boolean doFill) {
|
||||
if (!(container.tileBuffer[from.ordinal()].getTile() instanceof TileGenericPipe))
|
||||
return 0;
|
||||
|
||||
return ((PipeTransportLiquids)this.transport).side[from.ordinal()].fill(quantity, doFill, (short) id);
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue