diff options
Diffstat (limited to 'src/main/java/gtPlusPlus/xmod/gregtech/recipes')
| -rw-r--r-- | src/main/java/gtPlusPlus/xmod/gregtech/recipes/GregtechRecipeAdder.java | 115 |
1 files changed, 58 insertions, 57 deletions
diff --git a/src/main/java/gtPlusPlus/xmod/gregtech/recipes/GregtechRecipeAdder.java b/src/main/java/gtPlusPlus/xmod/gregtech/recipes/GregtechRecipeAdder.java index dcb2624c18..4fafaf25e3 100644 --- a/src/main/java/gtPlusPlus/xmod/gregtech/recipes/GregtechRecipeAdder.java +++ b/src/main/java/gtPlusPlus/xmod/gregtech/recipes/GregtechRecipeAdder.java @@ -9,16 +9,15 @@ import gregtech.api.GregTech_API; import gregtech.api.enums.ConfigCategories; import gregtech.api.enums.GT_Values; import gregtech.api.enums.Materials; -import gregtech.api.util.GTPP_Recipe; -import gregtech.api.util.GTPP_Recipe.GTPP_Recipe_Map; +import gregtech.api.recipe.RecipeMaps; import gregtech.api.util.GT_ModHandler; import gregtech.api.util.GT_OreDictUnificator; import gregtech.api.util.GT_Recipe; -import gregtech.api.util.GT_Recipe.GT_Recipe_Map; import gregtech.api.util.GT_Utility; import gregtech.api.util.SemiFluidFuelHandler; import gtPlusPlus.api.objects.Logger; import gtPlusPlus.api.objects.data.AutoMap; +import gtPlusPlus.api.recipe.GTPPRecipeMaps; import gtPlusPlus.core.lib.CORE; import gtPlusPlus.core.material.Material; import gtPlusPlus.core.material.MaterialGenerator; @@ -48,7 +47,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { return false; } - GTPP_Recipe aSpecialRecipe = new GTPP_Recipe( + GT_Recipe aSpecialRecipe = new GT_Recipe( true, new ItemStack[] { aInput1, aInput2 }, new ItemStack[] { aOutput }, @@ -59,7 +58,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aDuration, Math.max(1, aEUt), 0); - GTPP_Recipe.GTPP_Recipe_Map.sCokeOvenRecipes.add(aSpecialRecipe); + GTPPRecipeMaps.cokeOvenRecipes.add(aSpecialRecipe); return true; } @@ -79,7 +78,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { @Override public boolean addCokeOvenRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack[] aFluidInputs, FluidStack[] aFluidOutputs, ItemStack[] aOutputs, int aDuration, int aEUt) { - GTPP_Recipe aSpecialRecipe = new GTPP_Recipe( + GT_Recipe aSpecialRecipe = new GT_Recipe( true, new ItemStack[] { aInput1, aInput2 }, aOutputs, @@ -90,7 +89,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { Math.max(1, aDuration), Math.max(1, aEUt), 0); - GTPP_Recipe.GTPP_Recipe_Map.sCokeOvenRecipes.add(aSpecialRecipe); + GTPPRecipeMaps.cokeOvenRecipes.add(aSpecialRecipe); return true; } @@ -101,7 +100,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { Logger.WARNING("Something was null, returning false"); return false; } - GTPP_Recipe aRecipe = new GTPP_Recipe( + GT_Recipe aRecipe = new GT_Recipe( false, new ItemStack[] {}, new ItemStack[] {}, @@ -112,7 +111,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aDuration, aEUt, 0); - GTPP_Recipe_Map.sMatterFab2Recipes.addRecipe(aRecipe); + GTPPRecipeMaps.multiblockMassFabricatorRecipes.addRecipe(aRecipe); return true; } @@ -125,7 +124,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { return false; } - GTPP_Recipe aSpecialRecipe = new GTPP_Recipe( + GT_Recipe aSpecialRecipe = new GT_Recipe( true, aInput, aOutputItems, @@ -136,7 +135,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { Math.max(1, aDuration), Math.max(1, aEUt), 0); - GTPP_Recipe.GTPP_Recipe_Map.sChemicalDehydratorRecipes.add(aSpecialRecipe); + GTPPRecipeMaps.chemicalDehydratorRecipes.add(aSpecialRecipe); return true; } @@ -293,7 +292,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { return false; } - GTPP_Recipe.GTPP_Recipe_Map.sAlloyBlastSmelterRecipes.addRecipe( + GTPPRecipeMaps.alloyBlastSmelterRecipes.addRecipe( aOptimizeRecipe, aInput, aOutputStack, @@ -323,7 +322,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aFluidOutput = new FluidStack[0]; } - GTPP_Recipe.GTPP_Recipe_Map.sQuantumForceTransformerRecipes.add( + GTPPRecipeMaps.quantumForceTransformerRecipes.add( new GT_Recipe( false, aInput, @@ -371,7 +370,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { final FluidStack[] inputs = { aInput1, aInput2, aInput3, aInput4, aInput5, aInput6, aInput7, aInput8, aInput9 }; final FluidStack[] outputs = { aOutput1, aOutput2 }; - GTPP_Recipe.GTPP_Recipe_Map.sFissionFuelProcessing.addRecipe( + GTPPRecipeMaps.fissionFuelProcessingRecipes.addRecipe( aOptimise, new ItemStack[] {}, new ItemStack[] {}, @@ -407,7 +406,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { return false; } - GTPP_Recipe aSpecialRecipe = new GTPP_Recipe( + GT_Recipe aSpecialRecipe = new GT_Recipe( true, aInputs, aOutput, @@ -418,7 +417,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { Math.max(1, aDuration), Math.max(1, aEUt), aSpecialValue); - GTPP_Recipe.GTPP_Recipe_Map.sCyclotronRecipes.add(aSpecialRecipe); + GTPPRecipeMaps.cyclotronRecipes.add(aSpecialRecipe); return true; } @@ -430,7 +429,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { return false; } - GTPP_Recipe aSpecialRecipe = new GTPP_Recipe( + GT_Recipe aSpecialRecipe = new GT_Recipe( true, new ItemStack[] { aInput1, aInput2, aInput3, aInput4 }, new ItemStack[] { aOutput1, aOutput2, aOutput3, aOutput4 }, @@ -441,7 +440,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { Math.max(1, aDuration), Math.max(1, aEUt), 0); - GT_Recipe_Map.sMixerRecipes.add(aSpecialRecipe); + RecipeMaps.mixerRecipes.add(aSpecialRecipe); return true; } @@ -463,7 +462,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { return false; } - GTPP_Recipe aRecipe = new GTPP_Recipe( + GT_Recipe aRecipe = new GT_Recipe( false, aInputs, aOutputs, @@ -474,7 +473,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aDuration, aEUtick, aSpecial); - GTPP_Recipe.GTPP_Recipe_Map.sMultiblockCentrifugeRecipes_GT.addRecipe(aRecipe); + GTPPRecipeMaps.centrifugeNonCellRecipes.addRecipe(aRecipe); return true; } @@ -495,7 +494,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { return false; } - GTPP_Recipe aRecipe = new GTPP_Recipe( + GT_Recipe aRecipe = new GT_Recipe( false, aInputs, aOutputs, @@ -506,7 +505,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aDuration, aEUtick, aSpecial); - GTPP_Recipe.GTPP_Recipe_Map.sMultiblockElectrolyzerRecipes_GT.addRecipe(aRecipe); + GTPPRecipeMaps.electrolyzerNonCellRecipes.addRecipe(aRecipe); return true; } @@ -527,7 +526,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { return false; } - GTPP_Recipe aRecipe = new GTPP_Recipe( + GT_Recipe aRecipe = new GT_Recipe( false, aInputs, aOutputs, @@ -538,7 +537,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aDuration, aEUtick, aSpecial); - GTPP_Recipe.GTPP_Recipe_Map.sAdvFreezerRecipes_GT.addRecipe(aRecipe); + GTPPRecipeMaps.advancedFreezerRecipes.addRecipe(aRecipe); return false; } @@ -557,7 +556,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { return false; } - GTPP_Recipe aRecipe = new GTPP_Recipe( + GT_Recipe aRecipe = new GT_Recipe( false, aInputs, aOutputs, @@ -568,7 +567,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aDuration, aEUtick, aSpecial); - GTPP_Recipe.GTPP_Recipe_Map.sMultiblockMixerRecipes_GT.addRecipe(aRecipe); + GTPPRecipeMaps.mixerNonCellRecipes.addRecipe(aRecipe); return true; } @@ -588,7 +587,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { return false; } - GTPP_Recipe aRecipe = new GTPP_Recipe( + GT_Recipe aRecipe = new GT_Recipe( false, aInputs, aOutputs, @@ -599,7 +598,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aDuration, aEUtick, aSpecial); - GTPP_Recipe.GTPP_Recipe_Map.sMultiblockChemicalDehydratorRecipes.addRecipe(aRecipe); + GTPPRecipeMaps.chemicalDehydratorNonCellRecipes.addRecipe(aRecipe); return true; } @@ -645,7 +644,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { if (aCircuit < 0 || aCircuit > 24) { aCircuit = 22; } - GT_Recipe aSpecialRecipe = new GTPP_Recipe( + GT_Recipe aSpecialRecipe = new GT_Recipe( false, new ItemStack[] { input1, input2 }, new ItemStack[] { output, output2 }, @@ -656,7 +655,8 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { time, eu, 0); - return GT_Recipe.GT_Recipe_Map.sChemicalRecipes.mRecipeList.add(aSpecialRecipe); + RecipeMaps.chemicalReactorRecipes.add(aSpecialRecipe); + return true; } @Override @@ -695,7 +695,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { if ((aDuration = GregTech_API.sRecipeFile.get("compressor", aInput1, aDuration)) <= 0) { return false; } - GT_Recipe.GT_Recipe_Map.sCompressorRecipes.addRecipe( + RecipeMaps.compressorRecipes.addRecipe( true, new ItemStack[] { aInput1 }, new ItemStack[] { aOutput1 }, @@ -723,7 +723,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { if (!GregTech_API.sRecipeFile.get("brewing", aOutput.getUnlocalizedName(), true)) { return false; } - GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sBrewingRecipes.addRecipe( + GT_Recipe tRecipe = RecipeMaps.brewingRecipes.addRecipe( false, new ItemStack[] { aIngredient }, null, @@ -813,7 +813,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { public boolean addVacuumFurnaceRecipe(ItemStack[] aInputs, FluidStack[] aFluidInputs, ItemStack[] aOutputs, FluidStack[] aFluidOutputs, int aDuration, int aEUt, int aLevel) { if (aInputs != null && aOutputs != null) { - GTPP_Recipe.GTPP_Recipe_Map.sVacuumFurnaceRecipes.addRecipe( + GTPPRecipeMaps.vacuumFurnaceRecipes.addRecipe( false, aInputs, aOutputs, @@ -833,7 +833,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { @Override public boolean addUvLaserRecipe(ItemStack aInput1, ItemStack aOutput, int time, long eu) { // Generate Special Laser Recipe - GT_Recipe u = new GTPP_Recipe( + GT_Recipe u = new GT_Recipe( false, new ItemStack[] { aInput1, GregtechItemList.Laser_Lens_WoodsGlass.get(0), }, new ItemStack[] { aOutput }, @@ -844,7 +844,8 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { time, (int) eu, 0); - return GT_Recipe.GT_Recipe_Map.sLaserEngraverRecipes.mRecipeList.add(u); + RecipeMaps.laserEngraverRecipes.add(u); + return true; } @Override @@ -864,7 +865,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { CORE.crash(); } - GTPP_Recipe.GTPP_Recipe_Map.sChemicalPlantRecipes.addRecipe( + GTPPRecipeMaps.chemicalPlantRecipes.addRecipe( false, aInputs, aOutputs, @@ -881,7 +882,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { @Override public boolean addBlastRecipe(ItemStack[] aInputs, FluidStack[] aInputFluids, ItemStack[] aOutputs, FluidStack[] aFluidOutputs, int time, long eu, int aHeat) { - GTPP_Recipe aSpecialRecipe = new GTPP_Recipe( + GT_Recipe aSpecialRecipe = new GT_Recipe( false, aInputs, aOutputs, @@ -893,7 +894,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { (int) eu, aHeat); - GT_Recipe.GT_Recipe_Map.sBlastRecipes.add(aSpecialRecipe); + RecipeMaps.blastFurnaceRecipes.add(aSpecialRecipe); return true; } @@ -911,7 +912,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { .get("distillery", aOutput.getFluid().getUnlocalizedName(), aDuration)) <= 0) { return false; } else { - GT_Recipe tRecipe = GT_Recipe_Map.sDistilleryRecipes.addRecipe( + GT_Recipe tRecipe = RecipeMaps.distilleryRecipes.addRecipe( true, new ItemStack[] { aCircuit }, new ItemStack[] { aSolidOutput }, @@ -939,7 +940,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { @Override public boolean addExtractorRecipe(ItemStack aInput, ItemStack aOutput, int aChance, int aDuration, int aEUt) { if (aInput != null && aOutput != null) { - GT_Recipe aRecipe = new GTPP_Recipe( + GT_Recipe aRecipe = new GT_Recipe( false, new ItemStack[] { aInput.copy() }, new ItemStack[] { aOutput.copy() }, @@ -950,7 +951,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aDuration, aEUt, 0); - GT_Recipe_Map.sExtractorRecipes.add(aRecipe); + RecipeMaps.extractorRecipes.add(aRecipe); return true; } else { return false; @@ -1026,7 +1027,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { int[] aTime = new int[] { 2400, 3000, 1200, 1500 }; for (int i = 0; i < 4; i++) { - GTPP_Recipe aOreRecipe = new GTPP_Recipe( + GT_Recipe aOreRecipe = new GT_Recipe( false, aInputArray[i], aOutputArray[i], @@ -1037,7 +1038,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aTime[i], aEU, 0); - GTPP_Recipe.GTPP_Recipe_Map.sOreMillRecipes.add(aOreRecipe); + GTPPRecipeMaps.millingRecipes.add(aOreRecipe); } return true; } @@ -1060,7 +1061,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { FlotationRecipeHandler.registerOreType(aMat); - GT_Recipe aRecipe = new GTPP_Recipe( + GT_Recipe aRecipe = new GT_Recipe( false, new ItemStack[] { ItemUtils.getSimpleStack(aXanthate, 32), aMat.getMilled(64), aMat.getMilled(64), aMat.getMilled(64), aMat.getMilled(64), }, @@ -1072,7 +1073,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aTime, aEU, 0); - GTPP_Recipe.GTPP_Recipe_Map.sFlotationCellRecipes.add(aRecipe); + GTPPRecipeMaps.flotationCellRecipes.add(aRecipe); return true; } @@ -1097,7 +1098,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { @Override public boolean addFuelForRTG(ItemStack aFuelPellet, int aFuelDays, int aVoltage) { - GTPP_Recipe.GTPP_Recipe_Map.sRTGFuels.addRecipe( + GTPPRecipeMaps.rtgFuels.addRecipe( true, new ItemStack[] { aFuelPellet }, new ItemStack[] {}, @@ -1113,7 +1114,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { @Override public boolean addColdTrapRecipe(int aCircuit, ItemStack aInput, FluidStack aFluidInput, ItemStack[] aOutputs, int[] aChances, FluidStack aFluidOutput, int aTime, int aEU) { - GTPP_Recipe aRecipe = new GTPP_Recipe( + GT_Recipe aRecipe = new GT_Recipe( false, new ItemStack[] { CI.getNumberedAdvancedCircuit(aCircuit), aInput }, aOutputs, @@ -1125,14 +1126,14 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aEU, 0); - GTPP_Recipe_Map.sColdTrapRecipes.add(aRecipe); + GTPPRecipeMaps.coldTrapRecipes.add(aRecipe); return true; } @Override public boolean addReactorProcessingUnitRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, ItemStack[] aOutputs, int[] aChances, FluidStack aFluidOutput, int aTime, int aEU) { - GTPP_Recipe aRecipe = new GTPP_Recipe( + GT_Recipe aRecipe = new GT_Recipe( false, new ItemStack[] { aInput1, aInput2 }, aOutputs, @@ -1144,7 +1145,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aEU, 0); - GTPP_Recipe_Map.sReactorProcessingUnitRecipes.add(aRecipe); + GTPPRecipeMaps.reactorProcessingUnitRecipes.add(aRecipe); return true; } @@ -1164,7 +1165,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { return false; } - GTPP_Recipe aRecipe = new GTPP_Recipe( + GT_Recipe aRecipe = new GT_Recipe( false, aInputs, aOutputs, @@ -1175,7 +1176,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aDuration, aEUtick, aSpecial); - GTPP_Recipe.GTPP_Recipe_Map.sNuclearSaltProcessingPlantRecipes.addRecipe(aRecipe); + GTPPRecipeMaps.nuclearSaltProcessingPlantRecipes.addRecipe(aRecipe); return true; } @@ -1185,7 +1186,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { if ((aInput == null && aFluidInput == null) || aOutput == null) { return false; } - GT_Recipe.GT_Recipe_Map.sFluidHeaterRecipes.addRecipe( + RecipeMaps.fluidHeaterRecipes.addRecipe( true, new ItemStack[] { aInput }, null, @@ -1203,7 +1204,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { if (aInput == null || aOutput == null) { return false; } - GTPP_Recipe aRecipe = new GTPP_Recipe( + GT_Recipe aRecipe = new GT_Recipe( false, new ItemStack[] { aInput }, new ItemStack[] { aOutput }, @@ -1215,7 +1216,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aEUt, 0); - GT_Recipe_Map.sVacuumRecipes.add(aRecipe); + RecipeMaps.vacuumFreezerRecipes.add(aRecipe); return true; } @@ -1224,7 +1225,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { if (aInput == null || aOutput == null) { return false; } - GTPP_Recipe aRecipe = new GTPP_Recipe( + GT_Recipe aRecipe = new GT_Recipe( false, new ItemStack[] { aInput }, new ItemStack[] { aOutput }, @@ -1236,7 +1237,7 @@ public class GregtechRecipeAdder implements IGregtech_RecipeAdder { aEUt, 0); - GTPP_Recipe_Map.sMolecularTransformerRecipes.add(aRecipe); + GTPPRecipeMaps.molecularTransformerRecipes.add(aRecipe); return true; } |
