From 77d92cc43df05bebecde95f39074024f359ad1be Mon Sep 17 00:00:00 2001 From: Christian Heller Date: Wed, 9 Dec 2020 00:43:16 +0100 Subject: [PATCH] Fix web client moving player with explorer on move button press. --- rogue_chat.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/rogue_chat.html b/rogue_chat.html index 3b9238f..a28951a 100644 --- a/rogue_chat.html +++ b/rogue_chat.html @@ -1688,11 +1688,11 @@ document.getElementById("teleport").onclick = function() { for (const move_button of document.querySelectorAll('[id*="_move_"]')) { let direction = move_button.id.split('_')[2].toUpperCase(); move_button.onclick = function() { - if (tui.mode.available_actions.includes("move") - || tui.mode.available_actions.includes("move_explorer")) { + if (tui.mode.available_actions.includes("move")) { server.send(['TASK:MOVE', direction]); - } else { + } else if (tui.mode.available_actions.includes("move_explorer")) { explorer.move(direction); + tui.full_refresh(); }; }; }; -- 2.30.2