Commit | Line | Data |
---|---|---|
5ffc51f0 KM |
1 | .\" Copyright (c) 1980 Regents of the University of California. |
2 | .\" All rights reserved. The Berkeley software License Agreement | |
3 | .\" specifies the terms and conditions for redistribution. | |
4 | .\" | |
6bc80c78 | 5 | .\" @(#)cribbage.6 6.2 (Berkeley) %G% |
5ffc51f0 | 6 | .\" |
76aad035 | 7 | .TH CRIBBAGE 6 "" |
5ffc51f0 KM |
8 | .UC 4 |
9 | .SH NAME | |
10 | cribbage \- the card game cribbage | |
11 | .SH SYNOPSIS | |
12 | .B /usr/games/cribbage | |
13 | [ | |
efbb7ae1 KM |
14 | .B \-req |
15 | ] | |
16 | .I name ... | |
5ffc51f0 KM |
17 | .SH DESCRIPTION |
18 | .I Cribbage | |
19 | plays the card game cribbage, with the program playing one hand | |
20 | and the user the other. The program will initially ask the user if | |
efbb7ae1 | 21 | the rules of the game are needed \- if so, it will print out |
5ffc51f0 KM |
22 | the appropriate section from |
23 | .I According to Hoyle | |
24 | with | |
25 | .I more (I). | |
26 | .PP | |
27 | .I Cribbage | |
28 | options include: | |
29 | .TP | |
30 | .B \-e | |
6bc80c78 | 31 | When the player makes a mistake scoring his hand or crib, provide an |
5ffc51f0 KM |
32 | explanation of the correct score. (This is especially useful for |
33 | beginning players.) | |
34 | .TP | |
35 | .B \-q | |
efbb7ae1 | 36 | Print a shorter form of all messages \- this is only recommended for |
5ffc51f0 KM |
37 | users who have played the game without specifying this option. |
38 | .TP | |
39 | .B \-r | |
40 | Instead of asking the player to cut the deck, the program will randomly | |
41 | cut the deck. | |
42 | .PP | |
43 | .I Cribbage | |
44 | first asks the player whether he wishes to play a short game | |
45 | (\*(lqonce around\*(rq, to 61) or a long game (\*(lqtwice around\*(rq, to 121). A | |
46 | response of `s' will result in a short game, any other response will | |
47 | play a long game. | |
48 | .PP | |
49 | At the start of the first game, the program | |
50 | asks the player to cut the deck to determine who gets the | |
51 | first crib. The user should respond with a number between 0 and | |
52 | 51, indicating how many cards down the deck is to be cut. The player | |
53 | who cuts the lower ranked card gets the first crib. | |
54 | If more than one game is played, the | |
55 | loser of the previous game gets the first crib in the current game. | |
56 | .PP | |
57 | For each hand, the program first prints the player's hand, | |
58 | whose crib it is, and then asks the player | |
59 | to discard two cards into the crib. The cards are prompted for | |
60 | one per line, and are typed as explained below. | |
61 | .PP | |
62 | After discarding, the program cuts the deck (if it is the player's | |
6bc80c78 | 63 | crib) or asks the player to cut the deck (if it's its crib); in the latter |
5ffc51f0 KM |
64 | case, the appropriate response is a number from 0 to 39 indicating |
65 | how far down the remaining 40 cards are to be cut. | |
66 | .PP | |
67 | After cutting the deck, play starts with the non-dealer (the person | |
68 | who doesn't have the crib) leading the first card. | |
69 | Play continues, as per cribbage, until all cards are exhausted. The | |
70 | program keeps track of the scoring of all points and the total of | |
71 | the cards on the table. | |
72 | .PP | |
73 | After play, the hands are scored. The program requests the player to | |
74 | score his hand (and the crib, if it is his) by printing out the | |
75 | appropriate cards (and the cut card enclosed in brackets). | |
76 | Play continues until one player reaches the game limit (61 or 121). | |
77 | .PP | |
78 | A carriage return when a numeric input is expected is equivalent | |
79 | to typing the lowest legal value; when cutting the deck this | |
80 | is equivalent to choosing the top card. | |
81 | .PP | |
82 | Cards are specified as rank followed by suit. The ranks may be specified | |
83 | as one of: | |
84 | `a', `2', `3', `4', `5', `6', `7', `8', `9', `t', `j', `q', and `k', | |
85 | or alternatively, one of: \*(lqace\*(rq, \*(lqtwo\*(rq, \*(lqthree\*(rq, \*(lqfour\*(rq, \*(lqfive\*(rq, \*(lqsix\*(rq, | |
86 | \*(lqseven\*(rq, \*(lqeight\*(rq, \*(lqnine\*(rq, \*(lqten\*(rq, \*(lqjack\*(rq, \*(lqqueen\*(rq, and \*(lqking\*(rq. | |
87 | Suits may be specified as: `s', `h', `d', and `c', or alternatively as: | |
88 | \*(lqspades\*(rq, \*(lqhearts\*(rq, \*(lqdiamonds\*(rq, and \*(lqclubs\*(rq. | |
89 | A card may be specified as: <rank> \*(lq \*(rq <suit>, or: <rank> \*(lq of \*(rq <suit>. | |
90 | If the single letter rank and suit designations are used, the space | |
91 | separating the suit and rank may be left out. Also, if only one card | |
92 | of the desired rank is playable, typing the rank is sufficient. | |
93 | For example, if your hand was \*(lq2H, 4D, 5C, 6H, JC, KD\*(rq and it was | |
94 | desired to discard the king of diamonds, any of the following could be typed: | |
95 | \*(lqk\*(rq, \*(lqking\*(rq, \*(lqkd\*(rq, \*(lqk d\*(rq, \*(lqk of d\*(rq, \*(lqking d\*(rq, \*(lqking of d\*(rq, \*(lqk diamonds\*(rq, | |
96 | \*(lqk of diamonds\*(rq, \*(lqking diamonds\*(rq, or \*(lqking of diamonds\*(rq. | |
97 | .SH FILES | |
98 | .ta 2i | |
99 | /usr/games/cribbage | |
efbb7ae1 KM |
100 | .SH AUTHORS |
101 | Earl T. Cohen wrote the logic. | |
102 | Ken Arnold added the screen oriented interface. |