Saving no longer saves logs of running scripts. Some more hacking augmentation nerfs. Reduced thread RAM cost multiplier from 1.02 to 1.01

This commit is contained in:
Daniel Xie
2017-06-18 04:31:14 -05:00
parent dc39b941dc
commit c2aa8d8110
6 changed files with 32 additions and 18 deletions
+14 -1
View File
@@ -17,7 +17,20 @@ function BitburnerSaveObject() {
BitburnerSaveObject.prototype.saveGame = function() {
this.PlayerSave = JSON.stringify(Player);
this.AllServersSave = JSON.stringify(AllServers);
//Delete all logs from all running scripts
TempAllServers = jQuery.extend(true, {}, AllServers); //Deep copy
for (var ip in TempAllServers) {
var server = TempAllServers[ip];
if (server == null) {continue;}
for (var i = 0; i < server.runningScripts.length; ++i) {
var runningScriptObj = server.runningScripts[i];
runningScriptObj.logs.length = 0;
runningScriptObj.logs = [];
}
}
this.AllServersSave = JSON.stringify(TempAllServers);
this.CompaniesSave = JSON.stringify(Companies);
this.FactionsSave = JSON.stringify(Factions);
this.SpecialServerIpsSave = JSON.stringify(SpecialServerIps);