1 package pcc.chemicraft.base;
3 import java.util.Iterator;
5 import net.minecraft.block.Block;
6 import net.minecraft.item.Item;
7 import net.minecraft.item.ItemStack;
8 import net.minecraftforge.oredict.OreDictionary;
9 import pcc.chemicraft.ChemiCraftData;
10 import pcc.chemicraft.core.ChemiCraftAPI;
11 import pcc.chemicraft.core.ChemiCraftCore;
12 import pcc.chemicraft.core.nbt.NBTRecipeGrenade;
13 import pcc.chemicraft.util.Formula;
17 * @author mozipi,ponkotate
19 public class ChemiCraftRegisterBaseRecipe extends ChemiCraftBaseRegister {
21 public ChemiCraftRegisterBaseRecipe(ChemiCraftBase mod) {
28 this.mod.api.addChemicalCombinationRecipe(
29 new ItemStack(ChemiCraftCore.instance.itemCompounds, 1, this.mod.api.getCompound("SodiumChloride")),
32 this.mod.api.addChemicalCombinationRecipe(
33 new ItemStack(ChemiCraftCore.instance.itemCompounds, 1, this.mod.api.getCompound("ChlorousAcid")),
34 new Formula("HO2Cl"));
37 this.mod.api.addChemicalCombinationRecipe(new ItemStack(Item.diamond),
38 new Formula("C64Si16"));
40 this.mod.api.addChemicalCombinationRecipe(new ItemStack(Item.sugar),
41 new Formula("C12H22O11"));
43 this.mod.api.addElectrolysisDecompositionRecipe(new ItemStack(Item.bucketWater),
46 this.mod.api.addElectrolysisDecompositionRecipe(new ItemStack(Item.potion, 1, 0),
49 this.mod.api.addPyrolysisDecompositionRecipe(new ItemStack(Block.oreCoal),
52 this.mod.api.addPyrolysisDecompositionRecipe(new ItemStack(Item.coal),
55 this.mod.api.addReversibleOfElectrolysis(new ItemStack(Block.wood),
56 new Formula("C6H10O5"));
58 this.mod.api.addReversibleOfPyrolysis(new ItemStack(Block.dirt),
59 new Formula("SiI2O2"));
61 this.mod.api.addReversibleOfPyrolysis(new ItemStack(Block.glass),
62 new Formula("SiCO2"));
64 this.mod.api.addReversibleOfPyrolysis(new ItemStack(Block.stone),
67 this.mod.api.addReversibleOfPyrolysis(new ItemStack(Block.tnt),
68 new Formula("C7H5N3O6"));
70 this.mod.api.addReversibleOfPyrolysis(new ItemStack(Item.emerald),
71 new Formula("Be3Al2Si6O18"));
75 //RP2-------------------------------------------------------------------------------------------------------------
76 this.mod.api.addPyrolysisDecompositionRecipe(
77 OreDictionary.getOres("oreCopper"), new Formula("Cu"));
78 //------------------------------------------------------------------------------------------------------------------
81 this.mod.api.addMaterialRecipe(
83 null, new ItemStack(Block.stone), null,
84 new ItemStack(Block.stone), new ItemStack(Item.gunpowder), new ItemStack(Block.stone),
85 null, new ItemStack(Block.stone), null
87 new ItemStack(this.mod.itemAtomGrenade, 16, 0),
88 new NBTRecipeGrenade());
90 this.mod.api.addSharplessMaterialRecipe(
92 new ItemStack(this.mod.itemAtomGrenade, 1, 0),
94 new ItemStack(this.mod.itemAtomGrenade, 1, 0),
95 new NBTRecipeGrenade()
98 ChemiCraftAPI.addMaterialRecipe(
100 new ItemStack(Block.stone), new ItemStack(Item.ingotIron), new ItemStack(Block.stone),
101 new ItemStack(Item.ingotIron), new ItemStack(ChemiCraftCore.instance.itemAtoms, 1, ChemiCraftData.URANIUM), new ItemStack(Item.ingotIron),
102 new ItemStack(Block.stone), new ItemStack(Item.redstone), new ItemStack(Block.stone)
104 new ItemStack(this.mod.itemRadiationBallet),
107 ChemiCraftAPI.addMaterialRecipe(
109 new ItemStack(Block.stone), new ItemStack(ChemiCraftCore.instance.itemAtoms, 1, ChemiCraftData.URANIUM), new ItemStack(Block.stone),
110 new ItemStack(Item.ingotIron), new ItemStack(Item.redstone), new ItemStack(Item.ingotIron),
111 new ItemStack(Block.stone), new ItemStack(Item.redstone), new ItemStack(Block.stone)
113 new ItemStack(this.mod.itemRaditionGunDataChip),
116 ChemiCraftAPI.addMaterialRecipe(
118 new ItemStack(Block.blockSteel), new ItemStack(Block.blockSteel), new ItemStack(this.mod.itemRaditionGunDataChip),
119 null, null, new ItemStack(Block.stone),
120 null, null, new ItemStack(Item.stick)
122 new ItemStack(this.mod.itemRadiationGun),
126 this.mod.api.addElectrolysisDecompositionRecipe(
127 new ItemStack(ChemiCraftCore.instance.itemCompounds, 1, this.mod.api.getCompound("Water")),
131 Iterator<String> arrayOreNames = this.mod.apiBase.getAtomOresFormulas().keySet().iterator();
132 while (arrayOreNames.hasNext()) {
133 String name = arrayOreNames.next();
136 itemstack = OreDictionary.getOres(name).get(0);
137 } catch (IndexOutOfBoundsException e) {
138 int var1 = this.mod.apiBase.getAtomOresAtomName().indexOf(name);
139 itemstack = new ItemStack(this.mod.blockAtomOres[var1 / 16], 1, var1 % 16);
141 this.mod.api.addPyrolysisDecompositionRecipe(
143 this.mod.apiBase.getAtomOresFormulas().get(name));