From 1115fdca9304abdf8a4cb15df30f9015b32e572b Mon Sep 17 00:00:00 2001 From: Christian Heller Date: Sun, 1 Nov 2020 04:31:53 +0100 Subject: [PATCH] Add terrain info. --- new2/rogue_chat_nocanvas_monochrome.html | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/new2/rogue_chat_nocanvas_monochrome.html b/new2/rogue_chat_nocanvas_monochrome.html index 37930ce..a4aa85d 100644 --- a/new2/rogue_chat_nocanvas_monochrome.html +++ b/new2/rogue_chat_nocanvas_monochrome.html @@ -528,12 +528,14 @@ let explorer = { }, get_info: function() { let info = ""; + let position_i = this.position[0] * game.map_size[1] + this.position[1]; + info += "TERRAIN: " + game.map[position_i] + "\n"; for (let t_id in game.things) { let t = game.things[t_id]; if (t.position[0] == this.position[0] && t.position[1] == this.position[1]) { - info += "PLAYER"; + info += "PLAYER @"; if (t.name_) { - info += " " + t.name_; + info += ": " + t.name_; } info += "\n"; } -- 2.30.2