Commit | Line | Data |
---|---|---|
de5dd47d C |
1 | #include "back.h" |
2 | ||
3 | char *instr[] = { | |
4 | " If you did not notice by now, this program reacts to things as", | |
5 | "soon as you type them, without waiting for a newline. This means that", | |
6 | "the special characters RUBOUT, ESC, and CONTROL-D, will not perform", | |
7 | "their special functions during most of this program. The program", | |
8 | "should usually stop when a RUBOUT is typed, but occasionally it will", | |
9 | "ignore RUBOUTs until it is waiting for input.\n", | |
10 | " These instructions are presented in small chunks designed not to", | |
11 | "roll off the top of your screen. When the characters '-->' are print-", | |
12 | "ed, no more data will be printed until a space or newline is typed.", | |
13 | "In this way, you can finish one section before continuing to another.", | |
14 | "Like this:", | |
15 | "", | |
16 | " The two sides are colored 'red' and 'white.' The computer may play", | |
17 | "one side, or if there are two players, the computer can merely act as", | |
18 | "a gamekeeper, letting the players make the moves. Once you tell the", | |
19 | "computer what color(s) you want to play, the decision remains in ef-", | |
20 | "fect until you quit the program, even if you play more than one game,", | |
21 | "since the program keeps a running score.\n", | |
22 | " The program will prompt for a move in one of two ways. If the", | |
23 | "player has the opportunity to double, then merely his color will be", | |
24 | "typed out. The player can now do one of several things. He can dou-", | |
25 | "ble by typing a 'd', he can roll by typing a space (' ') or newline,", | |
26 | "or if he is not sure, he can reprint the board by typing a 'r'.\n", | |
27 | " If the player cannot double, his roll will be thrust in front of", | |
28 | "him, followed by the request 'Move:', asking for a move but not giving", | |
29 | "him the chance to double. He can still ask for the board by typing", | |
30 | "'r'. In either of these two states, the player can quit by typing 'q'", | |
31 | "or save the game by typing 's'. In either case, the player will be", | |
32 | "asked to verify, in case there was some error. The program then ends", | |
33 | "immediately, after first saving the file if so requested.", | |
34 | "", | |
35 | " A player can move one of his men using two forms of input. The", | |
36 | "first form is <s>-<f>, where <s> is the starting position, and <f> is", | |
37 | "the finishing position of the player's man. For example, if white", | |
38 | "wanted to move a piece from position 13 to position 8, his move could", | |
39 | "be entered as 13-8. The second form is <s>/<r> where <s> is the", | |
40 | "starting position, an <r> is the roll actually made. Hence, white", | |
41 | "could have entered as 13/5 instead of 13-8.\n", | |
42 | " A player must move each roll of the dice separately. For example,", | |
43 | "if a player rolled 4 3, and wanted to move from 13 to 6, he could", | |
44 | "enter it as 13/4,9/3 or 13/3,10/4 or 13-10,10-6 or 13-9,9-6, but not", | |
45 | "13-6. The last two entries can be shortened to 13-10-6 and 13-9-6.", | |
46 | "If you want to move more than one piece from the same position, such", | |
47 | "as 13-10,13-9, you can abbreviate this using the <s>/<r> format as by", | |
48 | "entering more than one <r>, or 13/34. A player can use both forms for", | |
49 | "the same roll, e.g. 13/3,13-9, and separates individual moves by ei-", | |
50 | "ther a comma or a space. The letter 'b' represents the bar, and the", | |
51 | "letter 'h' represents a player's home. You could also enter the", | |
52 | "number that would be in the position of the bar, 25 or 0 as appropri-", | |
53 | "ate. Use a newline at the end of your moves for a turn.", | |
54 | "", | |
55 | " As you type in your move, if a character does not make sense under", | |
56 | "the above constrictions, a bell will sound instead of the character,", | |
57 | "and it will be ignored. You may kill lines and erase characters as", | |
58 | "you would normally, but don't be surprised if they look different than", | |
59 | "usual. Also, if you have entered one or more of your rolls, and you", | |
60 | "wish to see what the move looks like so far, type a 'r' to see what it", | |
61 | "looks like. This cannot be done in the middle of a move (e.g., after", | |
62 | "a '-' or '/'). After the printing board, the program will go back to", | |
63 | "inputting your move and you can backspace or kill just as if you had", | |
64 | "just typed in your input.\n", | |
65 | " Now you should be ready to begin the game. Good luck!", | |
66 | "", | |
67 | 0}; | |
68 | \f | |
69 | ||
70 | text (t) | |
71 | char **t; | |
72 | ||
73 | { | |
74 | register int i; | |
75 | register char *s, *a; | |
76 | ||
77 | fixtty (noech); | |
78 | while (*t != 0) { | |
79 | s = a = *t; | |
80 | for (i = 0; *a != '\0'; i--) | |
81 | a++; | |
82 | if (i) { | |
83 | writel (s); | |
84 | writec ('\n'); | |
85 | } else { | |
86 | writel ("-->"); | |
87 | fixtty (raw); | |
88 | while ((i = readc()) != ' ' && i != '\n'); | |
89 | fixtty (noech); | |
90 | clear(); | |
91 | } | |
92 | t++; | |
93 | } | |
94 | fixtty (raw); | |
95 | } |