/*
 *  File Name:		commands.h
 *  Purpose:		Describe commands sent between server and client.
 *  Created:		01 Dec 88
 *  Last Modified:	16 Aug 90
 *  Comments:
 *		Commands do not have a trailing newline.
 *
 *  History:
 *		01 Dec 88/JVE	Created.
 *		09 Jun 89/JVE	Segregated, added, and commented.
 *		18 Jun 89/JVE	Added WINNER.
 *		02 Oct 89/JVE	Added CASH, TURN, STAKE.
 *		16 Aug 90/JVE	Added control commands.
 */

/*
 *	Stuff for parsing messages.
 */

# define	DELIM		":\n\r"   /* player command delimiters */
# define	MAXFIELDS	10

/*
 *	Message verbs. BET and DISCARD are also objects of GET.
 */

# define	NAME			"NAME"		/* tells names of players */
# define	CARDS			"CARDS"		/* gives players cards */
# define	UPDATE			"UPDATE"	/* force update of display */
# define	ACTION			"ACTION"	/* tells what a player has done */
# define	SAY				"SAY"		/* player speaks */
# define	QUIT			"QUIT"		/* player quits/is told to quit */
# define	SITOUT			"SITOUT"	/* player pauses/is told to pause */
# define	RETURN			"RETURN"	/* player returns from pause */
# define	MESSAGE 		"MESSAGE"	/* other player or server speaks */
# define	RESULT			"RESULT"	/* gives players hands results */
# define	WINNER			"WINNER"	/* tells who won */
# define	CASH			"CASH"		/* tells how much cash a player has */
# define	STAKE			"STAKE"		/* tells how much player bet in hand */
# define	TURN			"TURN"		/* tells whose turn it is */
# define	GET				"GET"		/* action is requested of player */
# define	BET				"BET"		/* player bets/asked to bet */
# define	DISCARD			"DISCARD"	/* player discards/asked to discard */

/*
 *	Miscellaneous text defines.
 */

# define	SERVER			"SERVER"
# define	BET_OK			"OK"
# define	BET_ERROR		"ERROR"
# define	BET_NOT_ENOUGH	"That's not enough!"
# define	BET_TOO_MANY	"Sorry, no more raises allowed."
# define	BET_TOO_MUCH	"Raise limit exceeded."
# define	TABLE_FULL		"MESSAGE:SERVER:This table is full!"

/*
 *	Ask a player to discard.
 */

# define	GET_DISCARD	"GET:DISCARD"

/*
 *	Ask a player to bet.
 */

# define	GET_BET 	"GET:BET"

/*
 *	Control commands.
 */

# define	EVICT		"EVICT"			/* kick out specified player */
# define	SHUTDOWN	"SHUTDOWN"		/* server exit after this hand */
# define	DUMP		"DUMP"			/* dump vars (debugging) */
