ok i have just started making a text-adventure and i already ran into a problem. I it so simple it is sad but i can figuer it out.
here is the code:what happens is when the user selects 1 it says thanks for deciding to play, but when the user selects 2 it displays thanks for deciding to play as well as exiting. Can anybody suggest a solusion?Code:#include <iostream> #include <stdlib.h> int main(int argc, char *argv[]) { cout<<"\t\t\t\tTHE"; cout<<"\t\t\t\t\t\t\t\t"; cout<<"\t\t TEMPLE"; cout<<"\t\t\t\t\t\t\t\t"; cout<<"\t OF"; cout<<"\t\t\t\t\t\t\t\t"; cout<<"\t\t TYR"; cout<<"\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t1 : Play"; cout<<"\t\t\t\t\t\t\t\t\t2 : Exit"; int playorexit; cin>> playorexit; if(playorexit==1); { cout<<" Thanks for deciding to play!"; } if(playorexit==2); { system("PAUSE"); return 0; } system("PAUSE"); return 0; }