From 3ee37bfde5da77bb6d0330eb8c451ba33e4f3663 Mon Sep 17 00:00:00 2001 From: borisflagell Date: Sun, 22 May 2022 01:16:20 +0200 Subject: [PATCH] BLADEBURNER: FIX #3685 Error being thrown when finishing a BlackOps fixes #3685 - Bladeburner.action property was reset before being used for the last time in Bladeburner.processAction(). Moving const action = this.getActionObject(this.action); before the call to const retValue = this.completeAction(player, player, this.action); --- src/Bladeburner/Bladeburner.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Bladeburner/Bladeburner.tsx b/src/Bladeburner/Bladeburner.tsx index 7a043ea35..771726395 100644 --- a/src/Bladeburner/Bladeburner.tsx +++ b/src/Bladeburner/Bladeburner.tsx @@ -1677,11 +1677,11 @@ export class Bladeburner implements IBladeburner { this.actionTimeOverflow = 0; if (this.actionTimeCurrent >= this.actionTimeToComplete) { this.actionTimeOverflow = this.actionTimeCurrent - this.actionTimeToComplete; + const action = this.getActionObject(this.action); const retValue = this.completeAction(player, player, this.action); player.gainMoney(retValue.money, "bladeburner"); player.gainStats(retValue); // Operation Daedalus - const action = this.getActionObject(this.action); if (action == null) { throw new Error("Failed to get BlackOperation Object for: " + this.action.name); } else if (action.name === BlackOperationNames.OperationDaedalus && this.blackops[action.name]) {