merge dev

This commit is contained in:
Olivier Gagnon
2021-12-03 15:35:45 -05:00
472 changed files with 8880 additions and 1304 deletions
+3 -1
View File
@@ -242,6 +242,8 @@ export const RamCosts: IMap<any> = {
purchaseAugmentation: RamCostConstants.ScriptSingularityFn3RamCost,
softReset: RamCostConstants.ScriptSingularityFn3RamCost,
installAugmentations: RamCostConstants.ScriptSingularityFn3RamCost,
isFocused: 0.1,
setFocus: 0.1,
// Gang API
gang: {
@@ -295,7 +297,7 @@ export const RamCosts: IMap<any> = {
getTeamSize: RamCostConstants.ScriptBladeburnerApiBaseRamCost,
setTeamSize: RamCostConstants.ScriptBladeburnerApiBaseRamCost,
getCityEstimatedPopulation: RamCostConstants.ScriptBladeburnerApiBaseRamCost,
getCityEstimatedCommunities: RamCostConstants.ScriptBladeburnerApiBaseRamCost,
getCityCommunities: RamCostConstants.ScriptBladeburnerApiBaseRamCost,
getCityChaos: RamCostConstants.ScriptBladeburnerApiBaseRamCost,
getCity: RamCostConstants.ScriptBladeburnerApiBaseRamCost,
switchCity: RamCostConstants.ScriptBladeburnerApiBaseRamCost,
+1 -1
View File
@@ -5,7 +5,7 @@ export const recentScripts: RecentScript[] = [];
export function AddRecentScript(workerScript: WorkerScript): void {
if (recentScripts.find((r) => r.pid === workerScript.pid)) return;
recentScripts.push({
recentScripts.unshift({
filename: workerScript.name,
args: workerScript.args,
pid: workerScript.pid,
+3 -3
View File
@@ -195,14 +195,14 @@ export class WorkerScript {
return this.disableLogs[fn] == null;
}
log(func: string, txt: string): void {
log(func: string, txt: () => string): void {
if (this.shouldLog(func)) {
if (func && txt) {
this.scriptRef.log(`${func}: ${txt}`);
this.scriptRef.log(`${func}: ${txt()}`);
} else if (func) {
this.scriptRef.log(func);
} else {
this.scriptRef.log(txt);
this.scriptRef.log(txt());
}
}
}