final specification kwangmonarchikhanjamesgraham

27
Final Final Specification Specification Kwang Kwang Monarch Monarch Ikhan Ikhan James James Graham Graham

Upload: ross-goodwin

Post on 17-Dec-2015

214 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Final Specification KwangMonarchIkhanJamesGraham

Final SpecificationFinal Specification

KwangKwangMonarchMonarchIkhanIkhanJamesJamesGrahamGraham

Page 2: Final Specification KwangMonarchIkhanJamesGraham

Waitlisted IdeasWaitlisted Ideas

Decided to put a few non-essential Decided to put a few non-essential features of the program on hold until the features of the program on hold until the program itself is working.program itself is working.

Includes networking, bluffing strategy, 3D Includes networking, bluffing strategy, 3D graphics, variable confidence meter.graphics, variable confidence meter.

Necessary elements of program include Necessary elements of program include Interface/Graphics, Deck randomization, Interface/Graphics, Deck randomization, Dealer functions, Computer AI.Dealer functions, Computer AI.

Page 3: Final Specification KwangMonarchIkhanJamesGraham

Dealer Functions

Graham Gimbert

James Ceferatti

Page 4: Final Specification KwangMonarchIkhanJamesGraham

The Deck-Standard 52 card deck-All players get 2 cards in their hand, and 5 on the table-A maximum of 25 cards dealt in

one hand-Total of 21 hand choices per player -Each card consists of a number

1-13, and a type “club” “heart” “spade” and “diamond”

Page 5: Final Specification KwangMonarchIkhanJamesGraham

Deck Mechanics

When a card is dealt, either to a player or to the table, it must be removed from the deck.

The actual deck can be represented as a look-up table, from which values can be taken from until a new hand is dealt.

How is a card chosen to be drawn?

Page 6: Final Specification KwangMonarchIkhanJamesGraham

Randomization

By using a random number generator, we can select cards to be dealt.

random.h is more than adequate for our needs.

Through modulus division we can restrict the values generated by the random function.

Page 7: Final Specification KwangMonarchIkhanJamesGraham

Dealing Algorithm

Need connection between dealer and graphics.

While dealing cards only the cards of the human player get shown.

Cards of the computer players are hidden.

Page 8: Final Specification KwangMonarchIkhanJamesGraham

Dealer Functions Dealer Functions (Cont)(Cont)

James CefarattiJames Cefaratti

Page 9: Final Specification KwangMonarchIkhanJamesGraham

General StrategyGeneral Strategy

Use a top-down approachUse a top-down approach Check for the royal flush first and then Check for the royal flush first and then

go down through possible hands go down through possible hands checking to see if the player has a checking to see if the player has a certain handcertain hand

Once each player’s hand is Once each player’s hand is determined, compare the players determined, compare the players hands to see who has the better handhands to see who has the better hand

Page 10: Final Specification KwangMonarchIkhanJamesGraham

Some Other RulesSome Other Rules

The algorithm should also check The algorithm should also check each player’s hand against the best each player’s hand against the best hand currently on the table. There is hand currently on the table. There is always the chance of a split pot.always the chance of a split pot.

Page 11: Final Specification KwangMonarchIkhanJamesGraham

Determining High CardsDetermining High Cards

Since each card has an explicit value Since each card has an explicit value 10, J, Q, K, A = 10, 11, 12, 13, 14. 10, J, Q, K, A = 10, 11, 12, 13, 14. Finding the highest flush, straight or Finding the highest flush, straight or even high card should be fairly even high card should be fairly straight forwardstraight forward

Simply compare the valuesSimply compare the values

Page 12: Final Specification KwangMonarchIkhanJamesGraham

Special CasesSpecial Cases

Since the algorithm compares the Since the algorithm compares the values on the card to determine high values on the card to determine high cards, the algorithm will have to take cards, the algorithm will have to take into account the ace, which can also into account the ace, which can also be used as 1 in a straight.be used as 1 in a straight.

Page 13: Final Specification KwangMonarchIkhanJamesGraham

Data Structures and AlgsData Structures and Algs

The algorithm will have to implement The algorithm will have to implement some data structures such as arrays some data structures such as arrays to store information about the handto store information about the hand

The algorithm will also have to The algorithm will also have to implement a fast sorting algorithm to implement a fast sorting algorithm to organize the cards before checking organize the cards before checking the two handsthe two hands

Page 14: Final Specification KwangMonarchIkhanJamesGraham

Computer Playing Computer Playing StrategyStrategy

Kwang KimKwang Kim

Devin GainesDevin Gaines

Page 15: Final Specification KwangMonarchIkhanJamesGraham

Computer Playing StrategyComputer Playing Strategy

• Weak players• Play less hands: see

less flops• Less likely to raise/bet• More likely to fold/call

• Tight players• Play less hands than

aggressive players, but more than weak players.

• More likely to bet/raise than weak players, but less than aggressive players.

Page 16: Final Specification KwangMonarchIkhanJamesGraham

Computer Playing StrategyComputer Playing Strategy

• Aggressive players

• Bet/raise the most frequently

• Least likely to fold, even with marginal hands

• How to implement these styles?

Page 17: Final Specification KwangMonarchIkhanJamesGraham

Computer Playing StrategyComputer Playing Strategy

• Each two card Hold’em hand has a specific strength, they can all be ranked in order from the statistically best hand to the worst hand.

• We will use these guidelines for the computer to play before the flop comes.

Page 18: Final Specification KwangMonarchIkhanJamesGraham

Computer Playing StrategyComputer Playing Strategy

• Example: ~9th

• Weak player folds preflop

• Tight player calls• Aggressive player

raises

Page 19: Final Specification KwangMonarchIkhanJamesGraham

Computer Playing StrategyComputer Playing Strategy

• Playing with community cards: Harder to implement than pre-flop strategy.

• Different algorithms will be needed for each style.

• The actions the computer does is based upon the current five card hand that the computer holds.

Page 20: Final Specification KwangMonarchIkhanJamesGraham

Computer Playing StrategyComputer Playing Strategy

Board:

Hand:

Weak player: check/fold

Tight: Bet/Call

Aggressive: Bet/raise

Page 21: Final Specification KwangMonarchIkhanJamesGraham

Graphics/InterfaceGraphics/Interface

IkhanIkhan

MonarchMonarch

Page 22: Final Specification KwangMonarchIkhanJamesGraham
Page 23: Final Specification KwangMonarchIkhanJamesGraham
Page 24: Final Specification KwangMonarchIkhanJamesGraham
Page 25: Final Specification KwangMonarchIkhanJamesGraham
Page 26: Final Specification KwangMonarchIkhanJamesGraham
Page 27: Final Specification KwangMonarchIkhanJamesGraham