Poker Networking Group S. Kofsky Request For Comments

Poker Networking Group
Request For Comments: 0143820
Obsoletes: 3423
Category: Standards Track
S. Kofsky
September 2006
Texas Hold’em Protocol – THP/1.0
Status of this Memo
This document specifies an Internet Standards track protocol for the internet
community, and requests for discussion and suggestions for improvements.
Copyright Notice
Copyright (C) Steve Kofsky (2006).
All Rights Reserved.
Abstract
The Texas Hold’em Protocol (THP) is an application-level protocol for
distributive Texas Hold’em Poker Games. It is a specific
protocol that keeps state
between the clients and the server.
Table of Contents
1. Introduction
1.1 Purpose
1.2 Requirements
1.3 Terminology
1.4 Overall Operation
2
Protocol Parameters
2.1 Card Syntax
2.2 Money Format
3
THP Client Messages
3.1 Login
3.2 Status
3.3 Bid
3.4 Fold
3.5 Logoff
4
THP Server Messages
4.1 New Round
4.2 Bid
4.3 Deal
4.4 Flop
4.5 Turn
4.6 River
4.7 Status
4.8 Winner
4.9 Boot
4.10 Error
1 Introduction
1.1 Purpose
The Texas Hold’em Protocol (THP) is an application-level protocol for
distributive Texas Hold’em Poker Games. It is a protocol that
allows multiple
clients to connect to a server to play Texas
Hold’em Poker. The protocol utilizes
a secure server that works as
the dealer to help reduce cheating. This protocol
uses TCP connections
between each client and the server/dealer.
1.2 Requirements
Applications should follow all of the guidelines outlined in this document in order
to allow multiple vendor support for this protocol.
1.3 Terminology
Client Message
A message sent from the client to the server
Server Message
A message sent from the server to the client
1.4 Overall Operation
THP is a client/server protocol. A client (or player) logons to the server. Then
the server tells the client when to bet or who is dealing. At any time the client
can request for the status of the game.
2 Protocol Parameters
2.1 Card Syntax
Poker is a card game, and as such a standard naming scheme for cards must be used.
The following standard must be followed:
[Card Name] [Suit]
The card name can be one of the following:
2, 3, 4, 5, 6, 7, 8, 9, 10, J, Q, K, A
(J, Q, K, A stand for Jack, Queen, King, Ace respectfully)
The suit can be one of the following:
C
D
H
S
–
–
–
Clubs
Diamonds
Hearts,
Spades
2.2 Money Format
All money is in dollars; however it is simply passed as a number for simplicity.
3 THP Client Messages
3.1 Login
Message:
LOGIN [User Name]
Used to initiate connection with the server. The player name cane be any valid
string without any carriage returns or line feeds.
3.2 Status
Message:
STATUS
Used to get the number of players, max number of players, the dealer, and the money
each player has. See STATUS in the THP Server Messages section.
3.3 Bid
Message:
BID [Dollars]
Used to send a bid to the server.
The amount must be in full dollar amounts.
3.4 Fold
Message:
FOLD
Tells the server that the client folds the current hand.
3.5 Logoff
Message:
LOGOFF
Alerts the server that the client is disconnecting.
required, but highly recommended.
This is not
4 THP Server Messages
4.1 New Round
Message:
NEW ROUND
DEALER [Dealer Player]
Alerts client of new round and informs them of the dealer
4.2 Bid
Message:
BID [Minimum Bid]
Alerts the player that they must bid at least the minimum bid.
the minimum bid is 10
For an
4.3 Deal
Message:
DEAL
[Card 1]
[Card 2]
Alerts the player of the cards that they have been dealt this round.
4.4 Flop
Message:
FLOP
[Card 1]
[Card 2]
[Card 3]
Shows the player the cards in the flop.
4.5 Turn
Message:
TURN
[Card 1]
Ante
Alerts the player of the card in the turn.
4.6 River
Message:
RIVER
[Card 1]
Alerts the player of the card in the river.
4.7 Status
Message:
STATUS
NAME [Server Name]
PLAYERS [Number of Players]
DEALER [Dealer Player]
[Player1 Name] [Player1 Money]
. . .
[PlayerN Name] [PlayerN Money]
4.8 Winner
Message:
WINNER
[Player Name] [Pot Size]
Alerts client of the winner of the round, and the amount of money the winner
won.
4.9 Boot
Message:
BOOT
[Message from server]
Alerts client that they have been kicked off of the server.
4.10 Error
Message:
ERROR [Code] [Message]
Alerts the client of an error.
following:
101
102
103
104
104
The error codes and messages can be any of the
Too many players
Insufficient funds
Bid out of turn
Higher Bid Required
Too many errors