Fixes #130
This commit is contained in:
parent
111c5e6d5c
commit
3f4b59faaf
5 changed files with 77 additions and 3 deletions
|
@ -1164,6 +1164,14 @@ public class RecipesIC2 implements ICompatModule {
|
|||
40, 60
|
||||
));
|
||||
}
|
||||
|
||||
CraftingHelper.addShapedOreRecipe(ItemParts.getPartByName("NaKCoolantSimple"),
|
||||
"TST", "PCP", "TST",
|
||||
'T', "ingotTin",
|
||||
'S', ItemCells.getCellByName("sodium"),
|
||||
'P', ItemCells.getCellByName("potassium"),
|
||||
'C', IC2Items.getItem("reactorCoolantSimple")
|
||||
);
|
||||
}
|
||||
|
||||
static void removeIc2Recipes() {
|
||||
|
|
|
@ -38,10 +38,12 @@ import techreborn.items.ItemRods;
|
|||
import techreborn.util.CraftingHelper;
|
||||
import techreborn.util.LogHelper;
|
||||
import techreborn.util.OreUtil;
|
||||
import techreborn.util.RecipeUtils;
|
||||
|
||||
import java.security.InvalidParameterException;
|
||||
|
||||
public class ModRecipes {
|
||||
public class
|
||||
ModRecipes {
|
||||
public static ConfigTechReborn config;
|
||||
|
||||
public static void init() {
|
||||
|
@ -192,6 +194,40 @@ public class ModRecipes {
|
|||
'A', "ingotAluminum"
|
||||
);
|
||||
|
||||
CraftingHelper.addShapedOreRecipe(ItemParts.getPartByName("heliumCoolantSimple"),
|
||||
" T ", "TCT", " T ",
|
||||
'T', "ingotTin",
|
||||
'C', ItemCells.getCellByName("helium", 1, false)
|
||||
);
|
||||
|
||||
CraftingHelper.addShapedOreRecipe(ItemParts.getPartByName("HeliumCoolantTriple"),
|
||||
"TTT", "CCC", "TTT",
|
||||
'T', "ingotTin",
|
||||
'C', ItemParts.getPartByName("heliumCoolantSimple")
|
||||
);
|
||||
|
||||
CraftingHelper.addShapedOreRecipe(ItemParts.getPartByName("HeliumCoolantSix"),
|
||||
"THT", "TCT", "THT",
|
||||
'T', "ingotTin",
|
||||
'C', "ingotCopper",
|
||||
'H', ItemParts.getPartByName("HeliumCoolantTriple")
|
||||
);
|
||||
|
||||
CraftingHelper.addShapedOreRecipe(ItemParts.getPartByName("NaKCoolantTriple"),
|
||||
"TTT", "CCC", "TTT",
|
||||
'T', "ingotTin",
|
||||
'C', ItemParts.getPartByName("NaKCoolantSimple")
|
||||
);
|
||||
|
||||
CraftingHelper.addShapedOreRecipe(ItemParts.getPartByName("NaKCoolantSix"),
|
||||
"THT", "TCT", "THT",
|
||||
'T', "ingotTin",
|
||||
'C', "ingotCopper",
|
||||
'H', ItemParts.getPartByName("NaKCoolantTriple")
|
||||
);
|
||||
|
||||
GameRegistry.addShapelessRecipe(ItemCells.getCellByName("heliumPlasma"), ItemCells.getCellByName("tritium"), ItemCells.getCellByName("deuterium"));
|
||||
|
||||
LogHelper.info("Shapped Recipes Added");
|
||||
}
|
||||
|
||||
|
@ -996,6 +1032,9 @@ public class ModRecipes {
|
|||
RecipeHandler.addRecipe(new CentrifugeRecipe(ItemDusts.getDustByName("tetrahedrite", 8), null, ItemDusts.getDustByName("copper", 3), ItemDusts.getDustByName("antimony", 1), ItemDusts.getDustByName("sulfur", 3), ItemDusts.getDustByName("iron", 1), 3640, 5));
|
||||
RecipeHandler.addRecipe(new CentrifugeRecipe(ItemDusts.getDustByName("lapis", 16), null, ItemDusts.getDustByName("lazurite", 12), ItemDusts.getDustByName("sodalite", 2), ItemDusts.getDustByName("pyrite", 7), ItemDusts.getDustByName("calcite", 1), 3580, 5));
|
||||
|
||||
|
||||
RecipeHandler.addRecipe(new CentrifugeRecipe(new ItemStack(Items.glowstone_dust, 16), RecipeUtils.getEmptyCell(1), ItemCells.getCellByName("helium", 1, false), ItemDusts.getDustByName("gold", 8), new ItemStack(Items.redstone), null, 25000, 20));
|
||||
RecipeHandler.addRecipe(new CentrifugeRecipe(ItemDusts.getDustByName("endstone", 16), RecipeUtils.getEmptyCell(2), ItemCells.getCellByName("helium3", 1, false), ItemCells.getCellByName("helium", 1, false), ItemDustsTiny.getTinyDustByName("Tungsten"), new ItemStack(Blocks.sand, 12), 4800, 5));
|
||||
}
|
||||
|
||||
static void addIndustrialGrinderRecipes() {
|
||||
|
@ -1509,4 +1548,7 @@ public class ModRecipes {
|
|||
FarmTree.harvestableLogs.add(Blocks.log);
|
||||
FarmTree.harvestableLogs.add(Blocks.log2);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -19,8 +19,13 @@ import java.util.List;
|
|||
public class ItemCells extends ItemTR {
|
||||
|
||||
public static ItemStack getCellByName(String name, int count) {
|
||||
return getCellByName(name, count, true);
|
||||
}
|
||||
|
||||
|
||||
public static ItemStack getCellByName(String name, int count, boolean lookForIC2) {
|
||||
Fluid fluid = FluidRegistry.getFluid("fluid" + name.toLowerCase());
|
||||
if (IC2Items.getItem("FluidCell") != null) {
|
||||
if (lookForIC2 && IC2Items.getItem("FluidCell") != null) {
|
||||
if (fluid != null) {
|
||||
ItemStack stack = IC2Items.getItem("FluidCell").copy();
|
||||
if (stack != null && stack.getItem() instanceof IFluidContainerItem) {
|
||||
|
@ -54,7 +59,7 @@ public class ItemCells extends ItemTR {
|
|||
"mercury", "methane", "nitrocarbon", "nitroCoalfuel",
|
||||
"nitroDiesel", "nitrogen", "nitrogenDioxide", "oil", "potassium",
|
||||
"seedOil", "silicon", "sodium", "sodiumPersulfate",
|
||||
"sodiumSulfide", "sulfur", "sulfuricAcid", "tritium", "wolframium",};
|
||||
"sodiumSulfide", "sulfur", "sulfuricAcid", "tritium", "wolframium", "empty"};
|
||||
|
||||
private IIcon[] textures;
|
||||
|
||||
|
|
19
src/main/java/techreborn/util/RecipeUtils.java
Normal file
19
src/main/java/techreborn/util/RecipeUtils.java
Normal file
|
@ -0,0 +1,19 @@
|
|||
package techreborn.util;
|
||||
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import ic2.api.item.IC2Items;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import techreborn.items.ItemCells;
|
||||
|
||||
|
||||
public class RecipeUtils {
|
||||
public static ItemStack getEmptyCell(int stackSize){
|
||||
if(Loader.isModLoaded("IC2")){
|
||||
ItemStack cell = IC2Items.getItem("cell").copy();
|
||||
cell.stackSize = stackSize;
|
||||
return cell;
|
||||
} else {
|
||||
return ItemCells.getCellByName("empty", stackSize);
|
||||
}
|
||||
}
|
||||
}
|
Binary file not shown.
After Width: | Height: | Size: 486 B |
Loading…
Reference in a new issue