mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-04-25 02:32:55 +02:00
Fix
This commit is contained in:
+26
-1
@@ -4,7 +4,14 @@ import { CONSTANTS } from "./Constants";
|
||||
import { Factions, loadFactions } from "./Faction/Factions";
|
||||
import { loadAllGangs, AllGangs } from "./Gang/AllGangs";
|
||||
import { Player, loadPlayer } from "./Player";
|
||||
import { saveAllServers, loadAllServers, GetAllServers } from "./Server/AllServers";
|
||||
import {
|
||||
saveAllServers,
|
||||
loadAllServers,
|
||||
GetAllServers,
|
||||
createUniqueRandomIp,
|
||||
AddToAllServers,
|
||||
GetServer,
|
||||
} from "./Server/AllServers";
|
||||
import { Settings } from "./Settings/Settings";
|
||||
import { loadStockMarket, StockMarket } from "./StockMarket/StockMarket";
|
||||
import { staneksGift, loadStaneksGift } from "./CotMG/Helper";
|
||||
@@ -26,6 +33,8 @@ import { pushGameSaved } from "./Electron";
|
||||
import { defaultMonacoTheme } from "./ScriptEditor/ui/themes";
|
||||
import { FactionNames } from "./Faction/data/FactionNames";
|
||||
import { Faction } from "./Faction/Faction";
|
||||
import { safetlyCreateUniqueServer } from "./Server/ServerHelpers";
|
||||
import { SpecialServers } from "./Server/data/SpecialServers";
|
||||
|
||||
/* SaveObject.js
|
||||
* Defines the object used to save/load games
|
||||
@@ -434,6 +443,22 @@ function evaluateVersionCompatibility(ver: string | number): void {
|
||||
Player.reapplyAllAugmentations(true);
|
||||
Player.reapplyAllSourceFiles();
|
||||
}
|
||||
if (ver < 18) {
|
||||
// Create the darkweb for everyone but it won't be linked
|
||||
const dw = GetServer(SpecialServers.DarkWeb);
|
||||
if (!dw) {
|
||||
const darkweb = safetlyCreateUniqueServer({
|
||||
ip: createUniqueRandomIp(),
|
||||
hostname: SpecialServers.DarkWeb,
|
||||
organizationName: "",
|
||||
isConnectedTo: false,
|
||||
adminRights: false,
|
||||
purchasedByPlayer: false,
|
||||
maxRam: 1,
|
||||
});
|
||||
AddToAllServers(darkweb);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user