From be22a9d082823f51444a77765fcd0d74dd8f767b Mon Sep 17 00:00:00 2001 From: bruberu <80226372+bruberu@users.noreply.github.com> Date: Mon, 29 Jul 2024 20:38:47 -0500 Subject: [PATCH] feat: set to ZPM (whatsapp2 recommendation) --- .../api/nuclear/fission/FissionFuelRegistry.java | 5 ++--- src/main/java/gregtech/common/ConfigHolder.java | 2 +- .../loaders/recipe/handlers/FluidRecipeHandler.java | 10 ++++------ 3 files changed, 7 insertions(+), 10 deletions(-) diff --git a/src/main/java/gregtech/api/nuclear/fission/FissionFuelRegistry.java b/src/main/java/gregtech/api/nuclear/fission/FissionFuelRegistry.java index 2ccca109ae7..8b64091072e 100644 --- a/src/main/java/gregtech/api/nuclear/fission/FissionFuelRegistry.java +++ b/src/main/java/gregtech/api/nuclear/fission/FissionFuelRegistry.java @@ -42,8 +42,7 @@ public static IFissionFuelStats getFissionFuel(int hash) { return HASHED_FUELS.get(hash); } - @Nullable - public static ItemStack getDepletedFuel(IFissionFuelStats stats) { - return DEPLETED_FUELS.get(stats); + public static @NotNull ItemStack getDepletedFuel(IFissionFuelStats stats) { + return DEPLETED_FUELS.get(stats).copy(); } } diff --git a/src/main/java/gregtech/common/ConfigHolder.java b/src/main/java/gregtech/common/ConfigHolder.java index 92746ad99d9..9444138c729 100644 --- a/src/main/java/gregtech/common/ConfigHolder.java +++ b/src/main/java/gregtech/common/ConfigHolder.java @@ -182,7 +182,7 @@ public static class NuclearOptions { @Config.Comment({ "Nuclear coolant heat exchanger recipe efficiency multiplier for balancing purposes", "Default: 0.1" }) @Config.RangeDouble(min = 0, max = 1000) - public double heatExchangerEfficiencyMultiplier = 0.0625; + public double heatExchangerEfficiencyMultiplier = 0.25; } } diff --git a/src/main/java/gregtech/loaders/recipe/handlers/FluidRecipeHandler.java b/src/main/java/gregtech/loaders/recipe/handlers/FluidRecipeHandler.java index 807adf67597..8c5e54fe7be 100644 --- a/src/main/java/gregtech/loaders/recipe/handlers/FluidRecipeHandler.java +++ b/src/main/java/gregtech/loaders/recipe/handlers/FluidRecipeHandler.java @@ -22,9 +22,8 @@ public static void processCoolant(Material mat, CoolantProperty coolant) { double multiplier = ConfigHolder.machines.nuclear.heatExchangerEfficiencyMultiplier; // water temp difference * water heat capacity * amount / coolantHeatCapacity * (hotHpTemp - coolantTemp) - int coolantAmt = (int) Math.ceil(100 * 4168 * waterAmt / (coolant.getSpecificHeatCapacity() * - (coolant.getHotHPCoolant().getFluid().getTemperature() - mat.getFluid().getTemperature())) * - multiplier); + int coolantAmt = (int) Math.ceil(100 * 4168 * waterAmt * multiplier / (coolant.getSpecificHeatCapacity() * + (coolant.getHotHPCoolant().getFluid().getTemperature() - mat.getFluid().getTemperature()))); RecipeMaps.HEAT_EXCHANGER_RECIPES.recipeBuilder().duration(1).circuitMeta(1) .fluidInputs(coolant.getHotHPCoolant().getFluid(coolantAmt), Materials.Water.getFluid(waterAmt)) @@ -36,9 +35,8 @@ public static void processCoolant(Material mat, CoolantProperty coolant) { .fluidOutputs(mat.getFluid(coolantAmt), Materials.Steam.getFluid(waterAmt * 160)).buildAndRegister(); waterAmt = 600; // Slightly more efficient - coolantAmt = (int) Math.ceil(100 * 4168 * waterAmt / (coolant.getSpecificHeatCapacity() * - (coolant.getHotHPCoolant().getFluid().getTemperature() - mat.getFluid().getTemperature())) * - multiplier); + coolantAmt = (int) Math.ceil(100 * 4168 * waterAmt * multiplier / (coolant.getSpecificHeatCapacity() * + (coolant.getHotHPCoolant().getFluid().getTemperature() - mat.getFluid().getTemperature())));; RecipeMaps.HEAT_EXCHANGER_RECIPES.recipeBuilder().duration(1).circuitMeta(2) .fluidInputs(coolant.getHotHPCoolant().getFluid(coolantAmt), Materials.Water.getFluid(waterAmt))