mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2025-04-02 00:13:13 +02:00
Fix blade corp gang equal 0
This commit is contained in:
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -153,6 +153,17 @@ function evaluateVersionCompatibility(ver: string): void {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (ver < "0.56.1") {
|
||||||
|
if (anyPlayer.bladeburner === 0) {
|
||||||
|
anyPlayer.bladeburner = null;
|
||||||
|
}
|
||||||
|
if (anyPlayer.gang === 0) {
|
||||||
|
anyPlayer.gang = null;
|
||||||
|
}
|
||||||
|
if (anyPlayer.corporation === 0) {
|
||||||
|
anyPlayer.corporation = null;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function loadGame(saveString: string): boolean {
|
function loadGame(saveString: string): boolean {
|
||||||
|
@ -58,9 +58,10 @@ export class Script {
|
|||||||
download(): void {
|
download(): void {
|
||||||
const filename = this.filename + ".js";
|
const filename = this.filename + ".js";
|
||||||
const file = new Blob([this.code], { type: "text/plain" });
|
const file = new Blob([this.code], { type: "text/plain" });
|
||||||
if (window.navigator.msSaveOrOpenBlob) {
|
const navigator = window.navigator as any;
|
||||||
|
if (navigator.msSaveOrOpenBlob) {
|
||||||
// IE10+
|
// IE10+
|
||||||
window.navigator.msSaveOrOpenBlob(file, filename);
|
navigator.msSaveOrOpenBlob(file, filename);
|
||||||
} else {
|
} else {
|
||||||
// Others
|
// Others
|
||||||
const a = document.createElement("a"),
|
const a = document.createElement("a"),
|
||||||
@ -112,6 +113,10 @@ export class Script {
|
|||||||
this.markUpdated();
|
this.markUpdated();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
imports(): string[] {
|
||||||
|
return [];
|
||||||
|
}
|
||||||
|
|
||||||
// Serialize the current object to a JSON save state
|
// Serialize the current object to a JSON save state
|
||||||
toJSON(): any {
|
toJSON(): any {
|
||||||
return Generic_toJSON("Script", this);
|
return Generic_toJSON("Script", this);
|
||||||
|
Reference in New Issue
Block a user