mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2025-02-17 02:22:23 +01:00
API FIX:#3732 Cannot assign two sleeve on "Take on contracts" regardless of contract type.
ns.sleeve.setToBladeburnerAction() was not testing the contract value.
This commit is contained in:
@ -332,7 +332,11 @@ export function NetscriptSleeve(player: IPlayer): InternalAPI<ISleeve> {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
const other = player.sleeves[i];
|
const other = player.sleeves[i];
|
||||||
if (other.currentTask === SleeveTaskType.Bladeburner && other.bbAction === action) {
|
if (
|
||||||
|
other.currentTask === SleeveTaskType.Bladeburner &&
|
||||||
|
other.bbAction === action &&
|
||||||
|
other.bbContract === contract
|
||||||
|
) {
|
||||||
throw ctx.helper.makeRuntimeErrorMsg(
|
throw ctx.helper.makeRuntimeErrorMsg(
|
||||||
`Sleeve ${sleeveNumber} cannot take of contracts because Sleeve ${i} is already performing that action.`,
|
`Sleeve ${sleeveNumber} cannot take of contracts because Sleeve ${i} is already performing that action.`,
|
||||||
);
|
);
|
||||||
|
Reference in New Issue
Block a user