summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--chess-algebraic.el2
-rw-r--r--chess-engine.el1
2 files changed, 2 insertions, 1 deletions
diff --git a/chess-algebraic.el b/chess-algebraic.el
index b7038cd..7aebdf3 100644
--- a/chess-algebraic.el
+++ b/chess-algebraic.el
@@ -73,7 +73,7 @@ This regexp handles both long and short form.")
(setq source (aref source 0)))
(let (candidates which)
(unless (< piece ?a)
- (setq piece ?P))
+ (setq source piece piece ?P))
;; we must use our knowledge of how pieces can
;; move, to determine which piece is meant by the
;; piece indicator
diff --git a/chess-engine.el b/chess-engine.el
index 23622ed..396b6c4 100644
--- a/chess-engine.el
+++ b/chess-engine.el
@@ -71,6 +71,7 @@
(let ((game (chess-engine-game nil)))
(when (and game (chess-game-get-data game 'my-color)
(= (chess-game-index game) 0))
+ (message "Your opponent played the first move, you are now black")
(chess-game-run-hooks game 'pass)
;; if no one else flipped my-color, we'll do it
(if (chess-game-get-data game 'my-color)