diff options
author | Johann Bernhardt <johann.bernhardt@tum.de> | 2021-12-01 14:34:14 +0100 |
---|---|---|
committer | Johann Bernhardt <johann.bernhardt@tum.de> | 2021-12-01 14:34:14 +0100 |
commit | 8e45b04722ee129ff412d8329b93d35eb8744c1f (patch) | |
tree | 5ed344f739e2349854b6acb5d451f00d8ca35319 /src/main/java/gregtech/api/util/GT_ModHandler.java | |
parent | 899aa570f096e2850e35627950f9f67ccfe8b186 (diff) | |
parent | 5fc226f1385e13afbf3406f4d3283638fc7b8a70 (diff) | |
download | GT5-Unofficial-8e45b04722ee129ff412d8329b93d35eb8744c1f.tar.gz GT5-Unofficial-8e45b04722ee129ff412d8329b93d35eb8744c1f.tar.bz2 GT5-Unofficial-8e45b04722ee129ff412d8329b93d35eb8744c1f.zip |
Merge remote-tracking branch 'origin/experimental' into unify-build-script
# Conflicts:
# .github/workflows/gradle.yml
# build.gradle
# build.properties
Diffstat (limited to 'src/main/java/gregtech/api/util/GT_ModHandler.java')
-rw-r--r-- | src/main/java/gregtech/api/util/GT_ModHandler.java | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/src/main/java/gregtech/api/util/GT_ModHandler.java b/src/main/java/gregtech/api/util/GT_ModHandler.java index 810a204c40..acd9a294f9 100644 --- a/src/main/java/gregtech/api/util/GT_ModHandler.java +++ b/src/main/java/gregtech/api/util/GT_ModHandler.java @@ -797,6 +797,13 @@ public class GT_ModHandler { /** * IC2-ThermalCentrifuge Recipe. Overloads old Recipes automatically */ + public static boolean addThermalCentrifugeRecipe(ItemStack aInput, int[] aChances, int aHeat, Object... aOutput) { + if (aInput == null || aOutput == null || aOutput.length <= 0 || aOutput[0] == null) return false; + if (!GregTech_API.sRecipeFile.get(ConfigCategories.Machines.thermalcentrifuge, aInput, true)) return false; + RA.addThermalCentrifugeRecipe(aInput, aOutput.length >= 1 ? (ItemStack)aOutput[0] : null, aOutput.length >= 2 ? (ItemStack)aOutput[1] : null, aOutput.length >= 3 ? (ItemStack)aOutput[2] : null, aChances, 500, 48); + return true; + } + public static boolean addThermalCentrifugeRecipe(ItemStack aInput, int aHeat, Object... aOutput) { if (aInput == null || aOutput == null || aOutput.length <= 0 || aOutput[0] == null) return false; if (!GregTech_API.sRecipeFile.get(ConfigCategories.Machines.thermalcentrifuge, aInput, true)) return false; @@ -807,11 +814,19 @@ public class GT_ModHandler { /** * IC2-OreWasher Recipe. Overloads old Recipes automatically */ + public static boolean addOreWasherRecipe(ItemStack aInput, int[] aChances, int aWaterAmount, Object... aOutput) { + if (aInput == null || aOutput == null || aOutput.length <= 0 || aOutput[0] == null) return false; + if (!GregTech_API.sRecipeFile.get(ConfigCategories.Machines.orewashing, aInput, true)) return false; + RA.addOreWasherRecipe(aInput, (ItemStack)aOutput[0], (ItemStack)aOutput[1], (ItemStack)aOutput[2], GT_ModHandler.getWater(aWaterAmount), aChances, 500, 16); + RA.addOreWasherRecipe(aInput, (ItemStack)aOutput[0], (ItemStack)aOutput[1], (ItemStack)aOutput[2], GT_ModHandler.getDistilledWater(aWaterAmount / 5), aChances, 300, 16); + return true; + } + public static boolean addOreWasherRecipe(ItemStack aInput, int aWaterAmount, Object... aOutput) { if (aInput == null || aOutput == null || aOutput.length <= 0 || aOutput[0] == null) return false; if (!GregTech_API.sRecipeFile.get(ConfigCategories.Machines.orewashing, aInput, true)) return false; - RA.addOreWasherRecipe(aInput, (ItemStack)aOutput[0], (ItemStack)aOutput[1], (ItemStack)aOutput[2], GT_ModHandler.getWater(1000L), 500, 16); - RA.addOreWasherRecipe(aInput, (ItemStack)aOutput[0], (ItemStack)aOutput[1], (ItemStack)aOutput[2], GT_ModHandler.getDistilledWater(200L), 300, 16); + RA.addOreWasherRecipe(aInput, (ItemStack)aOutput[0], (ItemStack)aOutput[1], (ItemStack)aOutput[2], GT_ModHandler.getWater(aWaterAmount), 500, 16); + RA.addOreWasherRecipe(aInput, (ItemStack)aOutput[0], (ItemStack)aOutput[1], (ItemStack)aOutput[2], GT_ModHandler.getDistilledWater(aWaterAmount / 5), 300, 16); return true; } |