A Case Study. Overview. References. Video poker Poker.Card & Poker.Hand General.dll & game variants

Similar documents
PROBLEM SET 2 Due: Friday, September 28. Reading: CLRS Chapter 5 & Appendix C; CLR Sections 6.1, 6.2, 6.3, & 6.6;

Problem Set 4: Video Poker

CS Project 1 Fall 2017

CS Programming Project 1

Project 2 - Blackjack Due 7/1/12 by Midnight

Poker: Further Issues in Probability. Poker I 1/29

Programming Assignment 4

DELIVERABLES. This assignment is worth 50 points and is due on the crashwhite.polytechnic.org server at 23:59:59 on the date given in class.

In 2004 the author published a paper on a

After receiving his initial two cards, the player has four standard options: he can "Hit," "Stand," "Double Down," or "Split a pair.

Poker Hands. Christopher Hayes

9 Video Poker Paytables in 1 Game Ultimate X Triple Play Draw Poker provides a rich selection of the most popular video poker paytables:

More Probability: Poker Hands and some issues in Counting

{ a, b }, { a, c }, { b, c }

Poker Hand Rankings Highest to Lowest A Poker Hand s Rank determines the winner of the pot!

Problem A. Worst Locations

Cashback Blackjack TO PLAY THE GAME. The objective of the game is to get closer to 21 than the dealer without going over.

FLOP POKER. Rank-- or ranking means the relative position of a card or hand as set forth in Section 5.

13:69E-1.13Z Criss cross poker; physical characteristics

CATFISH BEND CASINOS RULES OF THE GAME THREE CARD POKER

GAMBLING ( ) Name: Partners: everyone else in the class

CATFISH BEND CASINOS, L.C. RULES OF THE GAME FOUR CARD POKER

FOUR CARD POKER. Hand-- means the best four card poker hand that can be formed by each player and the dealer from the cards they are dealt.

6/24/14. The Poker Manipulation. The Counting Principle. MAFS.912.S-IC.1: Understand and evaluate random processes underlying statistical experiments

HEADS UP HOLD EM. "Cover card" - means a yellow or green plastic card used during the cut process and then to conceal the bottom card of the deck.

CHAPTER 649a. THREE CARD POKER

ULTIMATE TEXAS HOLD EM

Electronic Wireless Texas Hold em. Owner s Manual and Game Instructions #64260

Maryland State Lottery and Gaming Control Agency Standard Rules - Double Draw Poker

Problem A: Code Breaking

TEXAS HOLD EM BONUS POKER

LET IT RIDE POKER. Stub-- means the remaining portion of the deck after all cards in the round of play have been dealt or delivered.

Ante or ante wager means the initial wager required to be made prior to any cards being dealt in order to participate in the round of play.

To play the game player has to place a bet on the ANTE bet (initial bet). Optionally player can also place a BONUS bet.

FAST ACTION HOLD EM. Copy hand-- means a five-card hand of a player that is identical in rank to the five-card hand of the dealer.

TABLE GAMES RULES OF THE GAME

Counting Poker Hands

Maryland State Lottery and Gaming Control Agency Standard Rules Criss Cross Poker

Chapter 4: Probability

The Birds of a Feather Research Challenge. Todd W. Neller Gettysburg College November 9 th, 2017

characteristics; computerized random number generator (b) The layout for an Asia poker table shall contain, at a

Players try to obtain a hand whose total value is greater than that of the house, without going over 21.

CARIBBEAN. The Rules

CSCI 4150 Introduction to Artificial Intelligence, Fall 2004 Assignment 7 (135 points), out Monday November 22, due Thursday December 9

HOW to PLAY TABLE GAMES

Live Casino game rules. 1. Live Baccarat. 2. Live Blackjack. 3. Casino Hold'em. 4. Generic Rulette. 5. Three card Poker

MODEL IWTI-01

Bonus Side Bets Analysis

Chapter 2 Integers. Math 20 Activity Packet Page 1

Analysis For Hold'em 3 Bonus April 9, 2014

Texas Hold em Poker Basic Rules & Strategy

HIGH CARD FLUSH 1. Definitions

Welcome to the Best of Poker Help File.

Sheepshead, THE Game Release Notes

Activity 6: Playing Elevens

TABLE OF CONTENTS TEXAS HOLD EM... 1 OMAHA... 2 PINEAPPLE HOLD EM... 2 BETTING...2 SEVEN CARD STUD... 3

Activity 1: Play comparison games involving fractions, decimals and/or integers.

Bridge Tutor 1. lad1elhaek A DIVISION OF TANDY CORPORATION FORT WORTH, TEXAS 76102

Item Description - MC Phi - Please note: any activity that is not completed during class time may be set for homework or undertaken at a later date.

The student will explain and evaluate the financial impact and consequences of gambling.

The game of poker. Gambling and probability. Poker probability: royal flush. Poker probability: four of a kind

Texas Hold'em $2 - $4

Math 2 Proportion & Probability Part 3 Sums of Series, Combinations & Compound Probability

No Flop No Table Limit. Number of

A. Rules of blackjack, representations, and playing blackjack

2016 CCSC Eastern Conference Programming Competition

Simple Poker Game Design, Simulation, and Probability

Today s Topics. Sometimes when counting a set, we count the same item more than once

13:69E 1.13Z 5 Card Hi Lo table; physical characteristics. (a) 5 card hi lo shall be played at a table having on one side

10, J, Q, K, A all of the same suit. Any five card sequence in the same suit. (Ex: 5, 6, 7, 8, 9.) All four cards of the same index. (Ex: A, A, A, A.

Poker: Probabilities of the Various Hands

Think and Play. Defence against Trump Contracts

CATFISH BEND CASINOS, L.C. RULES OF THE GAME FORTUNE PAI GOW

BLACKJACK Perhaps the most popular casino table game is Blackjack.

HOW TO PLAY BLACKJACK

CRISS-CROSS POKER. Community cards Cards which are used by all players to form a five-card Poker hand.

Make better decisions. Learn the rules of the game before you play.

CS 210 Fundamentals of Programming I Fall 2015 Programming Project 8

LET S PLAY PONTOON. Pontoon also offers many unique payouts as well as a Super Bonus of up to $5000 on certain hands.

Texas Hold em Poker Rules

2. A separate designated betting area at each betting position for the placement of the ante wager;

STReight Gambling game

Here are two situations involving chance:

CHAPTER 69F RULES OF THE GAMES

NUMB3RS Activity: A Bit of Basic Blackjack. Episode: Double Down

CS 210 Fundamentals of Programming I Spring 2015 Programming Assignment 8

Ultimate Texas Hold em features head-to-head play against the player/dealer and optional bonus bets.

A UNIQUE COMBINATION OF CHANCE & SKILL.

CHAPTER 592. CRISS-CROSS POKER

Poker: Probabilities of the Various Hands

POKER. Bet-- means an action by which a player places gaming chips or gaming plaques into the pot on any betting round.

Mathematical Analysis Player s Choice Poker

Presentation Notes. Frozen suits

Poker Rules Friday Night Poker Club

Welcome to the Casino Collection Help File.

Problems. High School Programming Tournament. acm. YnE. Seventh Annual University of Central Florida

10 Game. Chapter. The PV Unit comes with two built-in games for your enjoyment. The games are named Game-1 and Game-2.

Ch. 653a ULTIMATE TEXAS HOLD EM POKER a.1. CHAPTER 653a. ULTIMATE TEXAS HOLD EM POKER

Up & Down GOAL OF THE GAME UP&DOWN CARD A GAME BY JENS MERKL & JEAN-CLAUDE PELLIN ART BY CAMILLE CHAUSSY

Description. Color of cutting card: An automated card shuffling device shall be utilized.

Transcription:

A Case Study Overview Video poker Poker.Card & Poker.Hand General.dll & game variants References Fergal Grimes, Microsoft.NET for Programmers, Manning, 2002 Jeffrey Richter, Applied Microsoft.NET Framework Programming, Microsoft Press, 2002 Andrew Troelsen, C# and the.net Platform, Apress, 2001

Video Poker Video Poker is a game that has been developed to increase the profits of casinos. In fact, now it accounts for a greater share of income than traditional slot machines. The rules: You play against the machine, which acts as dealer and you insert money to receive credits. Then you make a bet and hit the Deal button. The machine displays five cards from the deck. The idea is to make the best possible poker hand out of these five cards by holding onto the best cards and drawing replacements for those you wish to discard. (final drawing) If you win, you winnings are calculated by multiplying the score for the final (winning) hand by the amount of your bet.

Rule Of Thumb The casino always wins. The game is designed to make a guaranteed profit (say 25%). The game uses a Target Margin, a House Margin, and a Bias to adjust the strategy of the poker machine, in case the house margin is smaller than the target margin.

A Windows Forms Version GUI Help Statistics

Winning Poker Hands Hand Example Score Description Royal Flush TD JD QD KD AD 10 A straight to the ace in the same suit Straight Flush 3H 4H 5H 6H 7H 9 A straight in the same suit Four of a Kind 5C 5D 5H 5S QH 8 Four cards of the same number Full House KC KH KD 8C 8S 7 Three of a kind with any pair Flush 9S 3S QS TS AS 6 5 cards of the same suit Straight 8C 9S TC JC QH 5 5 cards with consecutive numbers Three of a Kind TD 4C 4S 3S 4D 4 Three cards of the same number Two Pair AD QH QD 7C 7D 3 Any pair with any pair Jacks or Better KD 8C 7D KS 5C 2 A pair of jacks, queens, kings, or aces

Card Encoding Suits Spades Encoding 2S-9S, TS, DS, KS, AS Example QS: Hearts 2H-9H, TH, QH, KH, AH 5H: Diamonds 2D-9D, TD, QD, KD, AD KD: Clubs 2C-9C, TC, QC, KC, AC TC:

Designing the Card Class Card objects are immutable. As in a real game cards drawn from the deck cannot be altered. A card has three public read-only properties: int Number: card number 2-14 (2-9, T, Q, K, A) int Suit: suit number 0-3 (C, D, H, S) string Name: two-character card identifier The class Card defines one constructor, which uses a card name as parameter.

Designing the Hand Class A hand always consists of 5 cards. The Video Poker's internal dealer initially shuffles the card set and deals 5 cards. The user can discard none, some, or all of these cards in an attempt to improve the hand s score. The Hand class contains a private array of 5 Card objects and three public getters: Score, Title, and Text The Hand class implements the poker game logic. That is, it defines a (private) method to calculate the score of a given hand.

Designing the Dealer Class The Dealer class implements a simple Video Poker machine. The Dealer class implements the Singleton pattern. So, only one instance exists at runtime. The dealer controls the card set. The dealer shuffles this set each time a new game is started. The Dealer class implements three public methods: Deal, ReplaceCards, and ReturnCards.

Design Rationale We want to support as many as possible user interfaces / clients. Video Poker is a N-tier application. It has a data layer, a logic layer, and an interface layer. A string interface supports best all needs!

General.dll The General.dll assembly provides the a simple poker machine (a dealer), which can deal and draw cards. The first General.dll does not provide any abstractions to record game history or to do profit calculations. The final version of General.dll will implement the data layer and the logic layer.

Video Poker History Poker.dll Data Layer Bank Logic Layer Card Hand Bet MsgLog Dealer Interface Layer SimPok COMPok RemPok QuePok WinPok MobPok IEPok ConPok SvcPok WSPok WebPok

VideoPoker