Added missing cell recipes. Closes #867

This commit is contained in:
drcrazy 2017-09-05 15:32:43 +03:00
parent a1c77aa47c
commit 48c9371d77
4 changed files with 81 additions and 72 deletions

View file

@ -77,9 +77,9 @@ public class ModRecipes {
IndustrialElectrolyzerRecipes.init();
ImplosionCompressorRecipes.init();
ScrapboxRecipes.init();
ChemicalReactorRecipes.init();
addAlloySmelterRecipes();
addChemicalReactorRecipes();
addBlastFurnaceRecipes();
addVacuumFreezerRecipes();
addReactorRecipes();
@ -499,76 +499,6 @@ public class ModRecipes {
new ItemStack(Items.IRON_INGOT, 2), ItemDusts.getDustByName("dark_ashes"), 140, 120, 1000));
}
static void addChemicalReactorRecipes() {
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(ItemCells.getCellByName("calcium", 1), ItemCells.getCellByName("carbon", 1),
ItemCells.getCellByName("calciumCarbonate", 2), 240, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(new ItemStack(Items.GOLD_NUGGET, 8), new ItemStack(Items.MELON, 1),
new ItemStack(Items.SPECKLED_MELON, 1), 40, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(ItemCells.getCellByName("nitrogen", 1), ItemCells.getCellByName("carbon", 1),
ItemCells.getCellByName("nitrocarbon", 2), 1500, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(ItemCells.getCellByName("carbon", 1), ItemCells.getCellByName("hydrogen", 4),
ItemCells.getCellByName("methane", 5), 3500, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(ItemCells.getCellByName("sulfur", 1), ItemCells.getCellByName("sodium", 1),
ItemCells.getCellByName("sodiumSulfide", 2), 100, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(new ItemStack(Items.BLAZE_POWDER, 1), new ItemStack(Items.ENDER_PEARL, 1),
new ItemStack(Items.ENDER_EYE, 1), 40, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(new ItemStack(Items.GOLD_NUGGET, 8), new ItemStack(Items.CARROT, 1),
new ItemStack(Items.GOLDEN_CARROT, 1), 40, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(ItemCells.getCellByName("glyceryl", 1), ItemCells.getCellByName("diesel", 4),
ItemCells.getCellByName("nitroDiesel", 5), 1000, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(new ItemStack(Items.GOLD_INGOT, 8), new ItemStack(Items.APPLE, 1),
new ItemStack(Items.GOLDEN_APPLE, 1), 40, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(new ItemStack(Blocks.GOLD_BLOCK, 8), new ItemStack(Items.APPLE, 1),
new ItemStack(Items.GOLDEN_APPLE, 1, 1), 40, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(new ItemStack(Items.BLAZE_POWDER, 1), new ItemStack(Items.SLIME_BALL, 1),
new ItemStack(Items.MAGMA_CREAM, 1), 40, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(ItemDusts.getDustByName("calcite", 1), null,
new ItemStack(getOre("fertilizer").getItem(), 1), 100, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(ItemDusts.getDustByName("calcite", 1),
ItemDusts.getDustByName("phosphorous", 1),
new ItemStack(getOre("fertilizer").getItem(), 3), 100, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(ItemCells.getCellByName("sodiumSulfide", 1),
ItemCells.getCellByName("empty"), ItemCells.getCellByName("sodiumPersulfate", 2), 2000,
30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(ItemCells.getCellByName("nitrocarbon", 1),
ItemCells.getCellByName("water"), ItemCells.getCellByName("glyceryl", 2), 580, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(ItemDusts.getDustByName("calcite", 1), ItemDusts.getDustByName("sulfur", 1),
new ItemStack(getOre("fertilizer").getItem(), 2), 100, 30));
ItemStack waterCells = ItemCells.getCellByName("water").copy();
waterCells.setCount(2);
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(ItemCells.getCellByName("sulfur", 1), waterCells,
ItemCells.getCellByName("sulfuricAcid", 3), 1140, 30));
ItemStack waterCells2 = ItemCells.getCellByName("water").copy();
waterCells2.setCount(5);
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(ItemCells.getCellByName("hydrogen", 4),
ItemCells.getCellByName("empty"), waterCells2, 10, 30));
RecipeHandler.addRecipe(
new ChemicalReactorRecipe(ItemCells.getCellByName("nitrogen", 1),
ItemCells.getCellByName("empty"), ItemCells.getCellByName("nitrogenDioxide", 2), 1240,
30));
}
static void addIc2Recipes() {
RebornCraftingHelper.addShapelessOreRecipe(new ItemStack(ModItems.MANUAL), IC2Duplicates.REFINED_IRON.getStackBasedOnConfig(),
Items.BOOK);

View file

@ -0,0 +1,77 @@
/*
* This file is part of TechReborn, licensed under the MIT License (MIT).
*
* Copyright (c) 2017 TechReborn
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
package techreborn.init.recipes;
import ic2.api.item.IC2Items;
import net.minecraft.init.Blocks;
import net.minecraft.init.Items;
import net.minecraft.item.ItemStack;
import reborncore.api.recipe.RecipeHandler;
import techreborn.api.recipe.machines.ChemicalReactorRecipe;
/**
* @author drcrazy
*
*/
public class ChemicalReactorRecipes extends RecipeMethods {
public static void init(){
register(getStack(Items.GOLD_NUGGET, 8), getStack(Items.MELON), getStack(Items.SPECKLED_MELON), 40);
register(getStack(Items.GOLD_NUGGET, 8), getStack(Items.CARROT), getStack(Items.GOLDEN_CARROT), 40);
register(getStack(Items.GOLD_INGOT, 8), getStack(Items.APPLE), getStack(Items.GOLDEN_APPLE), 40);
register(getStack(Blocks.GOLD_BLOCK, 8), getStack(Items.APPLE, 1), getStack(Items.GOLDEN_APPLE, 1, 1), 100);
register(getStack(Items.BLAZE_POWDER), getStack(Items.SLIME_BALL), getStack(Items.MAGMA_CREAM), 40);
register(getStack(Items.BLAZE_POWDER), getStack(Items.ENDER_PEARL), getStack(Items.ENDER_EYE), 40);
//Cells recipes. One cell should be cooked in 20 seconds
register(getMaterial("carbon", Type.CELL), getMaterial("calcium", Type.CELL), getMaterial("calciumCarbonate", 2, Type.CELL), 800);
register(getMaterial("carbon", Type.CELL), getMaterial("hydrogen", 4, Type.CELL), getMaterial("methane", 5, Type.CELL), 2000);
register(getMaterial("carbon", Type.CELL), getMaterial("nitrogen", Type.CELL), getMaterial("nitrocarbon", 2, Type.CELL), 800);
register(getMaterial("nitrocarbon", Type.CELL), getMaterial("water", Type.CELL), getMaterial("glyceryl", 2, Type.CELL), 800);
register(getMaterial("glyceryl", Type.CELL), getMaterial("diesel", 4, Type.CELL), getMaterial("nitroDiesel", 5, Type.CELL), 2000);
register(getMaterial("sulfur", Type.CELL), getMaterial("water", 2, Type.CELL), getMaterial("sulfuricAcid", 3, Type.CELL), 1200);
register(getMaterial("sulfur", Type.CELL), getMaterial("sodium", Type.CELL), getMaterial("sodiumSulfide", 2, Type.CELL), 800);
register(getMaterial("sodiumSulfide", Type.CELL), getMaterial("compressedair", Type.CELL), getMaterial("sodiumPersulfate", 2, Type.CELL), 800);
register(getMaterial("compressedair", Type.CELL), getMaterial("hydrogen", 2, Type.CELL), getMaterial("water", Type.CELL), 400);
register(getMaterial("compressedair", 2, Type.CELL), getMaterial("nitrogen", Type.CELL), getMaterial("nitrogenDioxide", Type.CELL), 400);
register(getMaterial("oil", Type.CELL), getMaterial("nitrogen", Type.CELL), getMaterial("nitrofuel", 2, Type.CELL), 800);
//Dusts
if (techreborn.compat.CompatManager.isIC2Loaded){
ItemStack f = IC2Items.getItem("crop_res", "fertilizer");
register(getMaterial("calcite", Type.DUST), getMaterial("sulfur", Type.DUST), f, 40);
//There is no recipe for phosphorous yet.
//register(getMaterial("calcite", Type.DUST), getMaterial("phosphorous", Type.DUST), f, 40);
}
}
static void register(ItemStack in1, ItemStack in2, ItemStack out, int tickTime, int euPerTick){
RecipeHandler.addRecipe(new ChemicalReactorRecipe(in1, in2, out, tickTime, euPerTick));
}
static void register (ItemStack in1, ItemStack in2, ItemStack out, int tickTime){
register(in1, in2, out, tickTime, 30);
}
}

View file

@ -109,6 +109,8 @@ public class IndustrialCentrifugeRecipes extends RecipeMethods {
register(getMaterial("helium", 16, Type.CELL), 10000, getMaterial("helium3", Type.CELL));
register(getMaterial("calciumcarbonate", Type.CELL), 40, getMaterial("calcite", Type.DUST));
register(getMaterial("sulfur", Type.CELL), 40, getMaterial("sulfur", Type.DUST));
//TO-DO Implement Distillation tower
register(getMaterial("oil", 4, Type.CELL), 800, getMaterial("diesel", Type.CELL));
}
static void register(Object input, int ticks, boolean oreDict, ItemStack... outputs) {

View file

@ -71,7 +71,7 @@ public class IndustrialElectrolyzerRecipes extends RecipeMethods {
register(getOre("dustAndradite", 20), 1280, 50, getMaterial("calcium", 3, Type.CELL), getMaterial("iron", 2, Type.DUST), getMaterial("silicon", 3, Type.CELL), getMaterial("compressedair", 6, Type.CELL));
register(getOre("dustGrossular", 20), 204, 50, getMaterial("calcium", 3, Type.CELL), getMaterial("aluminum", 2, Type.DUST), getMaterial("silicon", 3, Type.CELL), getMaterial("compressedair", 6, Type.CELL));
register(getOre("dustUvarovite", 20), 2200, 50, getMaterial("calcium", 3, Type.CELL), getMaterial("chrome", 2, Type.DUST), getMaterial("silicon", 3, Type.CELL), getMaterial("compressedair", 6, Type.CELL));
register(getOre("dustAshes", 2), 20, 50, getMaterial("carbon", Type.CELL));
register(getOre("dustAshes", 2), 20, 50, getMaterial("carbonfiber", Type.CELL));
register(ItemCells.getCellByName("methane", 5), 140, 50, getMaterial("hydrogen", 4, Type.CELL), getMaterial("carbon", Type.CELL));
register(ItemCells.getCellByName("sulfuricacid", 7), 40, 100, getMaterial("hydrogen", 2, Type.CELL), getMaterial("sulfur", Type.CELL), getMaterial("compressedair", 2, Type.CELL));
}