From c1b934d988f7e21d28ec0b84e2792e638fab2b31 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Sat, 3 Sep 2022 15:05:31 +0200 Subject: Close stack by clicking inactive units in open stack. --- play.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/play.js b/play.js index a87abbb..76edae8 100644 --- a/play.js +++ b/play.js @@ -292,7 +292,8 @@ function on_click_unit(evt) { hide_supply() evt.stopPropagation() if (focus_stack(evt.target.stack, evt.target.hex)) - send_action('unit', evt.target.unit) + if (!send_action('unit', evt.target.unit)) + blur_stack() } } -- cgit v1.2.3