diff --git a/src/main/java/WayofTime/bloodmagic/core/RegistrarBloodMagicRecipes.java b/src/main/java/WayofTime/bloodmagic/core/RegistrarBloodMagicRecipes.java index a323b825..62f6d717 100644 --- a/src/main/java/WayofTime/bloodmagic/core/RegistrarBloodMagicRecipes.java +++ b/src/main/java/WayofTime/bloodmagic/core/RegistrarBloodMagicRecipes.java @@ -36,12 +36,16 @@ import java.util.List; import java.util.Set; @Mod.EventBusSubscriber(modid = BloodMagic.MODID) -public class RegistrarBloodMagicRecipes { +public class RegistrarBloodMagicRecipes +{ @SubscribeEvent - public static void registerRecipes(RegistryEvent.Register event) { - for (int i = 0; i < ItemSoulGem.names.length; i++) { - for (EnumDemonWillType willType : EnumDemonWillType.values()) { + public static void registerRecipes(RegistryEvent.Register event) + { + for (int i = 0; i < ItemSoulGem.names.length; i++) + { + for (EnumDemonWillType willType : EnumDemonWillType.values()) + { ItemStack baseGemStack = new ItemStack(RegistrarBloodMagicItems.SOUL_GEM, 1, i); ItemStack newGemStack = new ItemStack(RegistrarBloodMagicItems.SOUL_GEM, 1, i); @@ -58,7 +62,8 @@ public class RegistrarBloodMagicRecipes { PluginUtil.handlePluginStep(PluginUtil.RegistrationStep.RECIPE_REGISTER); } - public static void registerAltarRecipes(BloodMagicRecipeRegistrar registrar) { + public static void registerAltarRecipes(BloodMagicRecipeRegistrar registrar) + { // ONE registrar.addBloodAltar(new OreIngredient("gemDiamond"), OrbRegistry.getOrbStack(RegistrarBloodMagic.ORB_WEAK), AltarTier.ONE.ordinal(), 2000, 2, 1); registrar.addBloodAltar(new OreIngredient("stone"), ItemSlate.SlateType.BLANK.getStack(), AltarTier.ONE.ordinal(), 1000, 5, 5); @@ -95,7 +100,8 @@ public class RegistrarBloodMagicRecipes { registrar.addBloodAltar(new OreIngredient("glowstone"), EnumRuneType.DAWN.getStack(), AltarTier.SIX.ordinal(), 200000, 100, 200); } - public static void registerAlchemyTableRecipes(BloodMagicRecipeRegistrar registrar) { + public static void registerAlchemyTableRecipes(BloodMagicRecipeRegistrar registrar) + { registrar.addAlchemyTable(new ItemStack(Items.STRING, 4), 0, 100, 0, Blocks.WOOL, Items.FLINT); registrar.addAlchemyTable(new ItemStack(Items.FLINT, 2), 0, 20, 0, Blocks.GRAVEL, Items.FLINT); registrar.addAlchemyTable(new ItemStack(Items.LEATHER, 4), 100, 200, 1, Items.ROTTEN_FLESH, Items.ROTTEN_FLESH, Items.ROTTEN_FLESH, Items.ROTTEN_FLESH, Items.FLINT, Items.WATER_BUCKET); @@ -109,7 +115,7 @@ public class RegistrarBloodMagicRecipes { registrar.addAlchemyTable(ComponentTypes.SALTPETER.getStack(4), 0, 100, 0, ComponentTypes.PLANT_OIL.getStack(), ComponentTypes.PLANT_OIL.getStack(), "dustCoal"); registrar.addAlchemyTable(new ItemStack(Items.GUNPOWDER, 3), 0, 100, 0, "dustSaltpeter", "dustSulfur", new ItemStack(Items.COAL, 1, 1)); registrar.addAlchemyTable(ComponentTypes.SAND_COAL.getStack(4), 100, 100, 1, new ItemStack(Items.COAL, 1, 0), new ItemStack(Items.COAL, 1, 0), Items.FLINT); - registrar.addAlchemyTable(ItemCuttingFluid.FluidType.BASIC.getStack(), 1000, 400, 1, "dustCoal", "gunpowder", Items.REDSTONE, Items.SUGAR, ComponentTypes.PLANT_OIL.getStack(), PotionUtils.addPotionToItemStack(new ItemStack(Items.POTIONITEM), PotionTypes.WATER); + registrar.addAlchemyTable(ItemCuttingFluid.FluidType.BASIC.getStack(), 1000, 400, 1, "dustCoal", "gunpowder", Items.REDSTONE, Items.SUGAR, ComponentTypes.PLANT_OIL.getStack(), PotionUtils.addPotionToItemStack(new ItemStack(Items.POTIONITEM), PotionTypes.WATER)); registrar.addAlchemyTable(ComponentTypes.SAND_IRON.getStack(2), 400, 200, 1, "oreIron", ItemCuttingFluid.FluidType.BASIC.getStack()); registrar.addAlchemyTable(ComponentTypes.SAND_GOLD.getStack(2), 400, 200, 1, "oreGold", ItemCuttingFluid.FluidType.BASIC.getStack()); registrar.addAlchemyTable(new ItemStack(Items.REDSTONE, 8), 400, 200, 1, "oreRedstone", ItemCuttingFluid.FluidType.BASIC.getStack()); @@ -128,13 +134,16 @@ public class RegistrarBloodMagicRecipes { Set addedOreRecipeList = Sets.newHashSet("oreIron", "oreGold", "oreCoal", "oreRedstone"); // We already added these above String[] oreList = OreDictionary.getOreNames().clone(); - for (String ore : oreList) { - if (ore.startsWith("ore") && !addedOreRecipeList.contains(ore)) { + for (String ore : oreList) + { + if (ore.startsWith("ore") && !addedOreRecipeList.contains(ore)) + { String dustName = ore.replaceFirst("ore", "dust"); List discoveredOres = OreDictionary.getOres(ore); List dustList = OreDictionary.getOres(dustName); - if (dustList != null && !dustList.isEmpty() && discoveredOres != null && !discoveredOres.isEmpty()) { + if (dustList != null && !dustList.isEmpty() && discoveredOres != null && !discoveredOres.isEmpty()) + { ItemStack dustStack = dustList.get(0).copy(); dustStack.setCount(2); registrar.addAlchemyTable(dustStack, 400, 200, 1, ore, ItemCuttingFluid.FluidType.BASIC.getStack()); @@ -144,7 +153,8 @@ public class RegistrarBloodMagicRecipes { } } - public static void registerTartaricForgeRecipes(BloodMagicRecipeRegistrar registrar) { + public static void registerTartaricForgeRecipes(BloodMagicRecipeRegistrar registrar) + { registrar.addTartaricForge(new ItemStack(RegistrarBloodMagicItems.SOUL_GEM), 1, 1, "dustRedstone", "ingotGold", "blockGlass", "dyeBlue"); registrar.addTartaricForge(new ItemStack(RegistrarBloodMagicItems.SOUL_GEM, 1, 1), 60, 20, new ItemStack(RegistrarBloodMagicItems.SOUL_GEM), "gemDiamond", "blockRedstone", "blockLapis"); registrar.addTartaricForge(new ItemStack(RegistrarBloodMagicItems.SOUL_GEM, 1, 2), 240, 50, new ItemStack(RegistrarBloodMagicItems.SOUL_GEM, 1, 1), "gemDiamond", "blockGold", ItemSlate.SlateType.IMBUED.getStack()); @@ -200,7 +210,8 @@ public class RegistrarBloodMagicRecipes { registrar.addTartaricForge(new ItemStack(RegistrarBloodMagicItems.DEMON_WILL_GAUGE), 400, 50, "ingotGold", "dustRedstone", "blockGlass", RegistrarBloodMagicItems.ITEM_DEMON_CRYSTAL); } - public static void registerAlchemyArrayRecipes(BloodMagicRecipeRegistrar registrar) { + public static void registerAlchemyArrayRecipes(BloodMagicRecipeRegistrar registrar) + { registrar.addAlchemyArray(new ItemStack(Items.REDSTONE), ItemSlate.SlateType.BLANK.getStack(), new ItemStack(RegistrarBloodMagicItems.SIGIL_DIVINATION), new ResourceLocation("bloodmagic", "textures/models/AlchemyArrays/DivinationSigil.png")); registrar.addAlchemyArray(ComponentTypes.REAGENT_WATER.getStack(), ItemSlate.SlateType.BLANK.getStack(), new ItemStack(RegistrarBloodMagicItems.SIGIL_WATER), new ResourceLocation("bloodmagic", "textures/models/AlchemyArrays/WaterSigil.png"));