From f36239a67ee82d304aefe8f0e5cf89adb5811a69 Mon Sep 17 00:00:00 2001 From: MagicBot Date: Fri, 19 Apr 2024 09:30:59 -0400 Subject: [PATCH] Window refresh update --- src/engine/gameManager/ForgeManager.java | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/engine/gameManager/ForgeManager.java b/src/engine/gameManager/ForgeManager.java index ecee0905..49354b69 100644 --- a/src/engine/gameManager/ForgeManager.java +++ b/src/engine/gameManager/ForgeManager.java @@ -325,14 +325,6 @@ public enum ForgeManager implements Runnable { for (Item workOrderItem : workOrder.cooking) { - // Remove the virtual items from the forge window - - ItemProductionMsg outMsg = new ItemProductionMsg(workOrder.vendor.building, workOrder.vendor, workOrderItem, mbEnums.ProductionActionType.CONFIRM_SETPRICE, true); - DispatchMessage.dispatchMsgToInterestArea(workOrder.vendor, outMsg, mbEnums.DispatchChannel.SECONDARY, 700, false, false); - - workOrder.cooking.remove(workOrderItem); - itemWorkOrderLookup.remove(workOrderItem); - // Persist item Item completedItem = DbManager.ItemQueries.PERSIST(workOrderItem); @@ -345,6 +337,14 @@ public enum ForgeManager implements Runnable { DispatchMessage.dispatchMsgToInterestArea(workOrder.vendor, outMsg1, mbEnums.DispatchChannel.SECONDARY, 700, false, false); ItemProductionMsg outMsg2 = new ItemProductionMsg(workOrder.vendor.building, workOrder.vendor, completedItem, mbEnums.ProductionActionType.CONFIRM_DEPOSIT, true); DispatchMessage.dispatchMsgToInterestArea(workOrder.vendor, outMsg2, mbEnums.DispatchChannel.SECONDARY, 700, false, false); + + // Remove the virtual items from the forge window + + ItemProductionMsg outMsg = new ItemProductionMsg(workOrder.vendor.building, workOrder.vendor, workOrderItem, mbEnums.ProductionActionType.CONFIRM_SETPRICE, true); + DispatchMessage.dispatchMsgToInterestArea(workOrder.vendor, outMsg, mbEnums.DispatchChannel.SECONDARY, 700, false, false); + + workOrder.cooking.remove(workOrderItem); + itemWorkOrderLookup.remove(workOrderItem); } }