blob: 104d5249efaee3296bafb27d4aa9fd3e952f28ba (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;
;; A null engine, used when two humans play each on the same display.
;;
;; $Revision$
(require 'chess-engine)
(defun chess-none-handler (event &rest args)
"An empty chess engine, used for fielding key events.
This is only useful when two humans are playing each other, in which
case this engine will do the job of accepting undos, handling
resignations, etc."
(cond
((eq event 'initialize) t)
((memq event '(resign abort))
(chess-engine-set-position nil))
((eq event 'undo)
(chess-game-undo chess-engine-game (car args)))))
(provide 'chess-none)
;;; chess-none.el ends here
|