From 40f2d16f4444255afdb93244ee33f3083244e0b3 Mon Sep 17 00:00:00 2001 From: SagePtr Date: Sat, 29 Jan 2022 18:10:59 +0200 Subject: [PATCH] Show "Can run scripts" to "NO" for zero-RAM servers in "analyze" command --- src/Terminal/Terminal.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Terminal/Terminal.ts b/src/Terminal/Terminal.ts index d21c8e1c3..043767686 100644 --- a/src/Terminal/Terminal.ts +++ b/src/Terminal/Terminal.ts @@ -314,7 +314,9 @@ export class Terminal implements ITerminal { this.print("Organization name: " + (!isHacknet ? org : "player")); const hasAdminRights = (!isHacknet && currServ.hasAdminRights) || isHacknet; this.print("Root Access: " + (hasAdminRights ? "YES" : "NO")); - this.print("Can run scripts on this host: " + (hasAdminRights ? "YES" : "NO")); + const canRunScripts = hasAdminRights && currServ.maxRam > 0; + this.print("Can run scripts on this host: " + (canRunScripts ? "YES" : "NO")); + this.print("RAM: " + numeralWrapper.formatRAM(currServ.maxRam)); if (currServ instanceof Server) { this.print("Backdoor: " + (currServ.backdoorInstalled ? "YES" : "NO")); const hackingSkill = currServ.requiredHackingSkill;