From: Christian Heller Date: Thu, 29 Oct 2020 02:13:34 +0000 (+0100) Subject: Improve help text, mode switching chars. X-Git-Url: https://plomlompom.com/repos/?p=plomrogue2-experiments;a=commitdiff_plain;h=3b4892919c8d26d3fd23735bca93575a0d6f42b6 Improve help text, mode switching chars. --- diff --git a/new2/rogue_chat_nocanvas_monochrome.html b/new2/rogue_chat_nocanvas_monochrome.html index e46daac..6508796 100644 --- a/new2/rogue_chat_nocanvas_monochrome.html +++ b/new2/rogue_chat_nocanvas_monochrome.html @@ -264,27 +264,23 @@ let tui = { }, log_help: function() { this.log_msg(""); - this.log_msg("HELP"); - this.log_msg(""); + this.log_msg("HELP:"); this.log_msg("chat mode commands:"); - this.log_msg(":nick NAME - re-name yourself to NAME"); - this.log_msg(":msg USER TEXT - send TEXT to USER"); - this.log_msg(":help - show this help"); - this.log_msg(":play or :p - switch to play mode"); - this.log_msg(":study or :s - switch to study mode"); - this.log_msg(""); - this.log_msg("play mode commands:"); - this.log_msg("w, a, s, d - move avatar"); - this.log_msg("f - flatten surroundings"); - this.log_msg("e - write following ASCII character"); - this.log_msg("c - switch to chat mode"); - this.log_msg("? - switch to study mode"); - this.log_msg(""); - this.log_msg("study mode commands:"); - this.log_msg("w, a, s, d - move question mark"); - this.log_msg("A - annotate terrain"); - this.log_msg("c - switch to chat mode"); - this.log_msg("p - switch to play mode"); + this.log_msg(" :nick NAME - re-name yourself to NAME"); + this.log_msg(" :msg USER TEXT - send TEXT to USER"); + this.log_msg(" :help - show this help"); + this.log_msg(" :p or :play - switch to play mode"); + this.log_msg(" :? or :study - switch to study mode"); + this.log_msg("commands common to study and play mode:"); + this.log_msg(" w, a, s, d - move"); + this.log_msg(" c - switch to chat mode"); + this.log_msg("commands specific to play mode:"); + this.log_msg(" e - write following ASCII character"); + this.log_msg(" f - flatten surroundings"); + this.log_msg(" ? - switch to study mode"); + this.log_msg("commands specific to study mode:"); + this.log_msg(" A - annotate terrain"); + this.log_msg(" p - switch to play mode"); this.log_msg(""); }, draw_map: function() { @@ -411,8 +407,8 @@ server.websocket.onmessage = function (event) { tui.log_msg('@ ' + tokens[1]); } else if (tokens[0] === 'LOGIN_OK') { server.send(['GET_GAMESTATE']); - tui.log_help(); tui.log_msg('@ ' + tokens[1]); + tui.log_help(); tui.switch_mode(mode_chat); } else if (tokens[0] === 'ANNOTATION') { let position = parser.parse_yx(tokens[1]); @@ -504,7 +500,7 @@ document.addEventListener('keydown', (event) => { if (tokens[0][0] == ':') { if (tokens[0] == ':play' || tokens[0] == ':p') { tui.switch_mode(mode_play); - } else if (tokens[0] == ':study' || tokens[0] == ':s') { + } else if (tokens[0] == ':study' || tokens[0] == ':?') { tui.switch_mode(mode_study); } else if (tokens[0] == ':help') { tui.log_help();