From 168febdd41c426ff6c73d5e267f2ef4fdd6f5ca6 Mon Sep 17 00:00:00 2001 From: CrazyPants Date: Sat, 11 Jan 2014 23:50:40 +0800 Subject: [PATCH] Finished off new recipe Alloy Smelter Recipes. --- .../machine/alloy/AlloyRecipeManager.java | 10 ++-- .../machine/crusher/CrusherRecipeManager.java | 6 +-- .../machine/recipe/RecipeConfigParser.java | 2 +- .../config/AlloySmelterRecipes_Core.xml | 52 +++++++++++++------ .../config/AlloySmelterRecipes_User.xml | 5 +- .../enderio/config/SAGMillRecipes_Core.xml | 42 ++++++++------- .../enderio/config/SAGMillRecipes_User.xml | 21 ++++++++ 7 files changed, 92 insertions(+), 46 deletions(-) diff --git a/common/crazypants/enderio/machine/alloy/AlloyRecipeManager.java b/common/crazypants/enderio/machine/alloy/AlloyRecipeManager.java index 7898b730..21480a97 100644 --- a/common/crazypants/enderio/machine/alloy/AlloyRecipeManager.java +++ b/common/crazypants/enderio/machine/alloy/AlloyRecipeManager.java @@ -41,9 +41,9 @@ public class AlloyRecipeManager { } public void loadRecipesFromConfig() { + VanillaFurnaceTagHandler tagHandler = new VanillaFurnaceTagHandler(); - RecipeConfig config = RecipeConfig.loadRecipeConfig(CORE_FILE_NAME, CUSTOM_FILE_NAME, tagHandler); - + RecipeConfig config = RecipeConfig.loadRecipeConfig(CORE_FILE_NAME, CUSTOM_FILE_NAME, tagHandler); if(config != null) { processConfig(config, tagHandler); } else { @@ -86,12 +86,12 @@ public class AlloyRecipeManager { } List newRecipes = config.getRecipes(false); - Log.info("Added " + newRecipes.size() + " Alloy Smelter recipes from config."); + Log.info("Found " + newRecipes.size() + " valid Alloy Smelter recipes in config."); for (Recipe rec : newRecipes) { addRecipe(new BasicAlloyRecipe(rec)); } - - tagHandler.apply(); + tagHandler.apply(); + Log.info("Finished processing Alloy Smelter recipes. " + recipes.size() + " recipes avaliable."); } diff --git a/common/crazypants/enderio/machine/crusher/CrusherRecipeManager.java b/common/crazypants/enderio/machine/crusher/CrusherRecipeManager.java index 04276961..b39bd16a 100644 --- a/common/crazypants/enderio/machine/crusher/CrusherRecipeManager.java +++ b/common/crazypants/enderio/machine/crusher/CrusherRecipeManager.java @@ -84,11 +84,11 @@ public class CrusherRecipeManager { } List newRecipes = config.getRecipes(true); - Log.info("Added " + newRecipes.size() + " SAG Mill recipes from config."); + Log.info("Found " + newRecipes.size() + " valid SAG Mill recipes in config."); for (Recipe rec : newRecipes) { addRecipe(rec); - } - + } + Log.info("Finished processing Alloy Smelter recipes. " + recipes.size() + " recipes avaliable."); } public void addRecipe(ItemStack input, float energyCost, ItemStack output) { diff --git a/common/crazypants/enderio/machine/recipe/RecipeConfigParser.java b/common/crazypants/enderio/machine/recipe/RecipeConfigParser.java index b5f37180..32281f24 100644 --- a/common/crazypants/enderio/machine/recipe/RecipeConfigParser.java +++ b/common/crazypants/enderio/machine/recipe/RecipeConfigParser.java @@ -333,7 +333,7 @@ public class RecipeConfigParser extends DefaultHandler { if(stack.getItemDamage() == OreDictionary.WILDCARD_VALUE) { useMeta = false; } - return new OreDictionaryRecipeInput(ores.get(0), OreDictionary.getOreID(oreDict)); + return new OreDictionaryRecipeInput(stack, OreDictionary.getOreID(oreDict)); } int itemID = getIntValue(AT_ITEM_ID, attributes, -1); diff --git a/resources/assets/enderio/config/AlloySmelterRecipes_Core.xml b/resources/assets/enderio/config/AlloySmelterRecipes_Core.xml index 70a4f2b5..beb32cf0 100644 --- a/resources/assets/enderio/config/AlloySmelterRecipes_Core.xml +++ b/resources/assets/enderio/config/AlloySmelterRecipes_Core.xml @@ -34,11 +34,7 @@ sand/cobble/wood=0.1 - - - - @@ -49,11 +45,7 @@ sand/cobble/wood=0.1 - - - - @@ -64,8 +56,6 @@ sand/cobble/wood=0.1 - - @@ -76,8 +66,6 @@ sand/cobble/wood=0.1 - - @@ -88,8 +76,6 @@ sand/cobble/wood=0.1 - - @@ -100,8 +86,6 @@ sand/cobble/wood=0.1 - - @@ -117,6 +101,42 @@ sand/cobble/wood=0.1 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/resources/assets/enderio/config/AlloySmelterRecipes_User.xml b/resources/assets/enderio/config/AlloySmelterRecipes_User.xml index f875da40..25520c4c 100644 --- a/resources/assets/enderio/config/AlloySmelterRecipes_User.xml +++ b/resources/assets/enderio/config/AlloySmelterRecipes_User.xml @@ -20,9 +20,12 @@ ore dictionary. + + Add this line to disbale the creation of TE alloys using the Alloy Smelter. + --> - + diff --git a/resources/assets/enderio/config/SAGMillRecipes_Core.xml b/resources/assets/enderio/config/SAGMillRecipes_Core.xml index bb358116..a6403b20 100644 --- a/resources/assets/enderio/config/SAGMillRecipes_Core.xml +++ b/resources/assets/enderio/config/SAGMillRecipes_Core.xml @@ -575,6 +575,22 @@ + + + + + + + + + + + + + + + + @@ -692,23 +708,17 @@ - + - + - + - - - - - - - + - + @@ -720,15 +730,7 @@ - - - - - - - - - + diff --git a/resources/assets/enderio/config/SAGMillRecipes_User.xml b/resources/assets/enderio/config/SAGMillRecipes_User.xml index 2585ebe4..f544f8d0 100644 --- a/resources/assets/enderio/config/SAGMillRecipes_User.xml +++ b/resources/assets/enderio/config/SAGMillRecipes_User.xml @@ -26,6 +26,27 @@ found in the core file. --> + +