summaryrefslogtreecommitdiff
path: root/chess-none.el
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2002-04-13 08:27:24 +0000
committerJohn Wiegley <johnw@newartisans.com>2002-04-13 08:27:24 +0000
commit9b3364910b621d1ddbd350300c8da153fdaa2a6e (patch)
tree0f823feddd5fe57f72c7eeab1085c1c661714b0a /chess-none.el
parentacd0fdb7106a8b49f27a74987d28e22315bbc471 (diff)
displays and engines now always have a single object associated with
them
Diffstat (limited to 'chess-none.el')
-rw-r--r--chess-none.el13
1 files changed, 6 insertions, 7 deletions
diff --git a/chess-none.el b/chess-none.el
index db628bf..edd2a29 100644
--- a/chess-none.el
+++ b/chess-none.el
@@ -7,17 +7,16 @@
(require 'chess-engine)
(defun chess-none-handler (event &rest args)
- "Initialize the network chess engine."
+ "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 'send))
-
((memq event '(resign abort))
- (and (chess-engine-game nil)
- (chess-engine-set-start-position nil)))
+ (chess-engine-set-position nil))
((eq event 'undo)
- (if (chess-engine-game nil)
- (chess-game-undo (chess-engine-game nil) (car args))))))
+ (chess-game-undo chess-engine-game (car args)))))
(provide 'chess-none)