Skip to content
Permalink
master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
///menu.cpp
#include "menu.h"
Main_menu::Main_menu()
{
player_input = 0;
}
bool Main_menu::choice()
{
if (player_input == 0){
///this if statement is purely for testing purpouses, if the test specifies player_input value, the code will ignore the if statement
///it is required because this function has input
cout<<""<<endl<<">>>>BARE CHESTS NINJA SOLO<<<<"<<endl<<endl;
cout<<"1: NEW GAME"<<endl;
cout<<"2: LOAD GAME"<<endl;
cout<<"3: QUIT"<<endl;
cout<<">";
cin >> player_input;
}
switch(player_input)
{
case 1:
return true;
case 2:
cout<<endl<<"This feature is not implemented, starting a new game\n";
return true;
case 3:
return false;
}
return false;
}
void Main_menu::setter(int value)
{
player_input = value;
}