From 4e2e84990a3c7973fd78f46ca5dd1bb73698acab Mon Sep 17 00:00:00 2001 From: Arona Jones Date: Sun, 1 Feb 2015 15:53:48 +0000 Subject: [PATCH] Add additional pipe sealant recipe using slimeballs --- common/buildcraft/BuildCraftTransport.java | 31 +++++++++++----------- 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/common/buildcraft/BuildCraftTransport.java b/common/buildcraft/BuildCraftTransport.java index 827e8758..6b8f5028 100644 --- a/common/buildcraft/BuildCraftTransport.java +++ b/common/buildcraft/BuildCraftTransport.java @@ -213,7 +213,7 @@ public class BuildCraftTransport extends BuildCraftMod { public static Item pipePowerDiamond; public static Item pipePowerEmerald; public static Item pipePowerSandstone; - + public static int groupItemsTrigger; public static String[] facadeBlacklist; @@ -238,7 +238,7 @@ public class BuildCraftTransport extends BuildCraftMod { public static boolean debugPrintFacadeList = false; public static float gateCostMultiplier = 1.0F; - + private static LinkedList pipeRecipes = new LinkedList(); public IIconProvider pipeIconProvider = new PipeIconProvider(); @@ -388,7 +388,7 @@ public class BuildCraftTransport extends BuildCraftMod { gateCopier = new ItemGateCopier(); CoreProxy.proxy.registerItem(gateCopier); - + for (PipeContents kind : PipeContents.values()) { triggerPipe[kind.ordinal()] = new TriggerPipeContents(kind); } @@ -452,7 +452,7 @@ public class BuildCraftTransport extends BuildCraftMod { StatementManager.registerParameterClass(ActionParameterSignal.class); StatementManager.registerTriggerProvider(new PipeTriggerProvider()); StatementManager.registerActionProvider(new PipeActionProvider()); - + PipeManager.registerStripesHandler(new StripesHandlerRightClick()); PipeManager.registerStripesHandler(new StripesHandlerBucket()); PipeManager.registerStripesHandler(new StripesHandlerArrow()); @@ -463,7 +463,7 @@ public class BuildCraftTransport extends BuildCraftMod { PipeManager.registerPipePluggable(LensPluggable.class, "lens"); PipeManager.registerPipePluggable(PlugPluggable.class, "plug"); PipeManager.registerPipePluggable(RobotStationPluggable.class, "robotStation"); - + if (BuildCraftCore.loadDefaultRecipes) { loadRecipes(); } @@ -475,7 +475,7 @@ public class BuildCraftTransport extends BuildCraftMod { @Mod.EventHandler public void postInit(FMLPostInitializationEvent evt) { facadeItem.initialize(); - + if (debugPrintFacadeList) { try { PrintWriter writer = new PrintWriter("FacadeDebug.txt", "UTF-8"); @@ -495,6 +495,7 @@ public class BuildCraftTransport extends BuildCraftMod { public void loadRecipes() { // Add base recipe for pipe waterproof. GameRegistry.addShapelessRecipe(new ItemStack(pipeWaterproof, 1), new ItemStack(Items.dye, 1, 2)); + GameRegistry.addShapelessRecipe(new ItemStack(pipeWaterproof, 1), new ItemStack(Items.slime_ball, 1, 2)); // Add pipe recipes for (PipeRecipe pipe : pipeRecipes) { @@ -506,7 +507,7 @@ public class BuildCraftTransport extends BuildCraftMod { } GameRegistry.addRecipe(new PipeColoringRecipe()); - + CoreProxy.proxy.addCraftingRecipe(new ItemStack(filteredBufferBlock, 1), "wdw", "wcw", "wpw", 'w', "plankWood", 'd', BuildCraftTransport.pipeItemsDiamond, 'c', Blocks.chest, 'p', @@ -525,7 +526,7 @@ public class BuildCraftTransport extends BuildCraftMod { if (Loader.isModLoaded("BuildCraft|Silicon")) { GameRegistry.addShapelessRecipe(new ItemStack(gateCopier, 1), new ItemStack(BuildCraftCore.wrenchItem), Chipset.RED.getStack(1)); - + // PIPE WIRE BuildcraftRecipeRegistry.assemblyTable.addRecipe("buildcraft:redWire", 5000, PipeWire.RED.getStack(8), "dyeRed", "dustRedstone", "ingotIron"); @@ -586,7 +587,7 @@ public class BuildCraftTransport extends BuildCraftMod { BuildcraftRecipeRegistry.assemblyTable.addRecipe("buildcraft:orGate" + materialName, energyCost, ItemGate.makeGateItem(material, GateLogic.OR), inputs); } - + @Mod.EventHandler public void processIMCRequests(IMCEvent event) { InterModComms.processIMC(event); @@ -597,19 +598,19 @@ public class BuildCraftTransport extends BuildCraftMod { Object... ingredients) { ItemPipe res = BlockGenericPipe.registerPipe(clas, creativeTab); res.setUnlocalizedName(clas.getSimpleName()); - + // Add appropriate recipes to temporary list if (ingredients.length == 3) { for (int i = 0; i < 17; i++) { PipeRecipe recipe = new PipeRecipe(); ItemStack glass; - + if (i == 0) { glass = new ItemStack(Blocks.glass); } else { glass = new ItemStack(Blocks.stained_glass, 1, i - 1); } - + recipe.result = new ItemStack(res, 8, i); recipe.input = new Object[]{"ABC", 'A', ingredients[0], 'B', glass, 'C', ingredients[2]}; @@ -618,20 +619,20 @@ public class BuildCraftTransport extends BuildCraftMod { } else if (ingredients.length == 2) { for (int i = 0; i < 17; i++) { PipeRecipe recipe = new PipeRecipe(); - + Object left = ingredients[0]; Object right = ingredients[1]; if (ingredients[1] instanceof ItemPipe) { right = new ItemStack((Item) right, 1, i); } - + recipe.isShapeless = true; recipe.result = new ItemStack(res, 1, i); recipe.input = new Object[]{left, right}; pipeRecipes.add(recipe); - + if (ingredients[1] instanceof ItemPipe) { PipeRecipe uncraft = new PipeRecipe(); uncraft.isShapeless = true;