-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmenu.cpp
More file actions
51 lines (36 loc) · 1.02 KB
/
menu.cpp
File metadata and controls
51 lines (36 loc) · 1.02 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
/********************************************************************************************************
** Program Name: Final Project - A Text-based Game- menu.cpp
** Author: Andrew Friedrich
** Date: 06/01/2019
** Description: This file is the Final Project - A Text-based Game - menu.cpp - header
** file. This initates the menu and then runs the game.
**
*********************************************************************************************************/
#include "menu.hpp"
// default constructor
Menu::Menu()
{
}
// menu options
void Menu::go_Menu()
{
int user_Start_Pick = 0;
std::cout << "Menu choice- do you wish to play the game or exit? " << std::endl;
std::cout << "1. Play" << std::endl;
std::cout << "2. Exit" << std::endl;
user_Start_Pick = inputValCheck2a();
// If user wants to quit, then quit.
if (user_Start_Pick == 2)
{
std::exit(0);
}
else
{
Game go;
go.menu_GOGO();
}
}
// default deconstructor
Menu::~Menu()
{
}