summaryrefslogtreecommitdiff
path: root/chess-common.el
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2002-04-19 07:53:38 +0000
committerJohn Wiegley <johnw@newartisans.com>2002-04-19 07:53:38 +0000
commit4e0af8d85ed9c1c8feb025abafe2dba87604ccb5 (patch)
tree5f1c83d3829350475e41abb3d3d5647f3dc276e6 /chess-common.el
parent5e7133d9e7a77ea970f5ba1cbf60fe5a2d26cf17 (diff)
Fixes and other work.
Diffstat (limited to 'chess-common.el')
-rw-r--r--chess-common.el11
1 files changed, 6 insertions, 5 deletions
diff --git a/chess-common.el b/chess-common.el
index d568dad..fb3a098 100644
--- a/chess-common.el
+++ b/chess-common.el
@@ -57,9 +57,6 @@
((eq event 'pass)
(chess-engine-send nil "go\n"))
- ((eq event 'resign)
- (chess-engine-send nil "resign\n"))
-
((eq event 'draw)
(chess-message 'draw-offer-declined))
@@ -78,9 +75,13 @@
(chess-game-undo game (car args))))
((eq event 'move)
- (if (= 1 (chess-game-index game))
- (chess-game-set-tag game "Black" chess-engine-opponent-name))
+ (if (= 0 (chess-game-index game))
+ (chess-game-set-tag game "White" chess-engine-opponent-name)
+ (if (= 1 (chess-game-index game))
+ (chess-game-set-tag game "Black" chess-engine-opponent-name)))
+
(chess-engine-send nil (concat (chess-ply-to-algebraic (car args)) "\n"))
+
(if (chess-game-over-p game)
(chess-game-set-data game 'active nil)))))