From e66b028def9af45cc545c973255df42c9b90cde1 Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Fri, 12 Apr 2002 07:58:22 +0000 Subject: optimizations and bug fixes --- chess-engine.el | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'chess-engine.el') diff --git a/chess-engine.el b/chess-engine.el index 9a97cef..afa80d8 100644 --- a/chess-engine.el +++ b/chess-engine.el @@ -64,8 +64,8 @@ (chess-engine-position (setq chess-engine-position (chess-ply-next-pos ply))))) -(defsubst chess-engine-convert-algebraic (move) - (or (chess-algebraic-to-ply (chess-engine-position nil) move) +(defsubst chess-engine-convert-algebraic (move &optional trust-check) + (or (chess-algebraic-to-ply (chess-engine-position nil) move trust-check) (ignore (message "Received invalid move string: %s" move)))) @@ -156,7 +156,7 @@ (when game (if (y-or-n-p "Your opponent offers a draw, accept? ") (progn - (chess-game-draw game) + (chess-game-end game :draw) (chess-engine-command nil 'accept) (chess-game-set-data game 'active nil)) (chess-engine-command nil 'decline)) @@ -200,7 +200,7 @@ (cond ((eq chess-engine-pending-offer 'draw) (message "Your draw offer was accepted") - (chess-game-draw game) + (chess-game-end game :draw) (chess-game-set-data game 'active nil)) ((eq chess-engine-pending-offer 'abort) -- cgit v1.2.3