Browse Source

Completion time reset before new batch

combat-2
MagicBot 7 months ago
parent
commit
8cada05424
  1. 5
      src/engine/gameManager/ForgeManager.java

5
src/engine/gameManager/ForgeManager.java

@ -85,7 +85,6 @@ public enum ForgeManager implements Runnable {
// enQueue this workOrder again; back into the oven // enQueue this workOrder again; back into the oven
// until all items for this workOrder are completed. // until all items for this workOrder are completed.
workOrder.completionTime = System.currentTimeMillis() + workOrder.rollingDuration;
forge.add(workOrder); forge.add(workOrder);
// Debugging // Debugging
@ -335,6 +334,10 @@ public enum ForgeManager implements Runnable {
public static void forgeWorkerOrderBatch(WorkOrder workOrder) { public static void forgeWorkerOrderBatch(WorkOrder workOrder) {
// New completion time for this batch
workOrder.completionTime = System.currentTimeMillis() + workOrder.rollingDuration;
for (int i = 0; i < workOrder.slots_used; ++i) { for (int i = 0; i < workOrder.slots_used; ++i) {
Item forged_item = forgeItem(workOrder); Item forged_item = forgeItem(workOrder);

Loading…
Cancel
Save