mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-12-23 14:42:28 +01:00
Fix bladeburner.getActionTime returning null
This commit is contained in:
parent
7e311d0592
commit
9b099fcee9
@ -3424,12 +3424,7 @@ function NetscriptFunctions(workerScript) {
|
||||
}
|
||||
updateDynamicRam("getCurrentAction", CONSTANTS.ScriptBladeburnerApiBaseRamCost / 4);
|
||||
if (Player.bladeburner instanceof Bladeburner && (Player.bitNodeN === 7 || hasBladeburner2079SF)) {
|
||||
let res = Player.bladeburner.getTypeAndNameFromActionId(Player.bladeburner.action);
|
||||
if (res.type === "Idle" && res.name === "Idle") {
|
||||
return null;
|
||||
} else {
|
||||
return res;
|
||||
}
|
||||
return Player.bladeburner.getTypeAndNameFromActionId(Player.bladeburner.action);
|
||||
}
|
||||
throw makeRuntimeRejectMsg(workerScript, "getCurrentAction() failed because you do not currently have access to the Bladeburner API. This is either because you are not currently employed " +
|
||||
"at the Bladeburner division or because you do not have Source-File 7");
|
||||
|
Loading…
Reference in New Issue
Block a user