diff options
Diffstat (limited to 'chess-phalanx.el')
| -rw-r--r-- | chess-phalanx.el | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/chess-phalanx.el b/chess-phalanx.el index 7b902a4..0eb3ae0 100644 --- a/chess-phalanx.el +++ b/chess-phalanx.el @@ -57,6 +57,12 @@ (and (chess-engine-game nil) (chess-engine-set-start-position nil))) + ((eq event 'undo) + (when (chess-engine-game nil) + (dotimes (i (car args)) + (chess-engine-send nil "undo\n")) + (chess-game-undo (chess-engine-game nil) (car args)))) + ((eq event 'move) (chess-engine-send nil (concat (chess-ply-to-algebraic (car args)) "\n"))))) |
