#include <iostream>
using namespace std;
int main()
{
int option = 0; //to be checked against for inital menu
string dir = ""; //for the movement loop
cout<<"Welcome to Townsville, USA!\n";
cout<<"Enter 1 for a new game, 2 to load a saved game, or 3 to quit.\n>";
//this is the logic for allowing the user to choose new/load/quit
do {
cin>>option;
//1 = new game, so starts loop to get user input for movement
if (option==1) {
cout<<"You are in the middle of the city\n";
cout<<"Train by bullying children, robbing banks, and doing other dasterdly deads\n";
cout<<"to prepare for your ultimate showdown with the Powerpuff Girls.\n";
cout<<"What do you want to do? \(Type help for a list of commands).\n>";
//movement loop
do{
cin>>dir;
if(dir=="north" || dir=="n"){
cout<<"You go north. All you can see are skyscrapers.\n>";
}
else if (dir=="south" || dir=="s") {
cout<<"You go north. All you can see are skyscrapers.\n>";
}
else if (dir=="east" || dir=="e") {
cout<<"You go east. All you can see are skyscrapers.\n>";
}
else if (dir=="west" || dir=="w") {
cout<<"You go west. All you can see are skyscrapers.\n>";
}
else if (dir == "look" || dir == "l") {
cout<<"You look around, but do not see anyone nearby to terrorize.\n>";
}
else if (dir == "help") {
cout<<"Available commands:\nMovement: Input north, south, east, west, or the first letter of the direction to move.\n";
cout<<"Look around with l or look.\nQuit with q or quit.\n>";
}
else if (dir=="quit" || dir=="q") {
cout<<"Quitting.\n";
return 0;
}
else {
cout<<"Command not recognized. Please try again.\n>";
}
}
while(dir!="q" || dir!="quit");
}
//2 = load game, not yet implemented
else if (option == 2) {
cout<<"Not implemented yet. Please choose another option.\n>";
}
//3 = quit
else if (option == 3) {
cout<<"Nobody likes a quitter. The Powerpuff Girls win again! :\(\n";
return 0;
}
//catches input that != 1,2,3, still fails on non-int inputs
else {
cout<<"Command not recognized. Please input 1, 2 or 3.\n>";
}
}
while (option != 3);
//it'll never actually get out of the initial do/while loop because all the quit options contain return 0;
return 0;
}