Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //two programs, meant to provide outputs for simon game
- //board size is 35 width, 21 height, all underscores
- void ColorBoard(color) { //input for display will be an array, translating into a number 0-3
- if (color == 'G') {
- cout << "___________________________________" << endl;
- cout << "_ _ _" << endl;
- cout << "_ GGGG _ _" << endl;
- cout << "_ G G _ _" << endl;
- cout << "_ G _ _" << endl;
- cout << "_ G GGGG _ _" << endl;
- cout << "_ G GG _ _" << endl;
- cout << "_ G G _ _" << endl;
- cout << "_ GGGG _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "___________________________________" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "___________________________________" << endl;
- }
- else if (color == 'R') {
- cout << "___________________________________" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ RRRR _" << endl;
- cout << "_ _ R R _" << endl;
- cout << "_ _ R R _" << endl;
- cout << "_ _ RRRR _" << endl;
- cout << "_ _ RR _" << endl;
- cout << "_ _ R R _" << endl;
- cout << "_ _ R R _" << endl;
- cout << "_ _ _" << endl;
- cout << "___________________________________" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "___________________________________" << endl;
- }
- else if (color == 'Y') {
- cout << "___________________________________" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "___________________________________" << endl;
- cout << "_ _ _" << endl;
- cout << "_ Y Y _ _" << endl;
- cout << "_ Y Y _ _" << endl;
- cout << "_ Y Y _ _" << endl;
- cout << "_ YYY _ _" << endl;
- cout << "_ Y _ _" << endl;
- cout << "_ Y _ _" << endl;
- cout << "_ Y _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "___________________________________" << endl;
- }
- else if (color == 'B') {
- cout << "___________________________________" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "___________________________________" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ BBBB _" << endl;
- cout << "_ _ B B _" << endl;
- cout << "_ _ B B _" << endl;
- cout << "_ _ BBBB _" << endl;
- cout << "_ _ B B _" << endl;
- cout << "_ _ B B _" << endl;
- cout << "_ _ BBBB _" << endl;
- cout << "_ _ _" << endl;
- cout << "___________________________________" << endl;
- }
- }
- //next part is used between each display and at the end, just a blank board cout statement
- void BlankBoard () {
- cout << "___________________________________" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "___________________________________" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "_ _ _" << endl;
- cout << "___________________________________" << endl;
- }
- //colors: 0=G 1=R 2=Y 3=B
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement