Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nuke ic2 recipe registration #21

Merged
merged 1 commit into from
Sep 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,18 @@

import appeng.api.AEApi;
import appeng.api.util.AEColor;
import cpw.mods.fml.common.Loader;
import ic2.api.item.IC2Items;
import ic2.api.recipe.Recipes;

public class AppengRecipes {

public static void addRecipesToRegistry() {

if (Loader.isModLoaded("dreamcraft")) {
return;
}

// AE Kit
Recipes.advRecipes.addRecipe(
new ItemStack(CrossAppeng.kitAppeng),
Expand All @@ -29,6 +34,10 @@ public static void addRecipesToRegistry() {

public static void addGregtechRecipes() {

if (Loader.isModLoaded("dreamcraft")) {
return;
}

// AE Kit
Recipes.advRecipes.addRecipe(
new ItemStack(CrossAppeng.kitAppeng),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import net.minecraft.item.ItemStack;
import net.minecraft.item.crafting.CraftingManager;

import cpw.mods.fml.common.Loader;
import cpw.mods.fml.common.registry.GameRegistry;
import ic2.api.item.IC2Items;
import ic2.api.recipe.Recipes;
Expand All @@ -19,25 +20,19 @@

public class GregtechRecipes {

private static Item gtmeta1;
private static ItemStack gtComputerMonitor;
private static ItemStack gtSensor;
private static ItemStack gtEmitter;

/**
* Grabs all the nessary items/itemstacks from GT indirectly.
*
* @author xbony2
*/
public static void grabItems() {
gtmeta1 = GameRegistry.findItem("gregtech", "gt.metaitem.01");
gtComputerMonitor = new ItemStack(gtmeta1, 1, 32740);
gtSensor = new ItemStack(gtmeta1, 1, 32690);
gtEmitter = new ItemStack(gtmeta1, 1, 32680);
}

public static void addRecipes() {
GregtechRecipes.grabItems();

CraftingManager.getInstance().getRecipeList().add(new StorageArrayRecipe());

if (Loader.isModLoaded("dreamcraft")) {
return;
}

final Item gtmeta1 = GameRegistry.findItem("gregtech", "gt.metaitem.01");
final ItemStack gtComputerMonitor = new ItemStack(gtmeta1, 1, 32740);
final ItemStack gtSensor = new ItemStack(gtmeta1, 1, 32690);
final ItemStack gtEmitter = new ItemStack(gtmeta1, 1, 32680);

Recipes.advRecipes.addRecipe(
new ItemStack(IC2NuclearControl.itemToolThermometer),
new Object[] { "BG ", "GMG", " GI", 'B', "boltIron", 'G', "plateGlass", 'M', "cellMercury", 'I',
Expand Down Expand Up @@ -245,6 +240,5 @@ public static void addRecipes() {
BlockDamages.DAMAGE_INFO_PANEL_EXTENDER),
'R', IC2NuclearControl.itemUpgrade, 'P', "plateStainlessSteel" });

CraftingManager.getInstance().getRecipeList().add(new StorageArrayRecipe());
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;

import cpw.mods.fml.common.Loader;
import cpw.mods.fml.common.registry.GameRegistry;
import ic2.api.item.IC2Items;
import ic2.api.recipe.Recipes;
Expand All @@ -25,6 +26,10 @@ public static void initVanilla() {
GameRegistry.registerItem(vanillaKit, "ItemVanilliaKit");
GameRegistry.registerItem(machineCard, "ItemVanillaMachineCard");

if (Loader.isModLoaded("dreamcraft")) {
return;
}

Recipes.advRecipes.addRecipe(
new ItemStack(vanillaKit),
new Object[] { "PL ", "FC ", 'P', Items.paper, 'C', "circuitBasic", 'F',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import net.minecraft.item.ItemStack;
import net.minecraft.item.crafting.CraftingManager;

import cpw.mods.fml.common.Loader;
import ic2.api.item.IC2Items;
import ic2.api.recipe.Recipes;
import ic2.core.util.StackUtil;
Expand All @@ -18,6 +19,13 @@
public class RecipesNew {

public static void addRecipes() {

CraftingManager.getInstance().getRecipeList().add(new StorageArrayRecipe());

if (Loader.isModLoaded("dreamcraft")) {
return;
}

ItemStack thermalMonitor = new ItemStack(
IC2NuclearControl.blockNuclearControlMain,
1,
Expand Down Expand Up @@ -220,6 +228,5 @@ public static void addRecipes() {
IC2Items.getItem("electronicCircuit"),
IC2NuclearControl.itemMultipleSensorLocationCard);

CraftingManager.getInstance().getRecipeList().add(new StorageArrayRecipe());
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import net.minecraft.item.ItemStack;
import net.minecraft.item.crafting.CraftingManager;

import cpw.mods.fml.common.Loader;
import ic2.api.item.IC2Items;
import ic2.api.recipe.Recipes;
import ic2.core.util.StackUtil;
Expand All @@ -19,6 +20,13 @@ public class RecipesOld {

@Deprecated // It's not :P ~Chocohead
public static void addOldRecipes() {

CraftingManager.getInstance().getRecipeList().add(new StorageArrayRecipe());

if (Loader.isModLoaded("dreamcraft")) {
return;
}

ItemStack thermalMonitor = new ItemStack(
IC2NuclearControl.blockNuclearControlMain,
1,
Expand Down Expand Up @@ -220,6 +228,5 @@ public static void addOldRecipes() {
new ItemStack(IC2Items.getItem("electronicCircuit").getItem(), 1),
new ItemStack(IC2NuclearControl.itemTimeCard, 1));

CraftingManager.getInstance().getRecipeList().add(new StorageArrayRecipe());
}
}