#include <iostream>
#include <string.h>
#include<conio.h>
#include<stdlib.h>
#include<windows.h>
usingnamespace std;
string name;
string comname;
char gender;
int age;
char x;
int powers;
int shops;
char a;
int strength = 20;
int speed = 10;
int aim = 30;
int dexterity = 35;
int money = 100;
int main()
{
system("COLOR B");
cout<<" \n";
cout<<" WELCOME TO LOST THE ZOMBIE ADVENTURE GAME! \n "<<endl;
cout<<" #################"<<endl;
cout<<" # 1.How To Play #\n"" # 2.Rules #\n"" # 3.Start #\n"" # 4.Exit #"<<endl;
cout<<" #################"<<endl;
do{
cin>>x;
}
while (x =='4');
if(x == '1'){
cout<<"So to play this game all you got to do is type and the game will tell you how to play!"<<endl;
do{
cin>>x;
} while (x =='4');
}
if(x == '2'){
cout<<"Rules :1.make sure you press the right button that th game tells you or else you might lose!\n 2.to win Follow all game instructions!\n 3.Have fun!"<<endl;
do{
cin>>x;
} while (x =='4');
}
if(x == '3'){
cout<<"Hello There Whats Your Name:"<<endl;
cin>>name;
}
if(age >= 45){
cout<<"Sorry but this game mighnt be for your age its too scary!"<<endl;
}
cout<<"How Old Are You:"<<endl;
cin>>age;
cout<<"Your name is "<< name <<"<"<< gender <<">"<<",You are "<<age<< "Years old." <<endl;
cout<<"You Went into to your bedroom ready to sleep then you hear this man screaming do you 1.sleep(s) 2.check whats going on(c)"<<endl;
cin>>a;
if(a== 's'){
cout<<"you decided to sleep a Zombie jumped on you and ate you!"<<endl;
cout << "********************************************************************************";
}
if(a == 'c'){
cout<<"You have Decided to check out the Window you see a Zombie coming towards your house your scared what do you do? 1.get a knife(k) 2.jump out of the window(j)"<<endl;
cin>>a;
}
if(a == 'k'){
cout<<"You decided to get a Knife you went down tne kitchen and got a Knife was it 1.Big(1) or 2.Small(2)"<<endl;
cin>>a;
}
if (a == '1'){
cout<<"you got the Big Knife!"<<endl;
}
if (a == '2'){
cout<<"You Got The Small Knife!"<<endl;
}
cout<<"The zombie Started Knocking on the Door you got your knife ready and the zombie knocked down the door do you 1.Run Away(r) 2.Attack Zombie (a)"<<endl;
cin>>a;
if(a == 'r'){
cout<<"You have Decided to Run Away from The Zombie and you went through the back door"<<endl;
cout<<"You Jumped Over The Fence But There was another zombie There ! 1.Hit Head(h) 2.Stab Stomach(s)"<<endl;
}
if(a == 'a'){
cout<<"You Have Decided to Attack The Zombie 1.Hit Head(h) 2.Stab Stomach(s)"<<endl;
cin>>a;
}
if(a == 'h'){
cout<<"You hit the zombies head you killed it Well Done!"<<endl;
}
if(a == 's'){
cout<<"You Stabbed The Zombie in the Stomach it fell down on the ground you killed it i think head would be better choice next time!"<<endl;
}
cout<<"Then you Hear your neighbour screaming do you go 1.help him<h> or 2.not<n>"<<endl;
cin>>a;
if(a == 'h'){
cout<<"you decided to help your neighbour you jumped the fence and you see a zombie on your neighbbuor and your neighbour is struggling you swung at the zombie you missed!"<<endl;
cout<<"PRESS ANY KEY TO FIGHT!"<<endl;
cout<< string(10, '\n');
cin>>a;
cout<<"zombies health is 50 yours is a 100 "<<endl;
cout<<"Press any key to Attack "<<endl;
cin>>a ;
cout<<name<<" sent a swing at the zombie and got him in the leg"<<endl;
cout<<"Zombie jumped on you and and bit your hand"<<endl;
cout<<"Zombies Health:20,"<<name<<"'s health is 50"<<endl;
cout<<"your friend helped you he shot a gun at the zombie and killed it you got poison in your hand what do you do"<<endl;
cout<<"1.amputate(a) 2.suck the poison out then stitch your hand!(s)"<<endl;
}
cin>> a;
if(a == 'a'){
cout<<"You decided to amputate your hand that wasnt a good choice but any way your friend cut off your hand from now on your gonig to have to survive wih one hand!"<<endl;
}
if(a == 's'){
cout<<"Nice Choice your friend got a stringe and sucked out the poison and you got your hand stitched!"<<endl;
cout<<"Thank you for saving me Now we need to head to Town Or The Forest to hide these Zombies are just crazy!, 1.Town(t) 2.Forest(f)"<<endl;
cin>>a;
if(a == 't'){
cout<<"You've Decided to go to Town theres alot of Zombies around Watch Out!"<<endl;
system("cls");
cout<<" \n AREA:TOWN. \n "<<endl;
cout<<"There is shops around which of these do you want to go into"<<endl;
cout<<" 1-Armory MONEY: "<<money<<" \n 2-Shop \n 3-Pharmacy\n 4-garage\n 5-Continue"<<endl;
cout<<" MONEY: "<<money<<endl;
}
cin>>shops;
while(shops != 'b'){
switch(shops){
case 1:
cout<<" You are Now in the Armory which of these Items you want to Upgrade:"<<endl;
cout<<" 1.Knife ...."<<endl;
cin>>powers;
cout<<"How Do you want to Upgrade It ?"<<endl;
cout<<" 1. Its Strength 20p \n 2.The Speed 10p \n 3.The Aim 30p \n 4.Dexterity.20p"<<endl;
cin>>powers;
}
}
while(money > 0){
switch(powers){
case 1:
cout<<"You upgraded your knifes strength 20p has been taken off your money!"<<endl;
money = money -20;
cout<<" 10p Has been taken of your account!"<<endl;
cout<<" MONEY:"<<money<<endl;
break;
case 2:
money = money - 10;
cout<<" MONEY: "<<money<<endl;
cout<<"You have upgraded The Speed Of Your item"<<endl;
cout<<" 10p Has been taken of your account!"<<endl;
money = money - 30;
break;
case 3:
cout<<" MONEY: "<<money<<endl;
cout<<"You Have Increased the aim of your weapon."<<endl;
cout<<" 30p Has been taken of your account!"<<endl;
break;
case 4:
money = money- 35;
cout<<"You Have increased The dexterity of your Weapon!"<<endl;
cout<<" 35p Has been taken of your account!"<<endl;
break;
cout<<" MONEY: "<<money<<endl;
}
if(money <= 0){
cout<<"Sorry you dont Have Enough Money!"<<endl;
}
if(money < strength){
cout<<"Sorry You Dont Have Enough Money!"<<endl;
}
if(money < speed){
cout<<"Sorry You Dont Have Enough Money!"<<endl;
if(money < aim){
cout<<"Sorry You Dont Have Enough Money!"<<endl;
}
if(money < dexterity){
cout<<"Sorry You Dont Have Enough Money!"<<endl;
}
if(a == 'f'){
cout<<"You've Decided to go to Forest theres alot of Zombies around Watch Out!"<<endl;
cout<< string(5, '\n');
cout<<" \n AREA:FOREST. \n "<<endl;
}
if(a == 'n'){
cout<<"you decided to leave your neighbour die you jumped out over the fence your neighbour was lying dead and you saw the zombie you attacked him but you missed"<<endl;
cout<<"PRESS ENTER TO FIGHT!"<<endl;
cout<< string(10, '\n');
cin>>a;
cout<<"zombies health is 50 yours is a 100 "<<endl;
cout<<"Press enter to attack "<<endl;
cin>>a;
cout<<name<<" sent a swing at the zombie and got him in the leg"<<endl;
cout<<"Zombie jumped on you and and bit your hand"<<endl;
cout<<"Zombies Health:20,"<<name<<"'s health is 50"<<endl;
cout<<"no could help you you kicked the zombie in the stomach but it was no use the zombie killed you and you TURNED"<<endl;
system("pause");
Sleep(5200);
system("cls");
cin>>a;
}
if(a =='j'){
cout<<"You decided to jump out of the window as a Result you Died!"<<endl;
cout<<" GAME OVER! "<<endl;
}
do{
cin>>x;
} while (x =='4');
if(x == '4'){
system("PAUSE");
a = false;
do{
cin>>x;
} while (x =='4');
}
}
}
}
}