Cadenza Cribbage (version 1.9, May 29, 1988) Hardware Requirements This program should run on any Atari ST computer with a monochrome monitor. This program MAY run on color monitors in medium resolution (please see the Bugs section below). Distribution of this Program Since Cadenza Cribbage is public domain, you may freely distribute copies of the program to other users, user groups, electronic bulletin boards, etc. The Rules of Cribbage Preliminaries Cribbage is a two player card game. The players take turns being the dealer. Cards are valued as follows: ace is worth 1, number cards are worth their face value, and tens and face cards are worth 10. The Deal When the game begins, the dealer first deals six cards to both players. Then each player selects two cards from his/her hand, and places them face down in a pile called the crib. After the crib is formed, the dealer cuts the rest of the pack, and turns up the top card of the lower portion. This card is called the starter. If the starter is a jack, the dealer scores two points "for his heels". Play After the deal is finished and the crib is formed, and the starter is turned up players alternately play one card, with the non- dealer playing first. This continues until a player, during his/her turn either cannot play without making the total of the played cards greater than 31 or is simply out of cards. At this point, if the player is not out of cards the player must say "go", and the player's opponent scores 1. After the go is called, the player who said "go" leads for another series of plays. The count starts at zero again, and as always, the total of the played cards cannot exceed 31. When a player says "go", that player's opponent must play until he/she is out of cards, or has no card that would not make the total of the played cards greater than 31. Consequently, this player could play more than one card. If a player cannot play because he/she has no cards, the other player plays out his/her hand, but is not given any additional score. As the player plays out his/her hand, if the total of the played cards would exceed 31, the played cards are moved away and the count starts at zero again. Scoring Scoring is done during play (see Scoring In Play), and also immediately after play ceases (see Showing). Scoring In Play When a player says "go", the other player scores 1. 31 A player scores 2 for bringing the total of the played cards to exactly 31. Last Card A player receives 1 for playing the last card, or 2 if this brings the total of played cards to exactly 31. 15s A player receives 2 for bringing the total of the played cards to exactly 15. Pairs If a player plays a card of the same rank as the card played immediately before (i.e. if the player forms a pair), the player scores 2. If the player plays a card of rank equal to the ranks of the previously played 2 cards, he/she scores 6. If the player plays a card of rank equal to the ranks of the previously played 3 cards, the player receives a score of 12. (Note that rank should not be confused with value: 10 and King are of equal value but different ranks). Runs If a player plays a card that results in a run of length greater than 2, the player receives a score equal to the number of cards in the run. The cards in the run need not be ordered, but there may not be any "foreign" cards in the middle of the run. For example, the player scores 3 for the following: A 3 5 7 6 (5, 7, & 6 form a 3-run) And the following is not a run: 5 J 6 7 (the Jack is foreign, so the 5, 6, & 7 do not form a run) Showing After play is complete, each player turns all of his/her cards face up, the crib is turned up, and additional scoring is done for each player. This process is called "showing". Cards are shown in the following order: non-dealer's hand, dealer's hand, and crib (which belongs to the dealer). For each hand (dealer's, non- dealer's, and crib) the starter forms a fifth card). The dealer receives the score for the crib. 15 Each combination of 15 scores 2 points. For example: Player's Hand Starter A 7 8 3 7 The player in the above example has 2 fifteens: 1: 7 & 8 both from player's hand 2: 8 from player's hand and 7 (starter) For the two fifteens, the player scores 4. Pairs A player scores 2 for each pair, 6 for each 3 of a kind, and 12 for each 4 of a kind. For example: Player's Hand Starter 4 5 5 5 3 In the above example, the player receives 6 for the 3 of a kind (i.e. the 3 5's). The player does not have any pairs (the 3 of a kind cannot be split to form pairs). If the player had 4 of a kind, it could not be split either. Runs For each combination that a player has that forms a run of length 3 or more, the player scores the length of the run. For example: Player's Hand Starter A 2 3 7 2 In the above example, the player has two 3-runs: 1: A 2 3 (all cards from player's hand) 2: A 2 3 (using the starter) The player then receives 6: 3 for either 3-run. Flush If the player has 4 cards of the same suit in his/her hand (not including the crib and starter), the player receives 4. If the starter is also of the same suit, the player receives 5. If the crib and starter are all of the same suit, the player receives 5. His Nobs If a player has a jack with the same suit as the starter, the player scores 1 for "his nobs". Game Length The game can be played "once around" or "twice around." If the game is played once around, play continues until one player achieves a score of 61 or more. If the game is played twice around (as is most often the case), play ceases when a player gets a score of 121 or greater. Lurch If the game is played once around and the loser receives a score less than 31, that player is "lurched", and the winner receives an additional game score. If the game is played twice around and the loser receives a score less than 61, the winner is given an additional game score for the lurch. Additional Information about Cribbage The following texts will provide additional information about the strategy of Cribbage: Hoyle's Modern Encyclopedia of Card Games (Highly Recommended) Walter B. Gibson Dolphin Books, Doubleday and Co., Inc., Garden City, New York ISBN 0-385-07680-0 Hoyle's Rules of Games, Second Revised Edition Albert H. Morehead and Geoffrey Mott-Smith Signet New American Library, NAL Penguin, Inc., New York ISBN 0-451-14842-8 Running the Program Once the program has been started you are ready to play. However, there are menus that will allow you to set the length of the game, disable or enable x-ray vision, and start a new game or quit the program. Menu options can be changed before the start of any game (not just before the first game). Menu options and desk accessories cannot be accessed in the middle of a game, however. The Game Length Menu This menu allows you to play a game to 121 (twice around) or to 61 (once around). By default the game will go to 121. The X-Ray Vision Menu Like Superman, you may choose to have x-ray vision which will allow you to see all of your opponent's cards. This feature is disabled by default. The Who Plays? Menu By default you play the computer. However, if you ever want to watch the computer play itself, select the "I play for you" submenu. The computer will play itself until you press the key. The Start/Stop Menu When you are ready to play a game (after the menu options are to your liking), select the Start New Game submenu. When you want to quit the program, select the Quit Program submenu. Screen Layout and Card Selection You and the computer will take turns being the dealer, but the computer is always the dealer for the first hand of a game. The scoreboard is displayed as follows: Me: / You: / RT: Throughout the program, the computer is referred to as "I", and the human player as "you". To select a card, place the mouse arrow on top of the desired card and then press and release the left mouse button. When you play a given card, it is turned over. If you attempt to play a card that cannot legally be played, the computer's bell will sound, and you will have to choose another card to play. The computer's cards are drawn in the uppermost row on the screen, and your cards are drawn immediately below them. The crib is drawn in a row below the computer's cards, and the starter is drawn below the crib, and to the right. As cards are played, they are drawn on the bottom of the screen from left to right. The human player's cards are drawn with solid borders, and the computer's cards have dotted borders. Quitting in the Middle of a Game You can quit in the middle of a game by pressing the UNDO key. However, after you press UNDO play will not end immediately - if you are in the middle of playing a hand, play will continue until that hand is completely finished. Pressing the UNDO will only allow you to quit the current game. If you want to quit the program, select the Quit Program menu option after you have quit the current game. Payment If you like this program, please send $5.00 US to the following address: Eric Bergman-Terrell Cadenza Software, Ltd. 1450 West 116th Avenue, #21 Westminster, CO 80234 U.S.A. For $10.00 + $2.00 postage you may order a disk containing the complete source code for this program, written in OSS Personal Pascal version 2.0. You may write to the same address to report bugs, request additional information, suggest improvements in the program, etc. If you want a reply, please include return postage (2 IRCs for those outside the U.S.A.). Bugs: When the computer plays the last card, and this brings the total of the played cards to 31, the user is obliged to press the left mouse button twice, rather than just once. This program frequently erases and redraws the screen. This may cause problems with some desk accessories. Since this program was developed on a monochrome system, there may be some bugs when it is run on a color monitor. Enjoy the program!