From 4ffe5508dcef66cbffd3ae34fdcd5292496e178a Mon Sep 17 00:00:00 2001 From: zeddrak <57454318+zeddrak@users.noreply.github.com> Date: Sat, 22 Jan 2022 14:47:33 -0800 Subject: [PATCH] HacknetServer Grow/Weaken error messages It may be intentional to use hack for all 3 (ie, assume the player makes the connection that can't hack, also means can't grow or weaken), in which case, disregard. On the other hand, it could've easily been a copy/paste artifact, and this would be more explicitly clear, so thought it was worth bringing up. --- src/Terminal/Terminal.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Terminal/Terminal.ts b/src/Terminal/Terminal.ts index 806e79fa7..c46399400 100644 --- a/src/Terminal/Terminal.ts +++ b/src/Terminal/Terminal.ts @@ -143,7 +143,7 @@ export class Terminal implements ITerminal { startGrow(player: IPlayer): void { const server = player.getCurrentServer(); if (server instanceof HacknetServer) { - this.error("Cannot hack this kind of server"); + this.error("Cannot grow this kind of server"); return; } if (!(server instanceof Server)) throw new Error("server should be normal server"); @@ -152,7 +152,7 @@ export class Terminal implements ITerminal { startWeaken(player: IPlayer): void { const server = player.getCurrentServer(); if (server instanceof HacknetServer) { - this.error("Cannot hack this kind of server"); + this.error("Cannot weaken this kind of server"); return; } if (!(server instanceof Server)) throw new Error("server should be normal server"); @@ -241,7 +241,7 @@ export class Terminal implements ITerminal { if (cancelled) return; if (server instanceof HacknetServer) { - this.error("Cannot hack this kind of server"); + this.error("Cannot grow this kind of server"); return; } if (!(server instanceof Server)) throw new Error("server should be normal server"); @@ -268,7 +268,7 @@ export class Terminal implements ITerminal { if (cancelled) return; if (server instanceof HacknetServer) { - this.error("Cannot hack this kind of server"); + this.error("Cannot weaken this kind of server"); return; } if (!(server instanceof Server)) throw new Error("server should be normal server");