From a8b46c11f5a02608101ef33ed39f103736ba5920 Mon Sep 17 00:00:00 2001 From: boubou19 Date: Sun, 21 Jul 2024 16:36:34 +0200 Subject: full RA1 removal (#2713) * remove addExtractionRecipes * remove addPulverisationRecipe * remove thermalcraft fake compat * deprecate addAlloySmelterRecipe * remove fake compat * remove RA1 fusion recipe usage * remove RA1 centrifuge recipe usage * remove RA1 compressor recipe usage * remove RA1 electrolyzer recipe usage * remove RA1 chemical reactor recipe usage * deprecate GT based recipes adders * obliterate RA1 entries in interfaces (1/?) * remove RA1 blast furnace recipe usage * remove RA1 canner recipe usage * remove RA1 alloy smelter recipe usage * remove RA1 circuit assembler recipe usage * obliterate RA1 entries in interfaces (2/?) * remove RA1 bender recipe usage * clean class * remove RA1 cutter recipe usage * remove RA1 fuels recipe usage * remove RA1 implosion compressor recipe usage * remove RA1 thermal centrifuge recipe usage * clean GT_ModHandler * obliterate RA1 entries in interfaces (3/?) * remove RA1 packager recipe usage * remove RA1 lathe recipe usage * remove RA1 vacuum freezer recipe usage * remove RA1 fluid heater recipe usage * remove RA1 nano forge recipe usage * remove RA1 autoclave recipe usage * obliterate RA1 entries in interfaces (4/?) * remove RA1 cracker recipe usage * remove RA1 pyrolyse recipe usage * remove RA1 pulveriser recipe usage * remove RA1 fluid extractor recipe usage * remove RA1 assembly line recipe usage * remove RA1 alloy blast smelter recipe usage * remove RA1 coke oven recipe usage * obliterate RA1 entries in interfaces (5/?) * remove RA1 dehydrator recipe usage * remove deprecated usages * obliterate RA1 entries in interfaces (6/?) * remove RA1 assembler recipe usage * obliterate RA1 entries in interfaces (7/?) * remove RA1 mixer recipe usage * remove RA1 forge hammer recipe usage * remove RA1 wiremill recipe usage * remove RA1 extruder recipe usage * remove RA1 fluid soldifier recipe usage * remove RA1 chemical bath recipe usage * remove RA1 electromagnetic separator recipe usage * remove RA1 sifter recipe usage * remove distillery recipe usage * remove distillation tower usage * remove extractor usage * obliterate RA1 entries in interfaces (8/?) * remove QFT usage * cleaning * remove packager usage * remove fluid heater usage * remove vacuum freezer usage * remove distillery usage * fix QFT chances arrays * remove fission fuel usage * remove cyclotron usage * remove molecular transformer usage * remove chemplant usage * remove coldtrap and reactor processing unit usage * obliterate RA1 entries in interfaces (9/?) * spotlessApply * fixes * remove addRecipe calls * migrate forge of gods recipes * yeet special value calls (1 / 2) * yeet special value calls (2 / 2) * migrate GG Fuel recipes * migrate all GG maps except EHE * CORE.RA is no more * clear GT_RecipeAdder * remove dead code * clean RecipeMap a bit * spotless apply * fix output chances * Update RecipeLoader.java * fix * remove buggy recipe * migrate to enum for IDs * sort enum * move to enum * fix recipes * spotless apply * fix recipe * remove useless recipes * spotless apply * remove unused blocks * fix GT++ recipe * Update RecipeLoader.java * Update RecipeLoader.java * fix imports * Spotless apply for branch remove_RA1_calls for #2713 (#2742) spotlessApply Co-authored-by: GitHub GTNH Actions <> * fix recipe (cherry picked from commit a25d3b62997f080e064369e940eaf53a96a300e6) * fix (cherry picked from commit d9af01140f3ee77de2be18be70f04f8fbe4b547f) * temporarily remove panic mode * fix recipes * Revert "temporarily remove panic mode" This reverts commit 483cfcf74371b91e7d545f058f9d25ff4fcec95a. * fix recipes --------- Co-authored-by: Dream Master Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- src/main/java/gregtech/common/GT_RecipeAdder.java | 3231 -------------------- .../common/items/GT_MetaGenerated_Item_01.java | 225 +- .../common/items/GT_MetaGenerated_Item_02.java | 207 +- 3 files changed, 298 insertions(+), 3365 deletions(-) (limited to 'src/main/java/gregtech/common') diff --git a/src/main/java/gregtech/common/GT_RecipeAdder.java b/src/main/java/gregtech/common/GT_RecipeAdder.java index f0225fd241..8f48ec19bf 100644 --- a/src/main/java/gregtech/common/GT_RecipeAdder.java +++ b/src/main/java/gregtech/common/GT_RecipeAdder.java @@ -1,3241 +1,10 @@ package gregtech.common; -import static gregtech.GT_Mod.GT_FML_LOGGER; -import static gregtech.api.enums.Mods.GTPlusPlus; -import static gregtech.api.enums.Mods.Railcraft; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Comparator; -import java.util.List; -import java.util.Objects; - -import net.minecraft.init.Blocks; -import net.minecraft.init.Items; -import net.minecraft.item.ItemStack; -import net.minecraftforge.fluids.Fluid; -import net.minecraftforge.fluids.FluidStack; -import net.minecraftforge.oredict.OreDictionary; - -import cpw.mods.fml.common.registry.GameRegistry; -import gregtech.GT_Mod; -import gregtech.api.enums.GT_Values; -import gregtech.api.enums.ItemList; -import gregtech.api.enums.Materials; -import gregtech.api.enums.OrePrefixes; import gregtech.api.interfaces.internal.IGT_RecipeAdder; -import gregtech.api.objects.ItemData; -import gregtech.api.recipe.RecipeMaps; -import gregtech.api.util.GT_AssemblyLineUtils; -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_AssemblyLine; import gregtech.api.util.GT_RecipeBuilder; -import gregtech.api.util.GT_RecipeConstants; -import gregtech.api.util.GT_Utility; -import gregtech.api.util.extensions.ArrayExt; -import ic2.core.init.MainConfig; -import ic2.core.util.ConfigUtil; -import mods.railcraft.common.blocks.aesthetics.cube.EnumCube; -import mods.railcraft.common.items.RailcraftToolItems; public class GT_RecipeAdder implements IGT_RecipeAdder { - @Override - @Deprecated - public boolean addFusionReactorRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, int aDuration, - int aEUt, int aStartEU) { - return false; - } - - @Deprecated - @Override // Really? - public boolean addFusionReactorRecipe(FluidStack aInput1, FluidStack aInput2, FluidStack aOutput1, int aDuration, - int aEUt, int aStartEU) { - if (aInput1 == null || aInput2 == null || aOutput1 == null || aDuration < 1 || aEUt < 1 || aStartEU < 1) { - return false; - } - RecipeMaps.fusionRecipes.addRecipe( - null, - new FluidStack[] { aInput1, aInput2 }, - new FluidStack[] { aOutput1 }, - aDuration, - aEUt, - aStartEU); - return true; - } - - @Deprecated - @Override - public boolean addFusionReactorRecipe(FluidStack[] FluidInputArray, FluidStack[] FluidOutputArray, - int aFusionDurationInTicks, int aFusionEnergyPerTick, int aEnergyNeededForStartingFusion) { - if (FluidInputArray.length == 0) return false; - - if (FluidOutputArray.length == 0) return false; - - RecipeMaps.fusionRecipes.addRecipe( - null, - FluidInputArray, - FluidOutputArray, - aFusionDurationInTicks, - aFusionEnergyPerTick, - aEnergyNeededForStartingFusion); - return true; - } - - @Deprecated - @Override - public boolean addCentrifugeRecipe(ItemStack aInput1, int aInput2, ItemStack aOutput1, ItemStack aOutput2, - ItemStack aOutput3, ItemStack aOutput4, ItemStack aOutput5, ItemStack aOutput6, int aDuration) { - return addCentrifugeRecipe( - aInput1, - aInput2 < 0 ? null : aInput2 > 0 ? ItemList.Cell_Empty.get(aInput2) : null, - null, - null, - aOutput1, - aOutput2, - aOutput3, - aOutput4, - aOutput5, - aOutput6, - null, - aDuration, - 5); - } - - @Deprecated - @Override - public boolean addCentrifugeRecipe(ItemStack aInput1, int aInput2, ItemStack aOutput1, ItemStack aOutput2, - ItemStack aOutput3, ItemStack aOutput4, ItemStack aOutput5, ItemStack aOutput6, int aDuration, int aEUt) { - return addCentrifugeRecipe( - aInput1, - aInput2 < 0 ? null : aInput2 > 0 ? ItemList.Cell_Empty.get(aInput2) : null, - null, - null, - aOutput1, - aOutput2, - aOutput3, - aOutput4, - aOutput5, - aOutput6, - null, - aDuration, - aEUt); - } - - @Deprecated - @Override - public boolean addCentrifugeRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, - FluidStack aFluidOutput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3, ItemStack aOutput4, - ItemStack aOutput5, ItemStack aOutput6, int[] aChances, int aDuration, int aEUt) { - return addCentrifugeRecipe( - aInput1, - aInput2, - aFluidInput, - aFluidOutput, - aOutput1, - aOutput2, - aOutput3, - aOutput4, - aOutput5, - aOutput6, - aChances, - aDuration, - aEUt, - false); - } - - @Deprecated - @Override - public boolean addCentrifugeRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, - FluidStack aFluidOutput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3, ItemStack aOutput4, - ItemStack aOutput5, ItemStack aOutput6, int[] aChances, int aDuration, int aEUt, boolean aCleanroom) { - if (((aInput1 == null) && (aFluidInput == null)) || ((aOutput1 == null) && (aFluidOutput == null))) { - return false; - } - if ((aInput1 != null) && (aDuration <= 0)) { - return false; - } - if ((aFluidInput != null) && (aDuration <= 0)) { - return false; - } - if (!GT_Mod.gregtechproxy.mEnableCleanroom) { - aCleanroom = false; - } - RecipeMaps.centrifugeRecipes.addRecipe( - true, - new ItemStack[] { aInput1, aInput2 }, - new ItemStack[] { aOutput1, aOutput2, aOutput3, aOutput4, aOutput5, aOutput6, }, - null, - aChances, - new FluidStack[] { aFluidInput }, - new FluidStack[] { aFluidOutput }, - aDuration, - aEUt, - aCleanroom ? -100 : 0); - ItemStack[] itemInputs = { aInput1, aInput2 }; - ItemStack[] itemOutputs = { aOutput1, aOutput2, aOutput3, aOutput4, aOutput5, aOutput6 }; - FluidStack[] fluidInputs = { aFluidInput, null, null }; - FluidStack[] fluidOutputs = { aFluidOutput, null, null, null, null, null, null }; - - byte iNumber = 0; - byte oNumber = 0; - - for (ItemStack item : itemInputs) { - if (item != null) { - if (GT_Utility.getFluidForFilledItem(aInput1, true) != null || GT_Utility.isCellEmpty(item)) { - fluidInputs[iNumber + 1] = GT_Utility.convertCellToFluid(item); - itemInputs[iNumber] = null; - } - } - iNumber++; - } - - for (ItemStack item : itemOutputs) { - if (item != null) { - if (GT_Utility.getFluidForFilledItem(item, true) != null || GT_Utility.isCellEmpty(item)) { - fluidOutputs[oNumber + 1] = GT_Utility.convertCellToFluid(item); - itemOutputs[oNumber] = null; - } - } - oNumber++; - } - - RecipeMaps.centrifugeNonCellRecipes.addRecipe( - false, - itemInputs, - itemOutputs, - null, - aChances, - fluidInputs, - fluidOutputs, - aDuration, - aEUt, - aCleanroom ? -100 : 0); - return true; - } - - @Deprecated - @Override - public boolean addCompressorRecipe(ItemStack aInput1, ItemStack aOutput1, int aDuration, int aEUt) { - if ((aInput1 == null) || (aOutput1 == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.compressorRecipes.addRecipe( - true, - new ItemStack[] { aInput1 }, - new ItemStack[] { aOutput1 }, - null, - null, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Deprecated - @Override - public boolean addElectrolyzerRecipe(ItemStack aInput1, int aInput2, ItemStack aOutput1, ItemStack aOutput2, - ItemStack aOutput3, ItemStack aOutput4, ItemStack aOutput5, ItemStack aOutput6, int aDuration, int aEUt) { - return addElectrolyzerRecipe( - aInput1, - aInput2 < 0 ? null : aInput2 > 0 ? ItemList.Cell_Empty.get(aInput2) : null, - null, - null, - aOutput1, - aOutput2, - aOutput3, - aOutput4, - aOutput5, - aOutput6, - null, - aDuration, - aEUt); - } - - @Deprecated - @Override - public boolean addElectrolyzerRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, - FluidStack aFluidOutput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3, ItemStack aOutput4, - ItemStack aOutput5, ItemStack aOutput6, int[] aChances, int aDuration, int aEUt) { - if (((aInput1 == null) && (aFluidInput == null)) || ((aOutput1 == null) && (aFluidOutput == null))) { - return false; - } - if ((aInput1 != null) && (aDuration <= 0)) { - return false; - } - if ((aFluidInput != null) && (aDuration <= 0)) { - return false; - } - RecipeMaps.electrolyzerRecipes.addRecipe( - true, - new ItemStack[] { aInput1, aInput2 }, - new ItemStack[] { aOutput1, aOutput2, aOutput3, aOutput4, aOutput5, aOutput6 }, - null, - aChances, - new FluidStack[] { aFluidInput }, - new FluidStack[] { aFluidOutput }, - aDuration, - aEUt, - 0); - ItemStack[] itemInputs = { aInput1, aInput2 }; - ItemStack[] itemOutputs = { aOutput1, aOutput2, aOutput3, aOutput4, aOutput5, aOutput6 }; - FluidStack[] fluidInputs = { aFluidInput, null, null }; - FluidStack[] fluidOutputs = { aFluidOutput, null, null, null, null, null, null }; - - byte iNumber = 0; - byte oNumber = 0; - - for (ItemStack item : itemInputs) { - if (item != null) { - if (GT_Utility.getFluidForFilledItem(item, true) != null || GT_Utility.isCellEmpty(item) - || GT_Utility.isAnyIntegratedCircuit(item)) { - fluidInputs[iNumber + 1] = GT_Utility.convertCellToFluid(item); - itemInputs[iNumber] = null; - } - } - iNumber++; - } - - for (ItemStack item : itemOutputs) { - if (item != null) { - if (GT_Utility.getFluidForFilledItem(item, true) != null || GT_Utility.isCellEmpty(item)) { - fluidOutputs[oNumber + 1] = GT_Utility.convertCellToFluid(item); - itemOutputs[oNumber] = null; - } - } - oNumber++; - } - - RecipeMaps.electrolyzerNonCellRecipes - .addRecipe(false, itemInputs, itemOutputs, null, aChances, fluidInputs, fluidOutputs, aDuration, aEUt, 0); - return true; - } - - @Deprecated - @Override - public boolean addChemicalRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput, int aDuration) { - return addChemicalRecipe(aInput1, aInput2, null, null, aOutput, aDuration); - } - - @Deprecated - @Override - public boolean addChemicalRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput, int aDuration, int aEUt) { - return addChemicalRecipe(aInput1, aInput2, null, null, aOutput, aDuration, aEUt); - } - - @Deprecated - @Override - public boolean addChemicalRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, - FluidStack aFluidOutput, ItemStack aOutput, int aDuration) { - return addChemicalRecipe(aInput1, aInput2, aFluidInput, aFluidOutput, aOutput, aDuration, 30); - } - - @Deprecated - @Override - public boolean addChemicalRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, - FluidStack aFluidOutput, ItemStack aOutput, ItemStack aOutput2, int aDuration) { - return addChemicalRecipe(aInput1, aInput2, aFluidInput, aFluidOutput, aOutput, aOutput2, aDuration, 30); - } - - @Deprecated - @Override - public boolean addChemicalRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, - FluidStack aFluidOutput, ItemStack aOutput, int aDuration, int aEUTick) { - return addChemicalRecipe( - aInput1, - aInput2, - aFluidInput, - aFluidOutput, - aOutput, - GT_Values.NI, - aDuration, - aEUTick); - } - - @Deprecated - @Override - public boolean addChemicalRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, - FluidStack aFluidOutput, ItemStack aOutput, ItemStack aOutput2, int aDuration, int aEUtick) { - return addChemicalRecipe( - aInput1, - aInput2, - aFluidInput, - aFluidOutput, - aOutput, - aOutput2, - aDuration, - aEUtick, - false); - } - - @Deprecated - @Override - public boolean addChemicalRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, - FluidStack aFluidOutput, ItemStack aOutput, ItemStack aOutput2, int aDuration, int aEUtick, - boolean aCleanroom) { - if (((aInput1 == null) && (aFluidInput == null)) - || ((aOutput == null) && (aOutput2 == null) && (aFluidOutput == null))) { - return false; - } - if ((aOutput != null || aOutput2 != null) && (aDuration <= 0)) { - return false; - } - if ((aFluidOutput != null) && (aDuration <= 0)) { - return false; - } - if (aEUtick <= 0) { - return false; - } - if (!GT_Mod.gregtechproxy.mEnableCleanroom) { - aCleanroom = false; - } - GT_RecipeBuilder builder = stdBuilder() - .itemInputs(ArrayExt.withoutNulls(new ItemStack[] { aInput1, aInput2 }, ItemStack[]::new)) - .itemOutputs(ArrayExt.withoutNulls(new ItemStack[] { aOutput, aOutput2 }, ItemStack[]::new)); - if (aFluidInput != null) builder.fluidInputs(aFluidInput); - if (aFluidOutput != null) builder.fluidOutputs(aFluidOutput); - builder.duration(aDuration) - .eut(aEUtick) - .metadata(GT_RecipeConstants.CLEANROOM, aCleanroom) - .addTo(GT_RecipeConstants.UniversalChemical); - return true; - } - - @Deprecated - @Override - public boolean addMultiblockChemicalRecipe(ItemStack[] aInputs, FluidStack[] aFluidInputs, - FluidStack[] aFluidOutputs, ItemStack[] aOutputs, int aDuration, int aEUtick) { - if (areItemsAndFluidsBothNull(aInputs, aFluidInputs) || areItemsAndFluidsBothNull(aOutputs, aFluidOutputs)) { - return false; - } - if (aEUtick <= 0) { - return false; - } - RecipeMaps.multiblockChemicalReactorRecipes - .addRecipe(false, aInputs, aOutputs, null, null, aFluidInputs, aFluidOutputs, aDuration, aEUtick, 0); - return true; - } - - @Deprecated - @Override - public boolean addChemicalRecipeForBasicMachineOnly(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, - FluidStack aFluidOutput, ItemStack aOutput, ItemStack aOutput2, int aDuration, int aEUtick) { - if (((aInput1 == null) && (aFluidInput == null)) - || ((aOutput == null) && (aOutput2 == null) && (aFluidOutput == null))) { - return false; - } - if ((aOutput != null || aOutput2 != null) && (aDuration <= 0)) { - return false; - } - if ((aFluidOutput != null) && (aDuration <= 0)) { - return false; - } - if (aEUtick <= 0) { - return false; - } - RecipeMaps.chemicalReactorRecipes.addRecipe( - true, - new ItemStack[] { aInput1, aInput2 }, - new ItemStack[] { aOutput, aOutput2 }, - null, - null, - new FluidStack[] { aFluidInput }, - new FluidStack[] { aFluidOutput }, - aDuration, - aEUtick, - 0); - return true; - } - - @Deprecated - @Override - public void addDefaultPolymerizationRecipes(Fluid aBasicMaterial, ItemStack aBasicMaterialCell, Fluid aPolymer) { - // Oxygen/Titaniumtetrafluoride -> +50% Output each - addChemicalRecipe( - ItemList.Cell_Air.get(1), - GT_Utility.getIntegratedCircuit(1), - new FluidStack(aBasicMaterial, 144), - new FluidStack(aPolymer, 144), - Materials.Empty.getCells(1), - 160); - addChemicalRecipe( - Materials.Oxygen.getCells(1), - GT_Utility.getIntegratedCircuit(1), - new FluidStack(aBasicMaterial, 144), - new FluidStack(aPolymer, 216), - Materials.Empty.getCells(1), - 160); - addChemicalRecipe( - aBasicMaterialCell, - GT_Utility.getIntegratedCircuit(1), - Materials.Air.getGas(14000), - new FluidStack(aPolymer, 1000), - Materials.Empty.getCells(1), - 1120); - addChemicalRecipe( - aBasicMaterialCell, - GT_Utility.getIntegratedCircuit(1), - Materials.Oxygen.getGas(7000), - new FluidStack(aPolymer, 1500), - Materials.Empty.getCells(1), - 1120); - addMultiblockChemicalRecipe( - new ItemStack[] { GT_Utility.getIntegratedCircuit(2) }, - new FluidStack[] { new FluidStack(aBasicMaterial, 2160), Materials.Air.getGas(7500), - Materials.Titaniumtetrachloride.getFluid(100) }, - new FluidStack[] { new FluidStack(aPolymer, 3240) }, - null, - 800, - 30); - addMultiblockChemicalRecipe( - new ItemStack[] { GT_Utility.getIntegratedCircuit(2) }, - new FluidStack[] { new FluidStack(aBasicMaterial, 2160), Materials.Oxygen.getGas(7500), - Materials.Titaniumtetrachloride.getFluid(100) }, - new FluidStack[] { new FluidStack(aPolymer, 4320) }, - null, - 800, - 30); - } - - @Deprecated - @Override - public boolean addBlastRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, ItemStack aOutput2, - int aDuration, int aEUt, int aLevel) { - return addBlastRecipe(aInput1, aInput2, null, null, aOutput1, aOutput2, aDuration, aEUt, aLevel); - } - - @Override - @Deprecated - public boolean addBlastRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, FluidStack aFluidOutput, - ItemStack aOutput1, ItemStack aOutput2, int aDuration, int aEUt, int aLevel) { - if ((aInput1 == null) || (aOutput1 == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.blastFurnaceRecipes.addRecipe( - true, - new ItemStack[] { aInput1, aInput2 }, - new ItemStack[] { aOutput1, aOutput2 }, - null, - null, - new FluidStack[] { aFluidInput }, - new FluidStack[] { aFluidOutput }, - aDuration, - aEUt, - aLevel); - return true; - } - - @Deprecated - public boolean addBlastRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aInput3, ItemStack aInput4, - FluidStack aFluidInput, FluidStack aFluidOutput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3, - ItemStack aOutput4, int aDuration, int aEUt, int aLevel) { - if ((aInput1 == null) || (aOutput1 == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.blastFurnaceRecipes.addRecipe( - true, - new ItemStack[] { aInput1, aInput2, aInput3, aInput4 }, - new ItemStack[] { aOutput1, aOutput2, aOutput3, aOutput4 }, - null, - null, - new FluidStack[] { aFluidInput }, - new FluidStack[] { aFluidOutput }, - aDuration, - aEUt, - aLevel); - return true; - } - - @Deprecated - @Override - public boolean addPlasmaForgeRecipe(ItemStack[] ItemInputArray, FluidStack[] FluidInputArray, - ItemStack[] OutputItemArray, FluidStack[] FluidOutputArray, int aDuration, int aEUt, int coil_heat_level) { - RecipeMaps.plasmaForgeRecipes.addRecipe( - false, - ItemInputArray, - OutputItemArray, - null, - null, - FluidInputArray, - FluidOutputArray, - aDuration, - aEUt, - coil_heat_level); - return true; - } - - @Override - @Deprecated - public boolean addPrimitiveBlastRecipe(ItemStack aInput1, ItemStack aInput2, int aCoalAmount, ItemStack aOutput1, - ItemStack aOutput2, int aDuration) { - if ((aInput1 == null && aInput2 == null) || (aOutput1 == null && aOutput2 == null)) { - return false; - } - if (aCoalAmount <= 0) { - return false; - } - if (aDuration <= 0) { - return false; - } - Materials[] coals = new Materials[] { Materials.Coal, Materials.Charcoal }; - for (Materials coal : coals) { - RecipeMaps.primitiveBlastRecipes.addRecipe( - true, - new ItemStack[] { aInput1, aInput2, coal.getGems(aCoalAmount) }, - new ItemStack[] { aOutput1, aOutput2, Materials.DarkAsh.getDustTiny(aCoalAmount) }, - null, - null, - null, - null, - aDuration, - 0, - 0); - RecipeMaps.primitiveBlastRecipes.addRecipe( - true, - new ItemStack[] { aInput1, aInput2, coal.getDust(aCoalAmount) }, - new ItemStack[] { aOutput1, aOutput2, Materials.DarkAsh.getDustTiny(aCoalAmount) }, - null, - null, - null, - null, - aDuration, - 0, - 0); - } - if (Railcraft.isModLoaded()) { - RecipeMaps.primitiveBlastRecipes.addRecipe( - true, - new ItemStack[] { aInput1, aInput2, RailcraftToolItems.getCoalCoke(aCoalAmount / 2) }, - new ItemStack[] { aOutput1, aOutput2, Materials.Ash.getDustTiny(aCoalAmount / 2) }, - null, - null, - null, - null, - aDuration * 2 / 3, - 0, - 0); - } - RecipeMaps.primitiveBlastRecipes.addRecipe( - true, - new ItemStack[] { aInput1, aInput2, - GT_ModHandler.getModItem(GTPlusPlus.ID, "itemCactusCoke", (aCoalAmount * 2L)) }, - new ItemStack[] { aOutput1, aOutput2, Materials.Ash.getDustTiny(aCoalAmount * 2) }, - null, - null, - null, - null, - aDuration * 2 / 3, - 0, - 0); - RecipeMaps.primitiveBlastRecipes.addRecipe( - true, - new ItemStack[] { aInput1, aInput2, - GT_ModHandler.getModItem(GTPlusPlus.ID, "itemSugarCoke", (aCoalAmount * 2L)) }, - new ItemStack[] { aOutput1, aOutput2, Materials.Ash.getDustTiny(aCoalAmount * 2) }, - null, - null, - null, - null, - aDuration * 2 / 3, - 0, - 0); - if ((aInput1 == null || aInput1.stackSize <= 6) && (aInput2 == null || aInput2.stackSize <= 6) - && (aOutput1 == null || aOutput1.stackSize <= 6) - && (aOutput2 == null || aOutput2.stackSize <= 6)) { - aInput1 = aInput1 == null ? null : GT_Utility.copyAmount(aInput1.stackSize * 10, aInput1); - aInput2 = aInput2 == null ? null : GT_Utility.copyAmount(aInput2.stackSize * 10, aInput2); - aOutput1 = aOutput1 == null ? null : GT_Utility.copyAmount(aOutput1.stackSize * 10, aOutput1); - aOutput2 = aOutput2 == null ? null : GT_Utility.copyAmount(aOutput2.stackSize * 10, aOutput2); - for (Materials coal : coals) { - RecipeMaps.primitiveBlastRecipes.addRecipe( - true, - new ItemStack[] { aInput1, aInput2, coal.getBlocks(aCoalAmount) }, - new ItemStack[] { aOutput1, aOutput2, Materials.DarkAsh.getDust(aCoalAmount) }, - null, - null, - null, - null, - aDuration * 10, - 0, - 0); - RecipeMaps.primitiveBlastRecipes.addRecipe( - true, - new ItemStack[] { aInput1, aInput2, coal.getBlocks(aCoalAmount) }, - new ItemStack[] { aOutput1, aOutput2, Materials.DarkAsh.getDust(aCoalAmount) }, - null, - null, - null, - null, - aDuration * 10, - 0, - 0); - } - if (Railcraft.isModLoaded()) { - RecipeMaps.primitiveBlastRecipes.addRecipe( - true, - new ItemStack[] { aInput1, aInput2, EnumCube.COKE_BLOCK.getItem(aCoalAmount / 2) }, - new ItemStack[] { aOutput1, aOutput2, Materials.Ash.getDust(aCoalAmount / 2) }, - null, - null, - null, - null, - aDuration * 20 / 3, - 0, - 0); - } - } - return true; - } - - @Override - @Deprecated - public boolean addCannerRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, ItemStack aOutput2, - int aDuration, int aEUt) { - if ((aInput1 == null) || (aOutput1 == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.cannerRecipes.addRecipe( - true, - aInput2 == null ? new ItemStack[] { aInput1 } : new ItemStack[] { aInput1, aInput2 }, - new ItemStack[] { aOutput1, aOutput2 }, - null, - null, - null, - null, - aDuration, - Math.max(aEUt, 1), - 0); - return true; - } - - @Override - @Deprecated - public boolean addAlloySmelterRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, int aDuration, - int aEUt) { - return addAlloySmelterRecipe(aInput1, aInput2, aOutput1, aDuration, aEUt, false); - } - - @Override - @Deprecated - public boolean addAlloySmelterRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, int aDuration, - int aEUt, boolean hidden) { - if ((aInput1 == null) || (aOutput1 == null || Materials.Graphite.contains(aInput1))) { - return false; - } - if ((aInput2 == null) && ((OrePrefixes.ingot.contains(aInput1)) || (OrePrefixes.dust.contains(aInput1)) - || (OrePrefixes.gem.contains(aInput1)))) { - return false; - } - if (aDuration <= 0) { - return false; - } - GT_Recipe tRecipe = new GT_Recipe( - true, - aInput2 == null ? new ItemStack[] { aInput1 } : new ItemStack[] { aInput1, aInput2 }, - new ItemStack[] { aOutput1 }, - null, - null, - null, - null, - aDuration, - Math.max(aEUt, 1), - 0); - if (hidden) { - tRecipe.mHidden = true; - } - RecipeMaps.alloySmelterRecipes.addRecipe(tRecipe); - return true; - } - - @Override - @Deprecated - public boolean addLatheRecipe(ItemStack aInput1, ItemStack aOutput1, ItemStack aOutput2, int aDuration, int aEUt) { - if ((aInput1 == null) || (aOutput1 == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.latheRecipes.addRecipe( - true, - new ItemStack[] { aInput1 }, - new ItemStack[] { aOutput1, aOutput2 }, - null, - null, - null, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Override - @Deprecated - public boolean addCutterRecipe(ItemStack aInput, FluidStack aLubricant, ItemStack aOutput1, ItemStack aOutput2, - int aDuration, int aEUt) { - if ((aInput == null) || (aLubricant == null) || (aOutput1 == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.cutterRecipes.addRecipe( - true, - new ItemStack[] { aInput }, - new ItemStack[] { aOutput1, aOutput2 }, - null, - new FluidStack[] { aLubricant }, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Override - @Deprecated - public boolean addCutterRecipe(ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2, int aDuration, int aEUt, - boolean aCleanroom) { - return addCutterRecipe(aInput, null, aOutput1, aOutput2, aDuration, aEUt, aCleanroom); - } - - @Deprecated - public boolean addCutterRecipe(ItemStack aInput, int aCircuit, ItemStack aOutput1, ItemStack aOutput2, - int aDuration, int aEUt) { - return addCutterRecipe(aInput, aCircuit, aOutput1, aOutput2, aDuration, aEUt, false); - } - - @Deprecated - public boolean addCutterRecipe(ItemStack aInput, int aCircuit, ItemStack aOutput1, ItemStack aOutput2, - int aDuration, int aEUt, boolean aCleanroom) { - return addCutterRecipe( - aInput, - GT_Utility.getIntegratedCircuit(aCircuit), - aOutput1, - aOutput2, - aDuration, - aEUt, - aCleanroom); - } - - @Override - @Deprecated - public boolean addCutterRecipe(ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2, int aDuration, int aEUt) { - return addCutterRecipe(aInput, aOutput1, aOutput2, aDuration, aEUt, false); - } - - @Override - @Deprecated - public boolean addCutterRecipe(ItemStack aInput, ItemStack aCircuit, ItemStack aOutput1, ItemStack aOutput2, - int aDuration, int aEUt) { - return addCutterRecipe(aInput, aCircuit, aOutput1, aOutput2, aDuration, aEUt, false); - } - - @Override - @Deprecated - public boolean addCutterRecipe(ItemStack aInput, ItemStack aCircuit, ItemStack aOutput1, ItemStack aOutput2, - int aDuration, int aEUt, boolean aCleanroom) { - return addCutterRecipe( - new ItemStack[] { aInput, aCircuit }, - new ItemStack[] { aOutput1, aOutput2 }, - aDuration, - aEUt, - aCleanroom ? -200 : 0); - } - - @Deprecated - public boolean addCutterRecipe(ItemStack[] aInputs, ItemStack[] aOutputs, int aDuration, int aEUt, - boolean aCleanroom) { - return addCutterRecipe(aInputs, aOutputs, aDuration, aEUt, aCleanroom ? -200 : 0); - } - - @Override - @Deprecated - public boolean addCutterRecipe(ItemStack[] aInputs, ItemStack[] aOutputs, int aDuration, int aEUt, int aSpecial) { - if ((aInputs == null) || (aOutputs == null) || aInputs.length == 0 || aOutputs.length == 0) { - return false; - } - if (Arrays.stream(aOutputs) - .noneMatch(Objects::nonNull)) { - return false; - } - if (aDuration <= 0) { - return false; - } - if (!GT_Mod.gregtechproxy.mEnableCleanroom && aSpecial == -200) { - aSpecial = 0; - } - RecipeMaps.cutterRecipes.addRecipe( - true, - aInputs, - aOutputs, - null, - new FluidStack[] { Materials.Water.getFluid(Math.max(4, Math.min(1000, aDuration * aEUt / 320))) }, - null, - aDuration * 2, - aEUt, - aSpecial); - RecipeMaps.cutterRecipes.addRecipe( - true, - aInputs, - aOutputs, - null, - new FluidStack[] { GT_ModHandler.getDistilledWater(Math.max(3, Math.min(750, aDuration * aEUt / 426))) }, - null, - aDuration * 2, - aEUt, - aSpecial); - RecipeMaps.cutterRecipes.addRecipe( - true, - aInputs, - aOutputs, - null, - new FluidStack[] { Materials.Lubricant.getFluid(Math.max(1, Math.min(250, aDuration * aEUt / 1280))) }, - null, - aDuration, - aEUt, - aSpecial); - return true; - } - - @Override - @Deprecated - public boolean addAssemblerRecipe(ItemStack aInput1, Object aOreDict, int aAmount, FluidStack aFluidInput, - ItemStack aOutput1, int aDuration, int aEUt) { - for (ItemStack tStack : GT_OreDictUnificator.getOresImmutable(aOreDict)) { - if (GT_Utility.isStackValid(tStack)) addAssemblerRecipe( - aInput1, - GT_Utility.copyAmount(aAmount, tStack), - aFluidInput, - aOutput1, - aDuration, - aEUt); - } - return true; - } - - @Override - @Deprecated - public boolean addAssemblerRecipe(ItemStack[] aInputs, Object aOreDict, int aAmount, FluidStack aFluidInput, - ItemStack aOutput1, int aDuration, int aEUt) { - for (ItemStack tStack : GT_OreDictUnificator.getOresImmutable(aOreDict)) { - if (GT_Utility.isStackValid(tStack)) { - ItemStack[] extendedInputs = new ItemStack[aInputs.length + 1]; - System.arraycopy(aInputs, 0, extendedInputs, 0, aInputs.length); - extendedInputs[aInputs.length] = GT_Utility.copyAmount(aAmount, tStack); - addAssemblerRecipe(extendedInputs, aFluidInput, aOutput1, aDuration, aEUt); - } - } - return true; - } - - @Override - @Deprecated - public boolean addAssemblerRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, int aDuration, - int aEUt) { - return addAssemblerRecipe( - new ItemStack[] { aInput1, aInput2 == null ? aInput1 : aInput2 }, - null, - aOutput1, - aDuration, - aEUt, - false); - } - - @Override - @Deprecated - public boolean addAssemblerRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, ItemStack aOutput1, - int aDuration, int aEUt) { - return addAssemblerRecipe(new ItemStack[] { aInput1, aInput2 }, aFluidInput, aOutput1, aDuration, aEUt); - } - - @Override - @Deprecated - public boolean addAssemblerRecipe(ItemStack[] aInputs, FluidStack aFluidInput, ItemStack aOutput1, int aDuration, - int aEUt) { - return addAssemblerRecipe(aInputs, aFluidInput, aOutput1, aDuration, aEUt, false); - } - - @Override - @Deprecated - public boolean addAssemblerRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, ItemStack aOutput1, - int aDuration, int aEUt, boolean aCleanroom) { - if (aInput2 == null) - return addAssemblerRecipe(new ItemStack[] { aInput1 }, aFluidInput, aOutput1, aDuration, aEUt, aCleanroom); - return addAssemblerRecipe( - new ItemStack[] { aInput1, aInput2 }, - aFluidInput, - aOutput1, - aDuration, - aEUt, - aCleanroom); - } - - @Override - @Deprecated - public boolean addAssemblerRecipe(ItemStack[] aInputs, FluidStack aFluidInput, ItemStack aOutput1, int aDuration, - int aEUt, boolean aCleanroom) { - - if (areItemsAndFluidsBothNull(aInputs, new FluidStack[] { aFluidInput })) { - return false; - } - - if (aDuration <= 0) { - return false; - } - - if (!GT_Mod.gregtechproxy.mEnableCleanroom) { - aCleanroom = false; - } - - if (!GT_Utility.isStackValid(aOutput1)) { - return false; - } - - for (int oreID : OreDictionary.getOreIDs(aOutput1)) { - if (OreDictionary.getOreName(oreID) - .startsWith("circuit")) { - return this.addAssemblerRecipeNonOD(aInputs, aFluidInput, aOutput1, aDuration, aEUt, aCleanroom); - } - } - - for (ItemStack aInput : aInputs) { - if (!GT_Utility.isStackValid(aInput)) { - GT_FML_LOGGER.debug("GT_RecipeAdder: Invalid input for (" + aOutput1 + ")"); - } - } - - RecipeMaps.assemblerRecipes.addRecipe( - true, - aInputs, - new ItemStack[] { aOutput1 }, - null, - new FluidStack[] { aFluidInput }, - null, - aDuration, - aEUt, - aCleanroom ? -200 : 0); - - return true; - } - - @Deprecated - public boolean addAssemblerRecipeNonOD(ItemStack[] aInputs, FluidStack aFluidInput, ItemStack aOutput1, - int aDuration, int aEUt, boolean aCleanroom) { - if (areItemsAndFluidsBothNull(aInputs, new FluidStack[] { aFluidInput })) { - return false; - } - - if (aDuration <= 0) { - return false; - } - - if (!GT_Mod.gregtechproxy.mEnableCleanroom) { - aCleanroom = false; - } - - if (!GT_Utility.isStackValid(aOutput1)) { - return false; - } - - RecipeMaps.assemblerRecipes.addRecipe( - true, - aInputs, - new ItemStack[] { aOutput1 }, - null, - new FluidStack[] { aFluidInput }, - null, - aDuration, - aEUt, - aCleanroom ? -200 : 0); - return true; - } - - @Override - @Deprecated - public boolean addWiremillRecipe(ItemStack aInput, ItemStack aOutput, int aDuration, int aEUt) { - if ((aInput == null) || (aOutput == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.wiremillRecipes.addRecipe( - true, - new ItemStack[] { aInput }, - new ItemStack[] { aOutput }, - null, - null, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Override - @Deprecated - public boolean addWiremillRecipe(ItemStack aInput, ItemStack aCircuit, ItemStack aOutput, int aDuration, int aEUt) { - if ((aInput == null) || (aOutput == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.wiremillRecipes.addRecipe( - true, - new ItemStack[] { aInput, aCircuit }, - new ItemStack[] { aOutput }, - null, - null, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Override - @Deprecated - public boolean addPolarizerRecipe(ItemStack aInput, ItemStack aOutput, int aDuration, int aEUt) { - if ((aInput == null) || (aOutput == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.polarizerRecipes.addRecipe( - true, - new ItemStack[] { aInput }, - new ItemStack[] { aOutput }, - null, - null, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Deprecated - @Override - public boolean addBenderRecipe(ItemStack aInput1, ItemStack aOutput1, int aDuration, int aEUt) { - if ((aInput1 == null) || (aOutput1 == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.benderRecipes.addRecipe( - true, - new ItemStack[] { aInput1, ItemList.Circuit_Integrated.getWithDamage(0, aInput1.stackSize) }, - new ItemStack[] { aOutput1 }, - null, - null, - null, - null, - aDuration, - Math.max(aEUt, 1), - 0); - return true; - } - - @Deprecated - @Override - public boolean addBenderRecipe(ItemStack aInput1, ItemStack aCircuit, ItemStack aOutput1, int aDuration, int aEUt) { - if ((aInput1 == null) || (aOutput1 == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - GT_Recipe tRecipe = new GT_Recipe( - new ItemStack[] { aInput1, aCircuit }, - new ItemStack[] { aOutput1 }, - null, - null, - null, - null, - aDuration, - Math.max(aEUt, 1), - 0); - RecipeMaps.benderRecipes.addRecipe(tRecipe); - return true; - } - - @Override - @Deprecated - public boolean addExtruderRecipe(ItemStack aInput, ItemStack aShape, ItemStack aOutput, int aDuration, int aEUt) { - if ((aInput == null) || (aShape == null) || (aOutput == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.extruderRecipes.addRecipe( - true, - new ItemStack[] { aInput, aShape }, - new ItemStack[] { aOutput }, - null, - null, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Override - @Deprecated - public boolean addSlicerRecipe(ItemStack aInput, ItemStack aShape, ItemStack aOutput, int aDuration, int aEUt) { - if ((aInput == null) || (aShape == null) || (aOutput == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.slicerRecipes.addRecipe( - true, - new ItemStack[] { aInput, aShape }, - new ItemStack[] { aOutput }, - null, - null, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Override - @Deprecated - public boolean addOreWasherRecipe(ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3, - FluidStack aFluidInput, int aDuration, int aEUt) { - if ((aInput == null) || (aFluidInput == null) - || ((aOutput1 == null) || (aOutput2 == null) || (aOutput3 == null))) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.oreWasherRecipes.addRecipe( - true, - new ItemStack[] { aInput }, - new ItemStack[] { aOutput1, aOutput2, aOutput3 }, - null, - new FluidStack[] { aFluidInput }, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Override - @Deprecated - public boolean addOreWasherRecipe(ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3, - FluidStack aFluidInput, int[] aChances, int aDuration, int aEUt) { - if ((aInput == null) || (aFluidInput == null) - || ((aOutput1 == null) || (aOutput2 == null) || (aOutput3 == null))) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.oreWasherRecipes.addRecipe( - true, - new ItemStack[] { aInput }, - new ItemStack[] { aOutput1, aOutput2, aOutput3 }, - null, - aChances, - new FluidStack[] { aFluidInput }, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Override - @Deprecated - public boolean addImplosionRecipe(ItemStack aInput1, int aInput2, ItemStack aOutput1, ItemStack aOutput2) { - if ((aInput1 == null) || (aOutput1 == null)) { - return false; - } - if (aInput2 <= 0) { - return false; - } - int tExplosives = Math.min(aInput2, 64); - int tGunpowder = tExplosives << 1; // Worst - int tDynamite = Math.max(1, tExplosives >> 1); // good - @SuppressWarnings("UnnecessaryLocalVariable") - int tTNT = tExplosives; // Slightly better - int tITNT = Math.max(1, tExplosives >> 2); // the best - // new GT_Recipe(aInput1, aInput2, aOutput1, aOutput2); - if (tGunpowder < 65) { - RecipeMaps.implosionRecipes.addRecipe( - true, - new ItemStack[] { aInput1, ItemList.Block_Powderbarrel.get(tGunpowder) }, - new ItemStack[] { aOutput1, aOutput2 }, - null, - null, - null, - null, - 20, - 30, - 0); - } - if (tDynamite < 17) { - RecipeMaps.implosionRecipes.addRecipe( - true, - new ItemStack[] { aInput1, GT_ModHandler.getIC2Item("dynamite", tDynamite, null) }, - new ItemStack[] { aOutput1, aOutput2 }, - null, - null, - null, - null, - 20, - 30, - 0); - } - RecipeMaps.implosionRecipes.addRecipe( - true, - new ItemStack[] { aInput1, new ItemStack(Blocks.tnt, tTNT) }, - new ItemStack[] { aOutput1, aOutput2 }, - null, - null, - null, - null, - 20, - 30, - 0); - RecipeMaps.implosionRecipes.addRecipe( - true, - new ItemStack[] { aInput1, GT_ModHandler.getIC2Item("industrialTnt", tITNT, null) }, - new ItemStack[] { aOutput1, aOutput2 }, - null, - null, - null, - null, - 20, - 30, - 0); - - return true; - } - - @Override - @Deprecated - public boolean addDistillationRecipe(ItemStack aInput1, int aInput2, ItemStack aOutput1, ItemStack aOutput2, - ItemStack aOutput3, ItemStack aOutput4, int aDuration, int aEUt) { - return false; - } - - @Override - @Deprecated - public boolean addUniversalDistillationRecipe(FluidStack aInput, FluidStack[] aOutputs, ItemStack aOutput2, - int aDuration, int aEUt) { - for (int i = 0; i < Math.min(aOutputs.length, 11); i++) { - addDistilleryRecipe(i + 1, aInput, aOutputs[i], aOutput2, aDuration * 2, aEUt / 4, false); - } - - return addDistillationTowerRecipe(aInput, aOutputs, aOutput2, aDuration, aEUt); - } - - @Override - @Deprecated - public boolean addDistillationTowerRecipe(FluidStack aInput, FluidStack[] aOutputs, ItemStack aOutput2, - int aDuration, int aEUt) { - if (aInput == null || aOutputs == null || aOutputs.length < 1 || aOutputs.length > 11) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.distillationTowerRecipes.addRecipe( - false, - null, - new ItemStack[] { aOutput2 }, - null, - new FluidStack[] { aInput }, - aOutputs, - aDuration, - Math.max(1, aEUt), - 0); - return false; - } - - @Override - @Deprecated - public boolean addDistillationTowerRecipe(FluidStack aInput, ItemStack[] aCircuit, FluidStack[] aOutputs, - ItemStack aOutput2, int aDuration, int aEUt) { - if (aInput == null || aOutputs == null || aOutputs.length < 1 || aOutputs.length > 11) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.distillationTowerRecipes.addRecipe( - false, - aCircuit, - new ItemStack[] { aOutput2 }, - null, - new FluidStack[] { aInput }, - aOutputs, - aDuration, - Math.max(1, aEUt), - 0); - return false; - } - - @Override - @Deprecated - public boolean addUniversalDistillationRecipewithCircuit(FluidStack aInput, ItemStack[] aCircuit, - FluidStack[] aOutputs, ItemStack aOutput2, int aDuration, int aEUt) { - for (int i = 0; i < Math.min(aOutputs.length, 11); i++) { - addDistilleryRecipe(i + 1, aInput, aOutputs[i], aOutput2, aDuration * 2, aEUt / 4, false); - } - return addDistillationTowerRecipe(aInput, aCircuit, aOutputs, aOutput2, aDuration, aEUt); - } - - @Override - @Deprecated - public boolean addVacuumFreezerRecipe(ItemStack aInput1, ItemStack aOutput1, int aDuration, int aEUt) { - if ((aInput1 == null) || (aOutput1 == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - RecipeMaps.vacuumFreezerRecipes.addRecipe( - false, - new ItemStack[] { aInput1 }, - new ItemStack[] { aOutput1 }, - null, - null, - null, - aDuration, - aEUt, - 0); - FluidStack tInputFluid = GT_Utility.getFluidForFilledItem(aInput1, true); - FluidStack tOutputFluid = GT_Utility.getFluidForFilledItem(aOutput1, true); - if (tInputFluid != null && tOutputFluid != null) { - addVacuumFreezerRecipe(tInputFluid, tOutputFluid, aDuration, aEUt); - } - return true; - } - - @Override - @Deprecated - public boolean addVacuumFreezerRecipe(ItemStack aInput1, ItemStack aOutput1, int aDuration) { - if ((aInput1 == null) || (aOutput1 == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - addVacuumFreezerRecipe(aInput1, aOutput1, aDuration, 120); - FluidStack tInputFluid = GT_Utility.getFluidForFilledItem(aInput1, true); - FluidStack tOutputFluid = GT_Utility.getFluidForFilledItem(aOutput1, true); - if (tInputFluid != null && tOutputFluid != null) { - addVacuumFreezerRecipe(tInputFluid, tOutputFluid, aDuration, 120); - } - return true; - } - - @Override - @Deprecated - public boolean addVacuumFreezerRecipe(FluidStack aInput1, FluidStack aOutput1, int aDuration, int aEUt) { - if ((aInput1 == null) || (aOutput1 == null)) { - return false; - } - RecipeMaps.vacuumFreezerRecipes.addRecipe( - false, - null, - null, - null, - new FluidStack[] { aInput1 }, - new FluidStack[] { aOutput1 }, - Math.max(1, aDuration), - aEUt, - 0); - return true; - } - - @Override - @Deprecated - public boolean addVacuumFreezerRecipe(ItemStack[] aItemInput, FluidStack[] aFluidInput, ItemStack[] aItemOutput, - FluidStack[] aFluidOutput, int aDuration, int aEUt) { - RecipeMaps.vacuumFreezerRecipes.addRecipe( - false, - aItemInput, - aItemOutput, - null, - aFluidInput, - aFluidOutput, - Math.max(1, aDuration), - Math.max(1, aEUt), - 0); - return true; - } - - @Override - @Deprecated - public boolean addGrinderRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, ItemStack aOutput2, - ItemStack aOutput3, ItemStack aOutput4) { - return false; - } - - @Override - @Deprecated - public boolean addFuel(ItemStack aInput1, ItemStack aOutput1, int aEU, int aType) { - if (aInput1 == null) { - return false; - } - new GT_Recipe(aInput1, aOutput1, null, null, null, aEU, aType); - return true; - } - - @Override - @Deprecated - public boolean addSonictronSound(ItemStack aItemStack, String aSoundName) { - if ((aItemStack == null) || (aSoundName == null) || (aSoundName.equals(""))) { - return false; - } - GT_Mod.gregtechproxy.mSoundItems.add(aItemStack); - GT_Mod.gregtechproxy.mSoundNames.add(aSoundName); - if (aSoundName.startsWith("note.")) { - GT_Mod.gregtechproxy.mSoundCounts.add(25); - } else { - GT_Mod.gregtechproxy.mSoundCounts.add(1); - } - return true; - } - - @Deprecated - @Override - public boolean addChemicalBathRecipe(ItemStack aInput, FluidStack aBathingFluid, ItemStack aOutput1, - ItemStack aOutput2, ItemStack aOutput3, FluidStack aFluidOutput, int[] aChances, int aDuration, int aEUt) { - return false; - } - - @Deprecated - @Override - public boolean addForgeHammerRecipe(ItemStack aInput1, ItemStack aOutput1, int aDuration, int aEUt) { - if ((aInput1 == null) || (aOutput1 == null)) { - return false; - } - RecipeMaps.hammerRecipes.addRecipe( - true, - new ItemStack[] { aInput1 }, - new ItemStack[] { aOutput1 }, - null, - null, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Deprecated - @Override - public boolean addForgeHammerRecipe(ItemStack[] ItemInputArray, FluidStack[] FluidInputArray, - ItemStack[] ItemOutputArray, FluidStack[] FluidOutputArray, int aDuration, int aEUt) { - - RecipeMaps.hammerRecipes.addRecipe( - true, - ItemInputArray, - ItemOutputArray, - null, - FluidInputArray, - FluidOutputArray, - aDuration, - aEUt, - 0); - return true; - } - - @Override - @Deprecated - public boolean addBoxingRecipe(ItemStack aContainedItem, ItemStack aEmptyBox, ItemStack aFullBox, int aDuration, - int aEUt) { - if ((aContainedItem == null) || (aFullBox == null)) { - return false; - } - RecipeMaps.packagerRecipes.addRecipe( - true, - new ItemStack[] { aContainedItem, aEmptyBox }, - new ItemStack[] { aFullBox }, - null, - null, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Override - @Deprecated - public boolean addUnboxingRecipe(ItemStack aFullBox, ItemStack aContainedItem, ItemStack aEmptyBox, int aDuration, - int aEUt) { - if ((aFullBox == null) || (aContainedItem == null)) { - return false; - } - RecipeMaps.unpackagerRecipes.addRecipe( - true, - new ItemStack[] { aFullBox }, - new ItemStack[] { aContainedItem, aEmptyBox }, - null, - null, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Deprecated - @Override - public boolean addThermalCentrifugeRecipe(ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2, - ItemStack aOutput3, int aDuration, int aEUt) { - if ((aInput == null) || (aOutput1 == null)) { - return false; - } - RecipeMaps.thermalCentrifugeRecipes.addRecipe( - true, - new ItemStack[] { aInput }, - new ItemStack[] { aOutput1, aOutput2, aOutput3 }, - null, - null, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Deprecated - @Override - public boolean addThermalCentrifugeRecipe(ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2, - ItemStack aOutput3, int[] aChances, int aDuration, int aEUt) { - if ((aInput == null) || (aOutput1 == null)) { - return false; - } - RecipeMaps.thermalCentrifugeRecipes.addRecipe( - true, - new ItemStack[] { aInput }, - new ItemStack[] { aOutput1, aOutput2, aOutput3 }, - null, - aChances, - null, - null, - aDuration, - aEUt, - 0); - return true; - } - - @Override - @Deprecated - public boolean addAmplifier(ItemStack aAmplifierItem, int aDuration, int aAmplifierAmountOutputted) { - if ((aAmplifierItem == null) || (aAmplifierAmountOutputted <= 0)) { - return false; - } - RecipeMaps.amplifierRecipes.addRecipe( - true, - new ItemStack[] { aAmplifierItem }, - null, - null, - null, - new FluidStack[] { Materials.UUAmplifier.getFluid(aAmplifierAmountOutputted) }, - aDuration, - 30, - 0); - return true; - } - - @Override - @Deprecated - public boolean addBrewingRecipe(ItemStack aIngredient, Fluid aInput, Fluid aOutput, int aDuration, int aEUt, - boolean aHidden) { - if ((aIngredient == null) || (aInput == null) || (aOutput == null)) { - return false; - } - GT_Recipe tRecipe = RecipeMaps.brewingRecipes.addRecipe( - false, - new ItemStack[] { aIngredient }, - null, - null, - new FluidStack[] { new FluidStack(aInput, 750) }, - new FluidStack[] { new FluidStack(aOutput, 750) }, - aDuration, - aEUt, - 0); - if ((aHidden) && (tRecipe != null)) { - tRecipe.mHidden = true; - } - return true; - } - - @Override - @Deprecated - public boolean addBrewingRecipe(ItemStack aIngredient, Fluid aInput, Fluid aOutput, boolean aHidden) { - return addBrewingRecipe(aIngredient, aInput, aOutput, 128, 4, aHidden); - } - - @Override - @Deprecated - public boolean addBrewingRecipeCustom(ItemStack aIngredient, FluidStack aInput, FluidStack aOutput, int aDuration, - int aEUt, boolean aHidden) { - if ((aInput == null) || (aOutput == null)) { - return false; - } - GT_Recipe tRecipe = RecipeMaps.brewingRecipes.addRecipe( - false, - new ItemStack[] { aIngredient }, - null, - null, - new FluidStack[] { aInput }, - new FluidStack[] { aOutput }, - aDuration, - aEUt, - 0); - if ((aHidden) && (tRecipe != null)) { - tRecipe.mHidden = true; - } - return true; - } - - @Override - @Deprecated - public boolean addFermentingRecipe(FluidStack aInput, FluidStack aOutput, int aDuration, int aEUt, - boolean aHidden) { - if ((aInput == null) || (aOutput == null)) { - return false; - } - if (aDuration <= 0) { - return false; - } - GT_Recipe tRecipe = RecipeMaps.fermentingRecipes.addRecipe( - false, - null, - null, - null, - ne