From a7d615c5554a3e0badb1b6cfbfed0ca45212534c Mon Sep 17 00:00:00 2001 From: StaffiX <32968022+StaffiX@users.noreply.github.com> Date: Sun, 22 Dec 2024 16:54:05 +0100 Subject: [PATCH 1/3] buff pcb parallel --- .../common/tileentities/machines/multi/MTEPCBFactory.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/MTEPCBFactory.java b/src/main/java/gregtech/common/tileentities/machines/multi/MTEPCBFactory.java index a817464b50f..02ef8b52cca 100644 --- a/src/main/java/gregtech/common/tileentities/machines/multi/MTEPCBFactory.java +++ b/src/main/java/gregtech/common/tileentities/machines/multi/MTEPCBFactory.java @@ -558,7 +558,7 @@ protected CheckRecipeResult validateRecipe(@Nonnull GTRecipe recipe) { } } } - maxParallel = (int) Math.max(Math.ceil(Math.log(numberOfNanites) / Math.log(2) + 0.00001), 1); + maxParallel = (int) Math.min(Math.max(Math.floor(Math.pow(2.1, Math.log(numberOfNanites))), 1), 256); mMaxParallel = maxParallel; PCBFactoryUpgrade requiredUpgrade = recipe.getMetadata(PCBFactoryUpgradeKey.INSTANCE); From d4f7c6ae60ca8ba11960619bfc7881c8c4075565 Mon Sep 17 00:00:00 2001 From: StaffiX <32968022+StaffiX@users.noreply.github.com> Date: Sun, 22 Dec 2024 17:34:43 +0100 Subject: [PATCH 2/3] change tooltip --- .../common/tileentities/machines/multi/MTEPCBFactory.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/MTEPCBFactory.java b/src/main/java/gregtech/common/tileentities/machines/multi/MTEPCBFactory.java index 02ef8b52cca..35294e4013e 100644 --- a/src/main/java/gregtech/common/tileentities/machines/multi/MTEPCBFactory.java +++ b/src/main/java/gregtech/common/tileentities/machines/multi/MTEPCBFactory.java @@ -558,7 +558,7 @@ protected CheckRecipeResult validateRecipe(@Nonnull GTRecipe recipe) { } } } - maxParallel = (int) Math.min(Math.max(Math.floor(Math.pow(2.1, Math.log(numberOfNanites))), 1), 256); + maxParallel = (int) Math.min(Math.max(Math.ceil(Math.pow(2.1, Math.log(numberOfNanites))), 1), 256); mMaxParallel = maxParallel; PCBFactoryUpgrade requiredUpgrade = recipe.getMetadata(PCBFactoryUpgradeKey.INSTANCE); @@ -846,8 +846,8 @@ protected MultiblockTooltipBuilder createTooltip() { .addInfo("Each tier and upgrade requires additional structures.") .addInfo("Power consumption is multiplied by Sqrt(structures).") .addInfo("Tier 2 and 3 allow parallel by using extra nanites.") - .addInfo("Every doubling of nanites adds one parallel.") - .addInfo("1x->1, 2x->2, 4x->3, 8x->4 with no limit.") + .addInfo("The formula for parallels is 2.1^(ln(nanite), rounded up.") + .addInfo("Maximum parallel is 256.") .addInfo("Recipes require a cooling upgrade to be overclocked.") .addInfo("Liquid Cooling uses 10 L/s of distilled water and enables default overclocks.") .addInfo("Thermosink uses 10 L/s of Super Coolant and enables perfect overclocks.") From 2b67d0038be7adf36c622bca7590f17c4f12872d Mon Sep 17 00:00:00 2001 From: StaffiX <32968022+StaffiX@users.noreply.github.com> Date: Sun, 22 Dec 2024 22:12:52 +0100 Subject: [PATCH 3/3] simplify formula --- .../common/tileentities/machines/multi/MTEPCBFactory.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/MTEPCBFactory.java b/src/main/java/gregtech/common/tileentities/machines/multi/MTEPCBFactory.java index 35294e4013e..0522eae509d 100644 --- a/src/main/java/gregtech/common/tileentities/machines/multi/MTEPCBFactory.java +++ b/src/main/java/gregtech/common/tileentities/machines/multi/MTEPCBFactory.java @@ -558,7 +558,7 @@ protected CheckRecipeResult validateRecipe(@Nonnull GTRecipe recipe) { } } } - maxParallel = (int) Math.min(Math.max(Math.ceil(Math.pow(2.1, Math.log(numberOfNanites))), 1), 256); + maxParallel = (int) Math.min(Math.max(Math.ceil(Math.pow(numberOfNanites, 0.75)), 1), 256); mMaxParallel = maxParallel; PCBFactoryUpgrade requiredUpgrade = recipe.getMetadata(PCBFactoryUpgradeKey.INSTANCE); @@ -846,7 +846,7 @@ protected MultiblockTooltipBuilder createTooltip() { .addInfo("Each tier and upgrade requires additional structures.") .addInfo("Power consumption is multiplied by Sqrt(structures).") .addInfo("Tier 2 and 3 allow parallel by using extra nanites.") - .addInfo("The formula for parallels is 2.1^(ln(nanite), rounded up.") + .addInfo("The formula for parallels is the amount of nanites^0.75, rounded up.") .addInfo("Maximum parallel is 256.") .addInfo("Recipes require a cooling upgrade to be overclocked.") .addInfo("Liquid Cooling uses 10 L/s of distilled water and enables default overclocks.")