summaryrefslogtreecommitdiff
path: root/chess-ics.el
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2002-04-26 03:27:40 +0000
committerJohn Wiegley <johnw@newartisans.com>2002-04-26 03:27:40 +0000
commit0e302a828c7e79491b5055cbeb0d8879cc3d8558 (patch)
tree3b666f8db828ec78a449e2cad38a328c190a1985 /chess-ics.el
parent738ff9a3b57b5e317e086a9ee4878fbb45f24b3e (diff)
fixes
Diffstat (limited to 'chess-ics.el')
-rw-r--r--chess-ics.el16
1 files changed, 10 insertions, 6 deletions
diff --git a/chess-ics.el b/chess-ics.el
index 0f80cba..1341ae1 100644
--- a/chess-ics.el
+++ b/chess-ics.el
@@ -107,7 +107,7 @@ The list is comprised of: the ply the string represents, who is white,
who is black."
(let ((parts (split-string string " "))
(position (chess-pos-create t))
- white black white-time black-time move)
+ white black white-time black-time move status)
(assert (= (length parts) 32))
@@ -245,18 +245,22 @@ who is black."
;; causal ply
(car (last (chess-game-plies game))))
(nth 1 info) t)))
- (setq error 'setting-white-remaining)
(chess-game-set-data game 'white-remaining (nth 4 info))
- (setq error 'setting-black-remaining)
(chess-game-set-data game 'black-remaining (nth 5 info))
(setq error 'applying-move)
(chess-game-move game ply)
(setq error nil))
(setq error nil))
- (let ((chess-game-inhibit-events t) plies)
+ (let ((chess-game-inhibit-events t)
+ (color (chess-pos-side-to-move (nth 0 info)))
+ plies)
(when (or (= 1 (nth 6 info)) (= -1 (nth 6 info)))
- (chess-game-set-data game 'my-color (= 1 (nth 6 info)))
- (chess-game-set-data game 'active t))
+ (chess-game-set-data game 'my-color (if (= 1 (nth 6 info))
+ color
+ (not color)))
+ (chess-game-set-data game 'active t)
+ (chess-game-set-data game 'white-remaining (nth 4 info))
+ (chess-game-set-data game 'black-remaining (nth 5 info)))
(chess-game-set-tag game "White" (nth 2 info))
(chess-game-set-tag game "Black" (nth 3 info))
(chess-game-set-tag game "Site" (car chess-ics-server))