From a16cda8a4ad79bb063313b553a84046af833deb2 Mon Sep 17 00:00:00 2001 From: MagicBot Date: Fri, 12 Apr 2024 15:31:12 -0400 Subject: [PATCH] workerOrder cost updating --- src/engine/gameManager/ForgeManager.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/engine/gameManager/ForgeManager.java b/src/engine/gameManager/ForgeManager.java index ad5799b8..05f1560f 100644 --- a/src/engine/gameManager/ForgeManager.java +++ b/src/engine/gameManager/ForgeManager.java @@ -105,8 +105,7 @@ public enum ForgeManager implements Runnable { // Set total cost for this production run - for (mbEnums.ResourceType resourceType : workOrder.production_cost.keySet()) - workOrder.production_cost.compute(resourceType, (k, resourceValue) -> resourceValue * workOrder.total_to_produce); + workOrder.production_cost.forEach((key, value) -> workOrder.production_cost_total.compute(key, (k, v) -> v * workOrder.total_to_produce)); // Single item rolls are total_to_produce of 0;