summaryrefslogtreecommitdiff
path: root/chess-common.el
diff options
context:
space:
mode:
Diffstat (limited to 'chess-common.el')
-rw-r--r--chess-common.el5
1 files changed, 5 insertions, 0 deletions
diff --git a/chess-common.el b/chess-common.el
index 462050f..ce320b4 100644
--- a/chess-common.el
+++ b/chess-common.el
@@ -83,6 +83,11 @@
(let ((chess-engine-handling-event t))
(chess-game-undo game (car args))))
+ ((eq event 'flag-fell)
+ (chess-game-set-data game 'active nil)
+ (let ((chess-game-inhibit-events t))
+ (chess-game-end game :flag-fell)))
+
((eq event 'move)
(when (= 1 (chess-game-index game))
(chess-game-set-tag game "White" chess-full-name)