diff options
Diffstat (limited to 'src/main/java/gregtech/loaders/oreprocessing')
5 files changed, 52 insertions, 54 deletions
diff --git a/src/main/java/gregtech/loaders/oreprocessing/ProcessingCell.java b/src/main/java/gregtech/loaders/oreprocessing/ProcessingCell.java index 5a6bdfcf13..f7057065eb 100644 --- a/src/main/java/gregtech/loaders/oreprocessing/ProcessingCell.java +++ b/src/main/java/gregtech/loaders/oreprocessing/ProcessingCell.java @@ -1,8 +1,11 @@ package gregtech.loaders.oreprocessing; +import static gregtech.api.enums.GT_Values.RA; import static gregtech.api.recipe.RecipeMaps.centrifugeRecipes; import static gregtech.api.recipe.RecipeMaps.electrolyzerRecipes; +import static gregtech.api.recipe.RecipeMaps.extractorRecipes; import static gregtech.api.recipe.RecipeMaps.vacuumFreezerRecipes; +import static gregtech.api.util.GT_RecipeBuilder.SECONDS; import static gregtech.api.util.GT_RecipeBuilder.TICKS; import static gregtech.api.util.GT_RecipeConstants.FUEL_TYPE; import static gregtech.api.util.GT_RecipeConstants.FUEL_VALUE; @@ -11,7 +14,6 @@ import java.util.ArrayList; import net.minecraft.item.ItemStack; -import gregtech.api.enums.GT_Values; import gregtech.api.enums.ItemList; import gregtech.api.enums.Materials; import gregtech.api.enums.OrePrefixes; @@ -39,11 +41,16 @@ public class ProcessingCell implements IOreRecipeRegistrator { if (aMaterial == Materials.Empty) { GT_ModHandler.removeRecipeByOutputDelayed(aStack); if (aModName.equalsIgnoreCase("AtomicScience")) { - GT_ModHandler.addExtractionRecipe(ItemList.Cell_Empty.get(1L), aStack); + RA.stdBuilder() + .itemInputs(ItemList.Cell_Empty.get(1L)) + .itemOutputs(aStack) + .duration(15 * SECONDS) + .eut(2) + .addTo(extractorRecipes); } } else { if (aMaterial.mFuelPower > 0) { - GT_RecipeBuilder recipeBuilder = GT_Values.RA.stdBuilder(); + GT_RecipeBuilder recipeBuilder = RA.stdBuilder(); recipeBuilder.itemInputs(GT_Utility.copyAmount(1, aStack)); if (GT_Utility.getFluidForFilledItem(aStack, true) == null && GT_Utility.getContainerItem(aStack, true) != null) { @@ -122,7 +129,7 @@ public class ProcessingCell implements IOreRecipeRegistrator { // Electrolyzer recipe if (GT_Utility.getFluidForFilledItem(aStack, true) == null) { // dust stuffed cell e.g. Phosphate, Phosphorous Pentoxide - GT_RecipeBuilder recipeBuilder = GT_Values.RA.stdBuilder(); + GT_RecipeBuilder recipeBuilder = RA.stdBuilder(); if (tCapsuleCount > 0L) { recipeBuilder.itemInputs( GT_Utility.copyAmount(tItemAmount, aStack), @@ -140,7 +147,7 @@ public class ProcessingCell implements IOreRecipeRegistrator { .addTo(electrolyzerRecipes); } else { long tCellBalance = tCapsuleCount + tItemAmount - 1; - GT_RecipeBuilder recipeBuilder = GT_Values.RA.stdBuilder(); + GT_RecipeBuilder recipeBuilder = RA.stdBuilder(); if (tCellBalance > 0L) { recipeBuilder.itemInputs(aStack, ItemList.Cell_Empty.get(tCellBalance)); } else { @@ -157,7 +164,7 @@ public class ProcessingCell implements IOreRecipeRegistrator { } } if ((aMaterial.mExtraData & 0x2) != 0) { - GT_RecipeBuilder recipeBuilder = GT_Values.RA.stdBuilder(); + GT_RecipeBuilder recipeBuilder = RA.stdBuilder(); if (tCapsuleCount > 0L) { recipeBuilder.itemInputs( GT_Utility.copyAmount(tItemAmount, aStack), @@ -180,7 +187,7 @@ public class ProcessingCell implements IOreRecipeRegistrator { if (aMaterial == Materials.Empty) { GT_ModHandler.removeRecipeByOutputDelayed(aStack); } else { - GT_RecipeBuilder recipeBuilder = GT_Values.RA.stdBuilder(); + GT_RecipeBuilder recipeBuilder = RA.stdBuilder(); recipeBuilder.itemInputs(GT_Utility.copyAmount(1, aStack)); if (GT_Utility.getFluidForFilledItem(aStack, true) == null && GT_Utility.getContainerItem(aStack, true) != null) { @@ -426,7 +433,7 @@ public class ProcessingCell implements IOreRecipeRegistrator { .addTo(GT_RecipeConstants.Fuel); } if (GT_OreDictUnificator.get(OrePrefixes.cell, aMaterial, 1L) != null) { - GT_Values.RA.stdBuilder() + RA.stdBuilder() .itemInputs(GT_Utility.copyAmount(1, aStack)) .itemOutputs(GT_OreDictUnificator.get(OrePrefixes.cell, aMaterial, 1L)) .duration(((int) Math.max(aMaterial.getMass() * 2L, 1L)) * TICKS) diff --git a/src/main/java/gregtech/loaders/oreprocessing/ProcessingDust.java b/src/main/java/gregtech/loaders/oreprocessing/ProcessingDust.java index 7cb26f7c36..c8a3af1130 100644 --- a/src/main/java/gregtech/loaders/oreprocessing/ProcessingDust.java +++ b/src/main/java/gregtech/loaders/oreprocessing/ProcessingDust.java @@ -290,16 +290,12 @@ public class ProcessingDust implements gregtech.api.interfaces.IOreRecipeRegistr GT_OreDictUnificator.get(OrePrefixes.dust, Materials.MeatCooked, 1L)); break; case "Oilsands": - centrifugeRecipes.addRecipe( - true, - new ItemStack[] { GT_Utility.copyAmount(1, aStack) }, - null, - null, - null, - new FluidStack[] { Materials.OilHeavy.getFluid(1000) }, - 660, - 8, - 0); + GT_Values.RA.stdBuilder() + .itemInputs(GT_Utility.copyAmount(1, aStack)) + .fluidOutputs(Materials.OilHeavy.getFluid(1000)) + .duration(33 * SECONDS) + .eut(8) + .addTo(centrifugeRecipes); break; case "HydratedCoal": GT_ModHandler.addSmeltingRecipe( diff --git a/src/main/java/gregtech/loaders/oreprocessing/ProcessingDye.java b/src/main/java/gregtech/loaders/oreprocessing/ProcessingDye.java index f3e82c0b0e..9661033e6a 100644 --- a/src/main/java/gregtech/loaders/oreprocessing/ProcessingDye.java +++ b/src/main/java/gregtech/loaders/oreprocessing/ProcessingDye.java @@ -1,8 +1,11 @@ package gregtech.loaders.oreprocessing; +import static gregtech.api.enums.GT_Values.RA; +import static gregtech.api.recipe.RecipeMaps.alloySmelterRecipes; import static gregtech.api.recipe.RecipeMaps.mixerRecipes; import static gregtech.api.util.GT_RecipeBuilder.SECONDS; import static gregtech.api.util.GT_RecipeBuilder.TICKS; +import static gregtech.api.util.GT_RecipeBuilder.WILDCARD; import static gregtech.api.util.GT_RecipeConstants.UniversalChemical; import java.util.Locale; @@ -59,21 +62,21 @@ public class ProcessingDye implements IOreRecipeRegistrator { } public void registerAlloySmelter(ItemStack stack, Dyes dye) { - GT_ModHandler.addAlloySmelterRecipe( - GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Glass, 8L), - GT_Utility.copyAmount(1, stack), - new ItemStack(Blocks.stained_glass, 8, 15 - dye.mIndex), - 200, - 8, - false); + RA.stdBuilder() + .itemInputs( + GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Glass, 8L), + GT_Utility.copyAmount(1, stack)) + .itemOutputs(new ItemStack(Blocks.stained_glass, 8, 15 - dye.mIndex)) + .duration(10 * SECONDS) + .eut(8) + .addTo(alloySmelterRecipes); - GT_ModHandler.addAlloySmelterRecipe( - new ItemStack(Blocks.glass, 8, 32767), - GT_Utility.copyAmount(1, stack), - new ItemStack(Blocks.stained_glass, 8, 15 - dye.mIndex), - 200, - 8, - false); + RA.stdBuilder() + .itemInputs(new ItemStack(Blocks.glass, 8, WILDCARD), GT_Utility.copyAmount(1, stack)) + .itemOutputs(new ItemStack(Blocks.stained_glass, 8, 15 - dye.mIndex)) + .duration(10 * SECONDS) + .eut(8) + .addTo(alloySmelterRecipes); } public void registerChemicalReactor(ItemStack stack, Dyes dye) { diff --git a/src/main/java/gregtech/loaders/oreprocessing/ProcessingLog.java b/src/main/java/gregtech/loaders/oreprocessing/ProcessingLog.java index 737ef4682a..5985e24dc7 100644 --- a/src/main/java/gregtech/loaders/oreprocessing/ProcessingLog.java +++ b/src/main/java/gregtech/loaders/oreprocessing/ProcessingLog.java @@ -187,10 +187,6 @@ public class ProcessingLog implements gregtech.api.interfaces.IOreRecipeRegistra .duration(10 * SECONDS) .eut(8) .addTo(cutterRecipes); - GT_ModHandler.addSawmillRecipe( - new ItemStack(aStack.getItem(), 1, i), - tPlanks, - GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Wood, 1L)); GT_ModHandler.removeRecipeDelayed(new ItemStack(aStack.getItem(), 1, i)); GT_ModHandler.addCraftingRecipe( GT_Utility.copyAmount( @@ -260,10 +256,6 @@ public class ProcessingLog implements gregtech.api.interfaces.IOreRecipeRegistra .duration(10 * SECONDS) .eut(8) .addTo(cutterRecipes); - GT_ModHandler.addSawmillRecipe( - GT_Utility.copyAmount(1, aStack), - tPlanks, - GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Wood, 1L)); GT_ModHandler.removeRecipeDelayed(GT_Utility.copyAmount(1, aStack)); GT_ModHandler.addCraftingRecipe( GT_Utility.copyAmount( diff --git a/src/main/java/gregtech/loaders/oreprocessing/ProcessingPlate.java b/src/main/java/gregtech/loaders/oreprocessing/ProcessingPlate.java index be8322f30c..801eaa8354 100644 --- a/src/main/java/gregtech/loaders/oreprocessing/ProcessingPlate.java +++ b/src/main/java/gregtech/loaders/oreprocessing/ProcessingPlate.java @@ -2,6 +2,7 @@ package gregtech.loaders.oreprocessing; import static gregtech.api.enums.GT_Values.L; import static gregtech.api.enums.GT_Values.NI; +import static gregtech.api.enums.GT_Values.RA; import static gregtech.api.enums.GT_Values.W; import static gregtech.api.recipe.RecipeMaps.alloySmelterRecipes; import static gregtech.api.recipe.RecipeMaps.assemblerRecipes; @@ -15,6 +16,7 @@ import static gregtech.api.util.GT_ModHandler.RecipeBits.DO_NOT_CHECK_FOR_COLLIS import static gregtech.api.util.GT_RecipeBuilder.MINUTES; import static gregtech.api.util.GT_RecipeBuilder.SECONDS; import static gregtech.api.util.GT_RecipeBuilder.TICKS; +import static gregtech.api.util.GT_RecipeBuilder.WILDCARD; import static gregtech.api.util.GT_RecipeConstants.FUEL_TYPE; import static gregtech.api.util.GT_RecipeConstants.FUEL_VALUE; import static gregtech.api.util.GT_Utility.calculateRecipeEU; @@ -552,20 +554,18 @@ public class ProcessingPlate implements gregtech.api.interfaces.IOreRecipeRegist .addTo(alloySmelterRecipes); } case "plateAlloyAdvanced" -> { - GT_ModHandler.addAlloySmelterRecipe( - GT_Utility.copyAmount(1, aStack), - new ItemStack(Blocks.glass, 3, W), - GT_ModHandler.getIC2Item("reinforcedGlass", 4L), - 400, - 4, - false); - GT_ModHandler.addAlloySmelterRecipe( - GT_Utility.copyAmount(1, aStack), - Materials.Glass.getDust(3), - GT_ModHandler.getIC2Item("reinforcedGlass", 4L), - 400, - 4, - false); + RA.stdBuilder() + .itemInputs(GT_Utility.copyAmount(1, aStack), new ItemStack(Blocks.glass, 3, WILDCARD)) + .itemOutputs(GT_ModHandler.getIC2Item("reinforcedGlass", 4L)) + .duration(20 * SECONDS) + .eut(4) + .addTo(alloySmelterRecipes); + RA.stdBuilder() + .itemInputs(GT_Utility.copyAmount(1, aStack), Materials.Glass.getDust(3)) + .itemOutputs(GT_ModHandler.getIC2Item("reinforcedGlass", 4L)) + .duration(20 * SECONDS) + .eut(4) + .addTo(alloySmelterRecipes); } case "plateAlloyIridium" -> |