diff options
author | Maya <10861407+serenibyss@users.noreply.github.com> | 2024-09-21 17:55:21 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-09-22 00:55:21 +0200 |
commit | e21f588f21b014ecff68f67fca686dea76a2054b (patch) | |
tree | 6ea1983e47a79040108b1fbee5903f78db3d482b | |
parent | d31fa71d15bd61dd9e49c4f51b70593d3235ae70 (diff) | |
download | GT5-Unofficial-e21f588f21b014ecff68f67fca686dea76a2054b.tar.gz GT5-Unofficial-e21f588f21b014ecff68f67fca686dea76a2054b.tar.bz2 GT5-Unofficial-e21f588f21b014ecff68f67fca686dea76a2054b.zip |
Remove tungsten chain recipe remover (#3251)
Co-authored-by: Martin Robertz <dream-master@gmx.net>
-rw-r--r-- | src/main/java/bartworks/system/material/WerkstoffLoader.java | 4 | ||||
-rw-r--r-- | src/main/java/gtnhlanth/GTNHLanthanides.java | 1 | ||||
-rw-r--r-- | src/main/java/gtnhlanth/loader/BotRecipes.java | 31 |
3 files changed, 4 insertions, 32 deletions
diff --git a/src/main/java/bartworks/system/material/WerkstoffLoader.java b/src/main/java/bartworks/system/material/WerkstoffLoader.java index d99cc2a197..38ccdc9097 100644 --- a/src/main/java/bartworks/system/material/WerkstoffLoader.java +++ b/src/main/java/bartworks/system/material/WerkstoffLoader.java @@ -319,6 +319,8 @@ public class WerkstoffLoader { public static final Werkstoff Ferberite = new Werkstoff( new short[] { 0xB0, 0xB0, 0xB0, 0 }, "Ferberite", + Werkstoff.Types.getDefaultStatForType(Werkstoff.Types.COMPOUND) + .setElektrolysis(false), Werkstoff.Types.COMPOUND, new Werkstoff.GenerationFeatures(), 11, @@ -383,6 +385,8 @@ public class WerkstoffLoader { public static final Werkstoff Huebnerit = new Werkstoff( new short[] { 0x80, 0x60, 0x60, 0 }, "Huebnerite", + Werkstoff.Types.getDefaultStatForType(Werkstoff.Types.COMPOUND) + .setElektrolysis(false), Werkstoff.Types.COMPOUND, new Werkstoff.GenerationFeatures(), 17, diff --git a/src/main/java/gtnhlanth/GTNHLanthanides.java b/src/main/java/gtnhlanth/GTNHLanthanides.java index 311b274e86..5f8ad37f05 100644 --- a/src/main/java/gtnhlanth/GTNHLanthanides.java +++ b/src/main/java/gtnhlanth/GTNHLanthanides.java @@ -73,7 +73,6 @@ public class GTNHLanthanides { @EventHandler public static void onModLoadingComplete(FMLLoadCompleteEvent e) { - BotRecipes.removeRecipes(); RecipeLoader.removeCeriumSources(); } diff --git a/src/main/java/gtnhlanth/loader/BotRecipes.java b/src/main/java/gtnhlanth/loader/BotRecipes.java index fd0d4c4df7..94c1cf9eb6 100644 --- a/src/main/java/gtnhlanth/loader/BotRecipes.java +++ b/src/main/java/gtnhlanth/loader/BotRecipes.java @@ -6,7 +6,6 @@ import static gregtech.api.recipe.RecipeMaps.blastFurnaceRecipes; import static gregtech.api.recipe.RecipeMaps.chemicalReactorRecipes; import static gregtech.api.recipe.RecipeMaps.crackingRecipes; import static gregtech.api.recipe.RecipeMaps.distilleryRecipes; -import static gregtech.api.recipe.RecipeMaps.electrolyzerRecipes; import static gregtech.api.recipe.RecipeMaps.multiblockChemicalReactorRecipes; import static gregtech.api.util.GTRecipeBuilder.MINUTES; import static gregtech.api.util.GTRecipeBuilder.SECONDS; @@ -15,8 +14,6 @@ import static gregtech.api.util.GTRecipeConstants.COIL_HEAT; import static gregtech.api.util.GTRecipeConstants.UniversalChemical; import static gtnhlanth.common.register.BotWerkstoffMaterialPool.*; -import java.util.HashSet; - import net.minecraft.item.ItemStack; import net.minecraftforge.fluids.FluidStack; @@ -26,7 +23,6 @@ import gregtech.api.enums.Materials; import gregtech.api.enums.TierEU; import gregtech.api.util.GTModHandler; import gregtech.api.util.GTOreDictUnificator; -import gregtech.api.util.GTRecipe; import gregtech.api.util.GTUtility; import gtnhlanth.common.register.BotWerkstoffMaterialPool; import ic2.core.Ic2Items; @@ -232,31 +228,4 @@ public class BotRecipes { .eut(TierEU.RECIPE_EV) .addTo(crackingRecipes); } - - public static void removeRecipes() { - BotRecipes.removeTungstenElectro(); - } - - public static void removeTungstenElectro() { - HashSet<GTRecipe> toDel = new HashSet<>(); - ItemStack[] toRemove = { Materials.Scheelite.getDust(1), Materials.Tungstate.getDust(1), - WerkstoffLoader.Ferberite.get(dust, 1), WerkstoffLoader.Huebnerit.get(dust, 1) }; - for (GTRecipe tRecipe : electrolyzerRecipes.getAllRecipes()) { - if (tRecipe.mFakeRecipe) continue; - for (int i = 0; i < tRecipe.mInputs.length; i++) { - ItemStack tItem = tRecipe.mInputs[i]; - if (item == null || !GTUtility.isStackValid(tItem)) continue; - for (ItemStack tStack : toRemove) { - if (GTUtility.areStacksEqual(tItem, tStack)) { - toDel.add(tRecipe); - continue; - } - } - } - } - electrolyzerRecipes.getBackend() - .removeRecipes(toDel); - electrolyzerRecipes.getBackend() - .reInit(); - } } |