SCRIPTS: Script modules are reused when they are imported (#461)

Also corrects some compile race conditions.
This commit is contained in:
Snarling
2023-04-07 00:33:51 -04:00
committed by GitHub
parent f5cddb6984
commit 04d49e3a6d
67 changed files with 428 additions and 561 deletions

View File

@@ -191,6 +191,8 @@ export function prestigeSourceFile(flume: boolean): void {
// Reset home computer (only the programs) and add to AllServers
AddToAllServers(homeComp);
prestigeHomeComputer(homeComp);
// Ram usage needs to be cleared for bitnode-level resets, due to possible change in singularity cost.
for (const script of homeComp.scripts) script.ramUsage = undefined;
// Re-create foreign servers
initForeignServers(Player.getHomeComputer());