Search in sources :

Example 1 with SynthesisRecipe

use of minechem.tileentity.synthesis.SynthesisRecipe in project Minechem by iopleke.

the class MinechemRecipes method RegisterModRecipes.

public void RegisterModRecipes() {
    // OreDict stuff
    DecomposerRecipe.createAndAddRecipeSafely("dustSalt", new Element(ElementEnum.Na), new Element(ElementEnum.Cl));
    DecomposerRecipe.createAndAddRecipeSafely("logWood", new Molecule(MoleculeEnum.cellulose, 8));
    DecomposerRecipe.createAndAddRecipeSafely("plankWood", new Molecule(MoleculeEnum.cellulose, 2));
    DecomposerRecipe.createAndAddRecipeSafely("ingotIron", this.element(ElementEnum.Fe, 16));
    DecomposerRecipe.createAndAddRecipeSafely("ingotGold", this.element(ElementEnum.Au, 16));
    DecomposerRecipe.createAndAddRecipeSafely("ingotCopper", this.element(ElementEnum.Cu, 16));
    DecomposerRecipe.createAndAddRecipeSafely("ingotTin", this.element(ElementEnum.Sn, 16));
    DecomposerRecipe.createAndAddRecipeSafely("ingotSilver", this.element(ElementEnum.Ag, 16));
    DecomposerRecipe.createAndAddRecipeSafely("ingotLead", this.element(ElementEnum.Pb, 16));
    DecomposerRecipe.createAndAddRecipeSafely("ingotPlatinum", this.element(ElementEnum.Pt, 16));
    DecomposerRecipe.createAndAddRecipeSafely("ingotAluminium", this.element(ElementEnum.Al, 16));
    DecomposerRecipe.createAndAddRecipeSafely("ingotMagnesium", this.element(ElementEnum.Mg, 16));
    DecomposerRecipe.createAndAddRecipeSafely("ingotSteel", new PotionChemical[] { this.element(ElementEnum.Fe, 15), this.element(ElementEnum.C, 1) });
    DecomposerRecipe.createAndAddRecipeSafely("ingotHSLA", new PotionChemical[] { this.element(ElementEnum.Fe, 15), this.element(ElementEnum.C, 1) });
    DecomposerRecipe.createAndAddRecipeSafely("ingotBronze", new PotionChemical[] { this.element(ElementEnum.Cu, 12), this.element(ElementEnum.Sn, 4) });
    DecomposerRecipe.createAndAddRecipeSafely("ingotElectrum", new PotionChemical[] { this.element(ElementEnum.Ag, 8), this.element(ElementEnum.Au, 8) });
    DecomposerRecipe.createAndAddRecipeSafely("ingotInvar", new PotionChemical[] { this.element(ElementEnum.Fe, 10), this.element(ElementEnum.Ni, 6) });
    SynthesisRecipe.createAndAddRecipeSafely("ingotIron", false, COST_INGOT, this.element(ElementEnum.Fe, 16));
    SynthesisRecipe.createAndAddRecipeSafely("ingotGold", false, COST_INGOT, this.element(ElementEnum.Au, 16));
    SynthesisRecipe.createAndAddRecipeSafely("ingotCopper", false, COST_INGOT, this.element(ElementEnum.Cu, 16));
    SynthesisRecipe.createAndAddRecipeSafely("ingotTin", false, COST_INGOT, this.element(ElementEnum.Sn, 16));
    SynthesisRecipe.createAndAddRecipeSafely("ingotSilver", false, COST_INGOT, this.element(ElementEnum.Ag, 16));
    SynthesisRecipe.createAndAddRecipeSafely("ingotLead", false, COST_INGOT, this.element(ElementEnum.Pb, 16));
    SynthesisRecipe.createAndAddRecipeSafely("ingotPlatinum", false, COST_INGOT, this.element(ElementEnum.Pt, 16));
    SynthesisRecipe.createAndAddRecipeSafely("ingotAluminium", false, COST_INGOT, this.element(ElementEnum.Al, 16));
    SynthesisRecipe.createAndAddRecipeSafely("ingotMagnesium", false, COST_INGOT, this.element(ElementEnum.Mg, 16));
    SynthesisRecipe.createAndAddRecipeSafely("ingotSteel", false, COST_INGOT, new PotionChemical[] { this.element(ElementEnum.Fe, 15), this.element(ElementEnum.C, 1) });
    SynthesisRecipe.createAndAddRecipeSafely("ingotHSLA", false, COST_INGOT, new PotionChemical[] { this.element(ElementEnum.Fe, 15), this.element(ElementEnum.C, 1) });
    SynthesisRecipe.createAndAddRecipeSafely("ingotBronze", false, COST_INGOT, new PotionChemical[] { this.element(ElementEnum.Cu, 12), this.element(ElementEnum.Sn, 4) });
    SynthesisRecipe.createAndAddRecipeSafely("ingotElectrum", false, COST_INGOT, new PotionChemical[] { this.element(ElementEnum.Ag, 8), this.element(ElementEnum.Au, 8) });
    SynthesisRecipe.createAndAddRecipeSafely("ingotInvar", false, COST_INGOT, new PotionChemical[] { this.element(ElementEnum.Fe, 10), this.element(ElementEnum.Ni, 6) });
    // Thermal Expansion
    if (Loader.isModLoaded("ThermalExpansion")) {
        Block rockwool = GameRegistry.findBlock("ThermalExpansion", "Rockwool");
        ItemStack blockRockWool = new ItemStack(rockwool, 1, 0);
        ItemStack blockRockOrangeWool = new ItemStack(rockwool, 1, 1);
        ItemStack blockRockMagentaWool = new ItemStack(rockwool, 1, 2);
        ItemStack blockRockLightBlueWool = new ItemStack(rockwool, 1, 3);
        ItemStack blockRockYellowWool = new ItemStack(rockwool, 1, 4);
        ItemStack blockRockLimeWool = new ItemStack(rockwool, 1, 5);
        ItemStack blockRockPinkWool = new ItemStack(rockwool, 1, 6);
        ItemStack blockRockGrayWool = new ItemStack(rockwool, 1, 7);
        ItemStack blockRockLightGrayWool = new ItemStack(rockwool, 1, 8);
        ItemStack blockRockCyanWool = new ItemStack(rockwool, 1, 9);
        ItemStack blockRockPurpleWool = new ItemStack(rockwool, 1, 10);
        ItemStack blockRockBlueWool = new ItemStack(rockwool, 1, 11);
        ItemStack blockRockBrownWool = new ItemStack(rockwool, 1, 12);
        ItemStack blockRockGreenWool = new ItemStack(rockwool, 1, 13);
        ItemStack blockRockRedWool = new ItemStack(rockwool, 1, 14);
        ItemStack blockRockBlackWool = new ItemStack(rockwool, 1, 15);
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.whitePigment) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockOrangeWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.orangePigment) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockMagentaWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.lightbluePigment), this.molecule(MoleculeEnum.redPigment) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockLightBlueWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.lightbluePigment) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockYellowWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.yellowPigment) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockLimeWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.limePigment) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockPinkWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.redPigment), this.molecule(MoleculeEnum.whitePigment) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockGrayWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.whitePigment), this.molecule(MoleculeEnum.blackPigment, 2) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockLightGrayWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.whitePigment), this.molecule(MoleculeEnum.blackPigment) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockCyanWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.lightbluePigment), this.molecule(MoleculeEnum.whitePigment) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockPurpleWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.purplePigment) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockBlueWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.lazurite) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockBrownWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.tannicacid) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockGreenWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.greenPigment) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockRedWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.redPigment) }));
        DecomposerRecipe.add(new DecomposerRecipeChance(blockRockBlackWool, 0.2F, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.blackPigment) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.whitePigment) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockOrangeWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.orangePigment) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockMagentaWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.lightbluePigment), this.molecule(MoleculeEnum.redPigment) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockLightBlueWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.lightbluePigment) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockYellowWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.yellowPigment) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockLimeWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.limePigment) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockPinkWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.redPigment), this.molecule(MoleculeEnum.whitePigment) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockGrayWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.whitePigment), this.molecule(MoleculeEnum.blackPigment, 2) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockLightGrayWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.whitePigment), this.molecule(MoleculeEnum.blackPigment) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockCyanWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.lightbluePigment), this.molecule(MoleculeEnum.whitePigment) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockPurpleWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.purplePigment) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockBlueWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.lazurite) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockGreenWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.greenPigment) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockRedWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.redPigment) }));
        SynthesisRecipe.add(new SynthesisRecipe(blockRockBlackWool, false, COST_WOOL, new PotionChemical[] { this.molecule(MoleculeEnum.asbestos, 2), this.molecule(MoleculeEnum.blackPigment) }));
        Block glass = GameRegistry.findBlock("ThermalExpansion", "Glass");
        Block frame = GameRegistry.findBlock("ThermalExpansion", "Frame");
        Block light = GameRegistry.findBlock("ThermalExpansion", "Light");
        ItemStack glassStack = new ItemStack(glass);
        ItemStack lightFrameStack = new ItemStack(frame, 1, 9);
        ItemStack lightStack = new ItemStack(light);
        DecomposerRecipe.add(new DecomposerRecipe(glassStack, new PotionChemical[] { this.molecule(MoleculeEnum.magnesiumOxide, 8), this.molecule(MoleculeEnum.siliconOxide, 16), this.element(ElementEnum.Pb, 8) }));
        DecomposerRecipe.add(new DecomposerRecipe(lightFrameStack, new PotionChemical[] { this.molecule(MoleculeEnum.siliconDioxide, 4), this.molecule(MoleculeEnum.galliumarsenide, 1), this.molecule(MoleculeEnum.magnesiumOxide, 16), this.molecule(MoleculeEnum.siliconOxide, 32), this.element(ElementEnum.Pb, 16), this.element(ElementEnum.Cu, 16) }));
        DecomposerRecipe.add(new DecomposerRecipe(lightStack, new PotionChemical[] { this.molecule(MoleculeEnum.siliconDioxide, 4), this.molecule(MoleculeEnum.galliumarsenide, 1), this.molecule(MoleculeEnum.magnesiumOxide, 16), this.molecule(MoleculeEnum.siliconOxide, 32), this.element(ElementEnum.Pb, 16), this.element(ElementEnum.Cu, 16), this.element(ElementEnum.P, 4) }));
    }
    if (Loader.isModLoaded("ThermalFoundation")) {
        Item bucket = GameRegistry.findItem("ThermalFoundation", "bucket");
        Item material = GameRegistry.findItem("ThermalFoundation", "material");
        ItemStack redstoneBucket = new ItemStack(bucket, 1, 0);
        ItemStack glowstoneBucket = new ItemStack(bucket, 1, 1);
        ItemStack enderBucket = new ItemStack(bucket, 1, 2);
        ItemStack signalumBlend = new ItemStack(material, 1, 42);
        ItemStack lumiumBlend = new ItemStack(material, 1, 43);
        ItemStack enderiumBlend = new ItemStack(material, 1, 44);
        ItemStack signalumIngot = new ItemStack(material, 1, 74);
        ItemStack lumiumIngot = new ItemStack(material, 1, 75);
        ItemStack enderiumIngot = new ItemStack(material, 1, 76);
        DecomposerRecipe.add(new DecomposerRecipe(redstoneBucket, new PotionChemical[] { this.element(ElementEnum.Cu, 4), this.element(ElementEnum.Fe, 48), this.molecule(MoleculeEnum.iron3oxide, 4) }));
        DecomposerRecipe.add(new DecomposerRecipe(enderBucket, new PotionChemical[] { this.element(ElementEnum.Fe, 48), this.element(ElementEnum.Es, 4), this.molecule(MoleculeEnum.calciumCarbonate, 32) }));
        DecomposerRecipe.add(new DecomposerRecipe(glowstoneBucket, new PotionChemical[] { this.element(ElementEnum.Fe, 48), this.element(ElementEnum.P, 4) }));
        DecomposerRecipe.add(new DecomposerRecipe(signalumBlend, new PotionChemical[] { this.element(ElementEnum.Cu, 12), this.element(ElementEnum.Ag, 4), this.molecule(MoleculeEnum.iron3oxide) }));
        DecomposerRecipe.add(new DecomposerRecipe(signalumIngot, new PotionChemical[] { this.element(ElementEnum.Cu, 12), this.element(ElementEnum.Ag, 4), this.molecule(MoleculeEnum.iron3oxide) }));
        DecomposerRecipe.add(new DecomposerRecipe(lumiumBlend, new PotionChemical[] { this.element(ElementEnum.Sn, 12), this.element(ElementEnum.Ag, 4), this.element(ElementEnum.P) }));
        DecomposerRecipe.add(new DecomposerRecipe(lumiumIngot, new PotionChemical[] { this.element(ElementEnum.Sn, 12), this.element(ElementEnum.Ag, 4), this.element(ElementEnum.P) }));
        DecomposerRecipe.add(new DecomposerRecipe(enderiumBlend, new PotionChemical[] { this.element(ElementEnum.Sn, 8), this.element(ElementEnum.Ag, 4), this.element(ElementEnum.Pt, 4), this.element(ElementEnum.Es), this.molecule(MoleculeEnum.calciumCarbonate, 8) }));
        DecomposerRecipe.add(new DecomposerRecipe(enderiumIngot, new PotionChemical[] { this.element(ElementEnum.Sn, 8), this.element(ElementEnum.Ag, 4), this.element(ElementEnum.Pt, 4), this.element(ElementEnum.Es), this.molecule(MoleculeEnum.calciumCarbonate, 8) }));
        SynthesisRecipe.add(new SynthesisRecipe(signalumBlend, false, COST_INGOT, new PotionChemical[] { this.element(ElementEnum.Cu, 12), this.element(ElementEnum.Ag, 4), this.molecule(MoleculeEnum.iron3oxide) }));
        SynthesisRecipe.add(new SynthesisRecipe(signalumIngot, false, COST_INGOT, new PotionChemical[] { this.element(ElementEnum.Cu, 12), this.element(ElementEnum.Ag, 4), this.molecule(MoleculeEnum.iron3oxide) }));
        SynthesisRecipe.add(new SynthesisRecipe(lumiumBlend, false, COST_INGOT, new PotionChemical[] { this.element(ElementEnum.Sn, 12), this.element(ElementEnum.Ag, 4), this.element(ElementEnum.P) }));
        SynthesisRecipe.add(new SynthesisRecipe(lumiumIngot, false, COST_INGOT, new PotionChemical[] { this.element(ElementEnum.Sn, 12), this.element(ElementEnum.Ag, 4), this.element(ElementEnum.P) }));
        SynthesisRecipe.add(new SynthesisRecipe(enderiumBlend, false, COST_INGOT, new PotionChemical[] { this.element(ElementEnum.Sn, 8), this.element(ElementEnum.Ag, 4), this.element(ElementEnum.Pt, 4), this.element(ElementEnum.Es), this.molecule(MoleculeEnum.calciumCarbonate, 8) }));
        SynthesisRecipe.add(new SynthesisRecipe(enderiumIngot, false, COST_INGOT * 2, new PotionChemical[] { this.element(ElementEnum.Sn, 8), this.element(ElementEnum.Ag, 4), this.element(ElementEnum.Pt, 4), this.element(ElementEnum.Es), this.molecule(MoleculeEnum.calciumCarbonate, 8), this.molecule(MoleculeEnum.iron3oxide), this.element(ElementEnum.Pu), this.element(ElementEnum.C, 8), this.element(ElementEnum.S, 16) }));
    }
    // Redstone Arsenal
    if (Loader.isModLoaded("RedstoneArsenal")) {
        Item alloy = GameRegistry.findItem("RedstoneArsenal", "material");
        ItemStack blend = new ItemStack(alloy, 1, 0);
        ItemStack ingot = new ItemStack(alloy, 1, 32);
        ItemStack nugget = new ItemStack(alloy, 1, 64);
        ItemStack gem = new ItemStack(alloy, 1, 96);
        DecomposerRecipe.add(new DecomposerRecipe(blend, new PotionChemical[] { this.element(ElementEnum.Au, 8), this.element(ElementEnum.Ag, 8), this.molecule(MoleculeEnum.iron3oxide), this.element(ElementEnum.Cu) }));
        DecomposerRecipe.add(new DecomposerRecipe(ingot, new PotionChemical[] { this.element(ElementEnum.Au, 8), this.element(ElementEnum.Ag, 8), this.molecule(MoleculeEnum.iron3oxide), this.element(ElementEnum.Cu) }));
        DecomposerRecipe.add(new DecomposerRecipeSelect(nugget, 0.11F, new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Au, 8), this.element(ElementEnum.Ag, 8), this.molecule(MoleculeEnum.iron3oxide), this.element(ElementEnum.Cu) })));
        DecomposerRecipe.add(new DecomposerRecipe(gem, new PotionChemical[] { this.molecule(MoleculeEnum.fullrene, 3), this.molecule(MoleculeEnum.iron3oxide), this.element(ElementEnum.Cu) }));
        SynthesisRecipe.add(new SynthesisRecipe(blend, false, COST_INGOT * 2, new PotionChemical[] { this.element(ElementEnum.Au, 8), this.element(ElementEnum.Ag, 8), this.molecule(MoleculeEnum.iron3oxide, 2), this.element(ElementEnum.Cu, 2) }));
        SynthesisRecipe.add(new SynthesisRecipe(ingot, false, COST_INGOT * 2, new PotionChemical[] { this.element(ElementEnum.Au, 8), this.element(ElementEnum.Ag, 8), this.molecule(MoleculeEnum.iron3oxide, 2), this.element(ElementEnum.Cu, 2) }));
        SynthesisRecipe.add(new SynthesisRecipe(gem, false, COST_INGOT * 2, new PotionChemical[] { this.molecule(MoleculeEnum.fullrene, 3), this.molecule(MoleculeEnum.iron3oxide, 2), this.element(ElementEnum.Cu, 2) }));
    }
    // EnderIO
    if (Loader.isModLoaded("EnderIO")) {
        Item alloy = GameRegistry.findItem("EnderIO", "itemAlloy");
        ItemStack electricalSteel = new ItemStack(alloy, 1, 0);
        ItemStack energeticAlloy = new ItemStack(alloy, 1, 1);
        ItemStack vibrantAlloy = new ItemStack(alloy, 1, 2);
        ItemStack redstoneAlloy = new ItemStack(alloy, 1, 3);
        ItemStack conductiveIron = new ItemStack(alloy, 1, 4);
        ItemStack pulsatingIron = new ItemStack(alloy, 1, 5);
        ItemStack darkSteel = new ItemStack(alloy, 1, 6);
        ItemStack soularium = new ItemStack(alloy, 1, 7);
        DecomposerRecipe.add(new DecomposerRecipe(electricalSteel, new PotionChemical[] { this.element(ElementEnum.Fe, 8), this.element(ElementEnum.C, 4), this.element(ElementEnum.Si, 4) }));
        DecomposerRecipe.add(new DecomposerRecipe(energeticAlloy, new PotionChemical[] { this.element(ElementEnum.Au, 8), this.element(ElementEnum.P, 1), this.molecule(MoleculeEnum.iron3oxide), this.element(ElementEnum.Cu) }));
        DecomposerRecipe.add(new DecomposerRecipe(vibrantAlloy, new PotionChemical[] { this.element(ElementEnum.Au, 8), this.element(ElementEnum.P, 1), this.molecule(MoleculeEnum.iron3oxide), this.element(ElementEnum.Cu), this.element(ElementEnum.Es), this.molecule(MoleculeEnum.calciumCarbonate, 4) }));
        DecomposerRecipe.add(new DecomposerRecipe(redstoneAlloy, new PotionChemical[] { this.element(ElementEnum.Si, 12), this.molecule(MoleculeEnum.iron3oxide), this.element(ElementEnum.Cu) }));
        DecomposerRecipe.add(new DecomposerRecipe(conductiveIron, new PotionChemical[] { this.element(ElementEnum.Fe, 12), this.molecule(MoleculeEnum.iron3oxide), this.element(ElementEnum.Cu) }));
        DecomposerRecipe.add(new DecomposerRecipe(pulsatingIron, new PotionChemical[] { this.element(ElementEnum.Fe, 12), this.element(ElementEnum.Es), this.molecule(MoleculeEnum.calciumCarbonate, 6) }));
        DecomposerRecipe.add(new DecomposerRecipe(darkSteel, new PotionChemical[] { this.molecule(MoleculeEnum.magnesiumOxide, 4), this.molecule(MoleculeEnum.siliconOxide, 8), this.element(ElementEnum.Fe, 8), this.element(ElementEnum.C, 4) }));
        DecomposerRecipe.add(new DecomposerRecipeSelect(soularium, 0.4F, new DecomposerRecipe[] { new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Pb, 3), this.element(ElementEnum.Be, 1), this.element(ElementEnum.Si, 2), this.element(ElementEnum.O), this.element(ElementEnum.Au, 8) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Pb, 1), this.element(ElementEnum.Si, 5), this.element(ElementEnum.O, 2), this.element(ElementEnum.Au, 8) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Si, 2), this.element(ElementEnum.O), this.element(ElementEnum.Au, 8) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Si, 6), this.element(ElementEnum.O, 2), this.element(ElementEnum.Au, 8) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Es, 1), this.element(ElementEnum.O, 2), this.element(ElementEnum.Au, 8) }) }));
    }
    if (Loader.isModLoaded("appliedenergistics2")) {
        MoleculeEnum certusQuartzMolecule = MoleculeEnum.aluminiumPhosphate;
        MoleculeEnum chargedCertusQuartzMolecule = MoleculeEnum.aluminiumHypophosphite;
        PotionChemical chargedCertusQuartzChemical = new Molecule(chargedCertusQuartzMolecule);
        PotionChemical[] chargedCertusQuartzDecompositionFormula = new PotionChemical[] { new Molecule(chargedCertusQuartzMolecule, 4) };
        PotionChemical[] chargedCertusQuartzCrystalSynthesisFormula = new PotionChemical[] { null, chargedCertusQuartzChemical, null, chargedCertusQuartzChemical, null, chargedCertusQuartzChemical, null, chargedCertusQuartzChemical, null };
        PotionChemical[] quartzGlassDecompositionFormula = new PotionChemical[] { new Molecule(certusQuartzMolecule, 5), new Molecule(MoleculeEnum.siliconDioxide, 16) };
        PotionChemical[] quartzGlassCrystalSynthesisFormula = new PotionChemical[] { new Molecule(certusQuartzMolecule), new Molecule(MoleculeEnum.siliconDioxide, 4), new Molecule(certusQuartzMolecule), new Molecule(MoleculeEnum.siliconDioxide, 4), new Molecule(certusQuartzMolecule), new Molecule(MoleculeEnum.siliconDioxide, 4), new Molecule(certusQuartzMolecule), new Molecule(MoleculeEnum.siliconDioxide, 4), new Molecule(certusQuartzMolecule) };
        Item item = GameRegistry.findItem("appliedenergistics2", "item.ItemMultiMaterial");
        Block skyStone = GameRegistry.findBlock("appliedenergistics2", "tile.BlockSkyStone");
        Block quartzGlass = GameRegistry.findBlock("appliedenergistics2", "tile.BlockQuartzGlass");
        ItemStack charged = new ItemStack(item, 1, 1);
        ItemStack singularity = new ItemStack(item, 1, 47);
        ItemStack skystone = new ItemStack(skyStone);
        ItemStack quartzglass = new ItemStack(quartzGlass);
        DecomposerRecipe.add(new DecomposerRecipe(charged, chargedCertusQuartzDecompositionFormula));
        SynthesisRecipe.add(new SynthesisRecipe(charged, true, 30000, chargedCertusQuartzCrystalSynthesisFormula));
        DecomposerRecipe.add(new DecomposerRecipe(singularity, new PotionChemical[] { this.element(ElementEnum.Fm, 148), this.element(ElementEnum.Md, 142), this.element(ElementEnum.No, 133), this.element(ElementEnum.Lr, 124), this.element(ElementEnum.Rf, 107), this.element(ElementEnum.Db, 104), this.element(ElementEnum.Sg, 93), this.element(ElementEnum.Bh, 81), this.element(ElementEnum.Hs, 67), this.element(ElementEnum.Mt, 54), this.element(ElementEnum.Ds, 52), this.element(ElementEnum.Rg, 37), this.element(ElementEnum.Cn, 33), this.element(ElementEnum.Uut, 22) }));
        DecomposerRecipe.add(new DecomposerRecipeSelect(skystone, 0.9F, new DecomposerRecipe[] { new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Si), this.element(ElementEnum.He) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Fe), this.element(ElementEnum.Xe) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Mg), this.element(ElementEnum.Ar) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Ti), this.element(ElementEnum.He) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Pb), this.element(ElementEnum.Ne) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Zn), this.element(ElementEnum.He) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Al), this.element(ElementEnum.He) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Si), this.element(ElementEnum.Xe) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Fe), this.element(ElementEnum.Ar) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Mg), this.element(ElementEnum.Kr) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Ti), this.element(ElementEnum.Ne) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Pb), this.element(ElementEnum.Rn) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Zn), this.element(ElementEnum.Ne) }), new DecomposerRecipe(new PotionChemical[] { this.element(ElementEnum.Al), this.element(ElementEnum.Ar) }) }));
        DecomposerRecipe.add(new DecomposerRecipe(quartzglass, quartzGlassDecompositionFormula));
        SynthesisRecipe.add(new SynthesisRecipe(quartzglass, true, 30000, quartzGlassCrystalSynthesisFormula));
    }
    // RailCraft
    if (Loader.isModLoaded("Railcraft")) {
        Block metalPost = GameRegistry.findBlock("Railcraft", "tile.railcraft.post.metal");
        Block metalPlatform = GameRegistry.findBlock("Railcraft", "tile.railcraft.post.metal.platform");
        Block post = GameRegistry.findBlock("Railcraft", "tile.railcraft.post");
        DecomposerRecipe.add(new DecomposerRecipe(new ItemStack(metalPost), this.element(ElementEnum.Fe, 5)));
        DecomposerRecipe.add(new DecomposerRecipe(new ItemStack(metalPlatform), this.element(ElementEnum.Fe, 5)));
        DecomposerRecipe.add(new DecomposerRecipe(new ItemStack(post), new PotionChemical[] {}));
    }
}
Also used : Molecule(minechem.item.molecule.Molecule) Item(net.minecraft.item.Item) ElementItem(minechem.item.element.ElementItem) SynthesisRecipe(minechem.tileentity.synthesis.SynthesisRecipe) Element(minechem.item.element.Element) DecomposerRecipeChance(minechem.tileentity.decomposer.DecomposerRecipeChance) DecomposerRecipeSelect(minechem.tileentity.decomposer.DecomposerRecipeSelect) Block(net.minecraft.block.Block) ItemBlock(net.minecraft.item.ItemBlock) PotionChemical(minechem.potion.PotionChemical) DecomposerRecipe(minechem.tileentity.decomposer.DecomposerRecipe) MoleculeEnum(minechem.item.molecule.MoleculeEnum) ItemStack(net.minecraft.item.ItemStack)

Example 2 with SynthesisRecipe

use of minechem.tileentity.synthesis.SynthesisRecipe in project Minechem by iopleke.

the class ChemicalTurtlePeripheral method keyListToStacks.

private ArrayList<ItemStack> keyListToStacks(List<MapKey> keys) {
    ArrayList<ItemStack> result = new ArrayList<ItemStack>();
    for (MapKey key : keys) {
        if (key != null) {
            ItemStack add = null;
            DecomposerRecipe decomp = DecomposerRecipe.get(key);
            if (decomp != null) {
                add = decomp.getInput();
            } else {
                SynthesisRecipe synth = SynthesisRecipe.get(key);
                if (synth != null) {
                    add = synth.getOutput();
                }
            }
            if (add != null) {
                result.add(add);
            }
        }
    }
    return result;
}
Also used : MapKey(minechem.utils.MapKey) SynthesisRecipe(minechem.tileentity.synthesis.SynthesisRecipe) ArrayList(java.util.ArrayList) DecomposerRecipe(minechem.tileentity.decomposer.DecomposerRecipe) ItemStack(net.minecraft.item.ItemStack)

Example 3 with SynthesisRecipe

use of minechem.tileentity.synthesis.SynthesisRecipe in project Minechem by iopleke.

the class MicroscopeTileEntity method onInspectItemStack.

public void onInspectItemStack(ItemStack itemstack) {
    SynthesisRecipe synthesisRecipe = SynthesisRecipeHandler.instance.getRecipeFromOutput(itemstack);
    DecomposerRecipe decomposerRecipe = DecomposerRecipeHandler.instance.getRecipe(itemstack);
    if (inventory[1] != null && (synthesisRecipe != null || decomposerRecipe != null)) {
        MinechemItemsRegistration.journal.addItemStackToJournal(itemstack, inventory[1], worldObj);
    }
}
Also used : SynthesisRecipe(minechem.tileentity.synthesis.SynthesisRecipe) DecomposerRecipe(minechem.tileentity.decomposer.DecomposerRecipe)

Example 4 with SynthesisRecipe

use of minechem.tileentity.synthesis.SynthesisRecipe in project Minechem by iopleke.

the class MoleculeEnum method registerMTMolecule.

public static void registerMTMolecule(MoleculeEnum molecule) {
    addMapping(molecule);
    ArrayList<PotionChemical> var5 = molecule.components();
    PotionChemical[] var6 = var5.toArray(new PotionChemical[var5.size()]);
    ItemStack var7 = new ItemStack(MinechemItemsRegistration.molecule, 1, molecule.id());
    DecomposerRecipe.add(new DecomposerRecipe(var7, var6));
    SynthesisRecipe.add(new SynthesisRecipe(var7, true, MinechemRecipes.COST_ITEM, var6));
}
Also used : SynthesisRecipe(minechem.tileentity.synthesis.SynthesisRecipe) PotionChemical(minechem.potion.PotionChemical) DecomposerRecipe(minechem.tileentity.decomposer.DecomposerRecipe) ItemStack(net.minecraft.item.ItemStack)

Example 5 with SynthesisRecipe

use of minechem.tileentity.synthesis.SynthesisRecipe in project Minechem by iopleke.

the class MinechemRecipes method addUnusedSynthesisRecipes.

private void addUnusedSynthesisRecipes() {
    Iterator decomposerRecipes = DecomposerRecipe.recipes.values().iterator();
    while (decomposerRecipes.hasNext()) {
        DecomposerRecipe nextDecomposerRecipe = (DecomposerRecipe) decomposerRecipes.next();
        if (nextDecomposerRecipe.getInput().getItemDamage() != -1) {
            boolean check = false;
            Iterator synthesisRecipes = SynthesisRecipe.recipes.values().iterator();
            while (true) {
                if (synthesisRecipes.hasNext()) {
                    SynthesisRecipe nextSynthesisRecipe = (SynthesisRecipe) synthesisRecipes.next();
                    if (!Compare.stacksAreSameKind(nextSynthesisRecipe.getOutput(), nextDecomposerRecipe.getInput())) {
                        continue;
                    }
                    check = true;
                }
                if (!check) {
                    ArrayList rawDecomposerRecipe = nextDecomposerRecipe.getOutputRaw();
                    if (rawDecomposerRecipe != null) {
                        if (shouldCreateSynthesis(nextDecomposerRecipe.getInput())) {
                            SynthesisRecipe.add(new SynthesisRecipe(nextDecomposerRecipe.getInput(), false, 100, rawDecomposerRecipe));
                        }
                    }
                }
                break;
            }
        }
    }
}
Also used : SynthesisRecipe(minechem.tileentity.synthesis.SynthesisRecipe) Iterator(java.util.Iterator) ArrayList(java.util.ArrayList) DecomposerRecipe(minechem.tileentity.decomposer.DecomposerRecipe)

Aggregations

SynthesisRecipe (minechem.tileentity.synthesis.SynthesisRecipe)10 DecomposerRecipe (minechem.tileentity.decomposer.DecomposerRecipe)8 ItemStack (net.minecraft.item.ItemStack)6 PotionChemical (minechem.potion.PotionChemical)4 ArrayList (java.util.ArrayList)3 MoleculeEnum (minechem.item.molecule.MoleculeEnum)3 Element (minechem.item.element.Element)2 Molecule (minechem.item.molecule.Molecule)2 DecomposerRecipeChance (minechem.tileentity.decomposer.DecomposerRecipeChance)2 DecomposerRecipeSelect (minechem.tileentity.decomposer.DecomposerRecipeSelect)2 MapKey (minechem.utils.MapKey)2 ILuaContext (dan200.computercraft.api.lua.ILuaContext)1 LuaException (dan200.computercraft.api.lua.LuaException)1 IComputerAccess (dan200.computercraft.api.peripheral.IComputerAccess)1 HashMap (java.util.HashMap)1 Iterator (java.util.Iterator)1 List (java.util.List)1 LuaMethod (minechem.computercraft.lua.LuaMethod)1 ElementItem (minechem.item.element.ElementItem)1 ChemistJournalActiveItemMessage (minechem.network.message.ChemistJournalActiveItemMessage)1