From: Jason Woofenden Date: Tue, 26 Nov 2013 17:01:14 +0000 (-0500) Subject: deselect when clicking disabled tiles X-Git-Url: https://jasonwoof.com/gitweb/?p=hexbog.git;a=commitdiff_plain;h=763be368fc0ded853123b4d16afebef839f47d05;hp=fff2ed1a0a156da47c7fa1e9760c8546b9af44fe deselect when clicking disabled tiles --- diff --git a/main.coffee b/main.coffee index 900295d..6f0cd18 100644 --- a/main.coffee +++ b/main.coffee @@ -649,7 +649,7 @@ new_tile = (space, y) -> space.tile = tile html_tile.click -> - return if tile.hp < 1 + return unselect_all() if tile.hp < 1 word = selected_word() if tile in selected if selected_word().length > 2 and is_word(word) and tile is selected.last()