mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-04-20 00:04:22 +02:00
MISC: Disable effect of SF7.3 and SF10 if player disables them with advanced options (#2019)
* MISC: Disable effect of SF7.3 and SF10 if player disables them with advanced options * Update based on feedback
This commit is contained in:
@@ -17,7 +17,11 @@ import { SleeveWorkType } from "../PersonObjects/Sleeve/Work/Work";
|
||||
import { canAccessBitNodeFeature } from "../BitNode/BitNodeUtils";
|
||||
|
||||
export const checkSleeveAPIAccess = function (ctx: NetscriptContext) {
|
||||
if (Player.bitNodeN !== 10 && !Player.sourceFileLvl(10)) {
|
||||
/**
|
||||
* Don't change sourceFileLvl to activeSourceFileLvl. The ability to control Sleeves (via both UI and APIs) is a
|
||||
* permanent benefit.
|
||||
*/
|
||||
if (Player.bitNodeN !== 10 && Player.sourceFileLvl(10) <= 0) {
|
||||
throw helpers.errorMessage(
|
||||
ctx,
|
||||
"You do not currently have access to the Sleeve API. This is either because you are not in BitNode-10 or because you do not have Source-File 10",
|
||||
|
||||
Reference in New Issue
Block a user