MSTMND (Mastermind Game) by Larry Knock [72106,1051] GAME = 2.6K, DOC = 3.5K MSTMND is the M100 version of the popular colorcode breaker game. In the basic game, the computer picks a code consisting of 4 colors out of a possible 6. The 6 valid colors are BLUE, GREEN, ORANGE, RED, WHITE, and YELLOW. Your task is to break the code by making successive guesses as to what you think the code is. Guesses are made by entering the first letters of the colors you think are in the code. The computer provides feedback on each guess which guides you in making succeeding guesses. This feedback takes the following form: An 'X' means that your guess contained a color that was both the correct color, and was in the correct position in the code. An 'O' means you had a correct color, but not in the proper position. For example, if the code was 'rwbg' and your first guess was 'rbog', the result would be 'XXO'. This means that two of the colors you guessed (red & green) were proper colors in the proper positions (1st & 4th). A third color (blue) was a correct color, but was not in the proper position, since blue is in the 3rd position in the code, and your guess had blue in the 2nd position. By analyzing the results of each guess, you attempt to break the code in as few guesses as possible. NOTES on the M100 version: When the program is run, the M100 will ask 3 questions: 1. Advanced Game or Basic (A/B)? The basic game uses a code of 4 colors out of a possible 6. In the Basic game, you have 10 tries to break the code. The advanced game uses a code of 5 colors out of a possible 8 (with the colors PURPLE and SILVER added), and you have 12 guessess to break the code. 2. Duplicates Allowed (Y/N)? Ordinarily, the M100 will pick a code of 4 (or 5) DIFFERENT colors. Allowing duplicates will mean that codes such as 'rwow' or 'bgpss' or 'ggggg' are possible. 3. Blanks Allowed (Y/N)? This will allow the M100 (and your guesses) to contain empty positions. This has the same effect as using an extra color. To avoid having to use the SHIFT key, all answers to the questions, and all guesses, are made in lower case. Upper case is not accepted at any time. The M100 uses INKEY$ to input the player's guesses. As a result, if you type a letter you don't really want in your guess, you can use the BKSP key to erase it. The M100 will check to make sure your guess consists of valid colors. If not, an error message is printed, and the invalid guess is not accepted. This avoids wasted guesses due to typing errors. At the end of the game, if you don't break the code, it will be shown to you. Win or lose, the M100 will ask: Quit, Play Again, or Reset (Q/P/R)? Q - Quit playing, go to MENU P - Play another game, using the same game parameters. R - Reset the game parameters. The M100 will redisplay the 3 original questions, so you can switch between the basic and advanced games, etc. GOOD LUCK AND HAVE FUN!