Chess programmed by Kenneth Silverman
Documentation written on: 03/25/1999

COMMAND LINE OPTIONS:
>Chess [whiteplayer] [blackplayer]

Meanings of whiteplayer and blackplayer values:
	0: human controlled
	1: Extremely stupid computer           (Thinks 1 move  ahead: Me)
	2: Pretty stupid computer              (Thinks 2 moves ahead: Me,You)
	3: Stupid computer                     (Thinks 3 moves ahead: Me,You,Me)
	4: Ok, I guess computer                (Thinks 4 moves ahead: Me,You,Me,You)
	5: Good computer, but takes a long time
 6-8: Congratulations - you found a new way to lock up your computer (unless
		 of course you have a Pentium VII running at 100 Gigahertz.)

If you negate the first option, then the 2nd option is a time-out
	length (120 per second)  When the timer runs out, the computer selects
	a move for you.  Of course the computer uses "extremely stupid" mode as
	a way of punishing you for taking too long.

Examples:
	"chess 0 4": the default, where you (white) play a 4-move ahead computer
	"chess 3 4": Watch the white computer lose to the smarter black computer.
	"chess -2 600": A timed game against a pretty stupid computer where
		 you have 5 seconds to move before the computer picks a really stupid
		 move for you.

CONTROLS:
	Drag mouse with left button to move pieces.
	Hold right mouse button down on your own piece to see its possible moves.
	H - Press 'H', then press a number from 1-8 to get a hint from the computer.
		 The number you press is the computer smartness, so as usual don't press
		 6-8 unless you have a Pentium VII running at 100 Gigahertz.
	BACKSPACE - take back 2 moves
	TAB - type messages to other player (for network/modem games)
	ESC - quit

COMMENTS ABOUT MY CHESS ALGORITHM:
- I use a brute force algorithm - a minimax game search tree.  I do not use
	pruning, meaning that a computer opponent rated at 4 moves ahead will
	actually search through all branches at 4 levels.  Also, my algorithm
	keeps score about its position only on the number of pieces each player
	has.  Pawn:1,Bishop&Knight:3,Rook:5,Queen:15,King:1024
	Statistics of the search process are shown in the bottom-left corner as it
	progresses.  Choose computer level 5 if you want to watch them.  The first
	number is number of nodes (possible chess boards) searched.  The second is
	the change in score at that point.

- Capturing pieces "en passant" is not supported in this version.

- Castling can be done whenever the King and Rook are in the correct position
	and there are no pieces in between them.  This is not consistent with the
	official rules of chess.  However since the computer is going to "cheat",
	you may as well make it fair and "cheat" yourself.

- The computer evaluates moves on the order of something like 50^n where n is
	the number of moves ahead it thinks.  50 is just some average guess that
	I came up with.  On the first move, there are 20 possible moves.  This
	number increases quickly when queens open up, and then goes back down as
	pieces get captured.

SETUP PROGRAM:
	I used a setup program from another game of mine.  Most of the options don't
even apply to this chess game.  Here's a list of what does apply to this game:

 - Digitized sound can be either: No sound, Sound Blaster, or PC speaker
		(PC speaker will only work well in non-multitasking environments)
 - Define Keys menu: 1 key is selectable - the message typing key (TAB).
 - Communcations menu should work except that since the error correction
		scheme is designed for a continuous stream of packets.  Chess only sends
		packets when you make a move or type messages (use TAB key to type
		messages to the other player)  If it seems that the other player takes
		too long to move, make some packets by typing messages.  Chess can be
		played over a modem if you connect in another communications program and
		then quit it without hanging up.

	Please keep in mind that this Chess program was not intended to be a fully
operational program.  Many parts of it, such as the communications code and
sound code were taken from other programs, specially programmed for other
applications.  Also it's a few years old.
