From: Christian Heller Date: Fri, 11 Dec 2020 06:23:14 +0000 (+0100) Subject: Fix face pop-ups on non-faces. X-Git-Url: https://plomlompom.com/repos/%7B%7Bprefix%7D%7D/process?a=commitdiff_plain;h=075ed2b9529e52ab8a5075d56d77e09d2191d9c7;p=plomrogue2 Fix face pop-ups on non-faces. --- diff --git a/rogue_chat.html b/rogue_chat.html index 781fc63..ba49e86 100644 --- a/rogue_chat.html +++ b/rogue_chat.html @@ -1134,7 +1134,7 @@ let tui = { }, draw_face_popup: function() { const t = game.things[this.draw_face]; - if (!t) { + if (!t || !t.face) { this.draw_face = false; return; } diff --git a/rogue_chat_curses.py b/rogue_chat_curses.py index 983a422..fdfc2bc 100755 --- a/rogue_chat_curses.py +++ b/rogue_chat_curses.py @@ -966,7 +966,7 @@ class TUI: def draw_face_popup(): t = self.game.get_thing(self.draw_face) - if not t: + if not t or not hasattr(t, 'face'): self.draw_face = False return