954,536 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Game Error

I started this game a few months ago and I decided to finish it up, but a problem im having is with my arena. basically the "Arena" is the final thing to the game.
If you beat the arena you win the game.

whats wrong with it, is that when i get to the arena, and you start to fight the first person, it doesn't let you do anything else.

I know the code is pretty brutal but most of it is when I just started up c++ programming.

heres the full code so you can run it:

# include <iostream>
# include <cmath>
# include <ctime>
# include <conio.h>



using namespace std;

    int WeakHPotion;
    int LesserHPotion;
    int HealthPotion;
    int GreaterHPotion;
    int currentlvl;
    int exptolvl;
    int currentexp;
    int healing;
    int maxhealth;
    int arenamonsterhealth1;
    int arenamonsterhealth2;
    int arenamonsterhealth3;
    int arenamonsterhealth4;
    int arenaboss;
    int points = 3;
    int loot = 0;
    int money = 100;
    int dmg;
    int mdmg;
    int yourclass;
    string name;     
    int choice;
    int goblin = 25; 
    int dwarf = 50;
    int troll = 75;
    int giant = 100;
    int glvl = 1; 
    int dlvl = 2;
    int tlvl = 3;
    int Glvl = 4;
    int typeofclass;
    int health;
    int mana;
    int str;
    int def;
    int texp;
    int expe;
    int lvl = 1; 


void arenafight();
void exit ();
void attpoints();
void mainmenu();
void shop ();
void invin ();
void arena ();
void heal();
void gmelee();
void gspell();
void gmagic();
void gclasshealing();
void gsuperstrike();
void glightningbolt();
void glightningstrike();
void gfrostbolt();
void gfirebolt();
void gfireball();
void dmelee();
void dspell();
void dmagic();
void dclasshealing();
void dsuperstrike();
void dlightningbolt();
void dlightningstrike();
void dfrostbolt();
void dfirebolt();
void dfireball();
void tmelee();
void tspell();
void tmagic();
void tclasshealing();
void tsuperstrike();
void tlightningbolt();
void tlightningstrike();
void tfrostbolt();
void tfirebolt();
void tfireball();
void Gmelee();
void Gspell();
void Gmagic();
void Gclasshealing();
void Gsuperstrike();
void Glightningbolt();
void Glightningstrike();
void Gfrostbolt();
void Gfirebolt();
void Gfireball();


void bossmelee();
void bossspell();
void bossmagic();
void bossclasshealing();
void bosssuperstrike();
void bosslightningbolt();
void bosslightningstrike();
void bossfrostbolt();
void bossfirebolt();
void bossfireball();

void A1melee();
void A1spell();
void A1magic();
void A1classhealing();
void A1superstrike();
void A1lightningbolt();
void A1lightningstrike();
void A1frostbolt();
void A1firebolt();
void A1fireball();

void A2melee();
void A2spell();
void A2magic();
void A2classhealing();
void A2superstrike();
void A2lightningbolt();
void A2lightningstrike();
void A2frostbolt();
void A2firebolt();
void A2fireball();

void A3melee();
void A3spell();
void A3magic();
void A3classhealing();
void A3superstrike();
void A3lightningbolt();
void A3lightningstrike();
void A3frostbolt();
void A3firebolt();
void A3fireball();

void A4melee();
void A4spell();
void A4magic();
void A4classhealing();
void A4superstrike();
void A4lightningbolt();
void A4lightningstrike();
void A4frostbolt();
void A4firebolt();
void A4fireball();


 void fightg (){
      
             srand(static_cast<unsigned>(time(0)));
             bool done = false;
             goblin = 25;

             is <= 0
              system ("cls");
                  
                    
                    
                         do {
                             
                         dmg = 0;
                         mdmg = 0;
                         
                         if (health <= 0){
                         cout << "You have died." << endl << endl; 
                         cout << "Press Enter to return to the Main Menu.\n\n";
                         health = maxhealth;
                         cin.ignore();
                         cin.get();
                         mainmenu();
                    }
                               
                         system ("cls");
                         cout << "Your health is: " << health << endl << endl;
                         cout << "The Goblin's heath is: " << goblin << endl << endl << endl;
                         cout << "Do you want to: " << endl << endl;
                         cout << "1. Attack." << endl << endl;
                         cout << "2. Heal." << endl << endl;
                         cout << "3. Go to Main menu." << endl << endl;
                         cin >> choice;
                           if (choice == 1){
                              do {
                              
                              system ("cls");
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";

                              
                              cin >> choice;
                              if (choice == 1){
                                          done = true;
                                          gmelee();
                                          }
                                     else if (yourclass == 2 || 3 & choice == 2){
                                          done = true;
                                          gspell();
                                          }
                                     else{
                                          system("cls");
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                          }
                                     
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                               system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }               
                               
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
                              
                       
                                  
                                }
                           else if (choice == 3){mainmenu ();}
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                            } while (goblin > 0);
                                 
                          
                          system("cls");
                          
               if (goblin <= 0){ // after you killed a monster you got random exp depending on the monsters lvl
                          expe = 0; // ok .... umm hol on a sec I'm going to come off team viewer for like 5 min 
                          expe = rand() % 10 + 1; // i have to do something sry. kk
                          expe = expe * glvl;
                          currentexp = currentexp + expe;
                          loot = rand() % 100 + 1;
                          loot = loot * glvl;
                          cout << "You have killed a Goblin!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
                              }
                          
                          
                          health = maxhealth;
                          mainmenu();
                          
                          }
                          


void fightd () {
     
            dwarf = 50;
     
             bool done = false;

              system ("cls");
                  
                    
                    
                         do {
                             
                         dmg = 0;
                         mdmg = 0;
                         
                         if (health <= 0){
                         cout << "You have died." << endl << endl; 
                         cout << "Press Enter to return to the Main Menu.\n\n";
                         health = maxhealth;
                         cin.ignore();
                         cin.get();
                         mainmenu();
                    }
                               
                         system ("cls");
                         cout << "Your health is: " << health << endl << endl;
                         cout << "The Dwarf's heath is: " << dwarf << endl << endl << endl;
                         cout << "Do you want to: " << endl << endl;
                         cout << "1. Attack." << endl << endl;
                         cout << "2. Heal." << endl << endl;
                         cout << "3. Go to Main menu." << endl << endl;
                         cin >> choice;
                           if (choice == 1){
                              do {
                              
                              system ("cls");
                              
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";
                              cin >> choice;
                              switch (choice){
                                     case 1:
                                          done = true;
                                          dmelee();
                                     break;
                                     case 2:
                                          done = true;
                                          dspell();
                                     break;
                                     default:
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                     }
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                                   system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }               
                               
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                              
                       
                                  
                                }
                           else if (choice == 3){mainmenu ();}
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                            } while (dwarf > 0);
                                 
                          
                          system("cls");
                          
               if (dwarf <= 0){
                          expe = 0;
                          expe = rand() % 10 + 1;
                          expe = expe * dlvl;
                          currentexp = currentexp + expe;
                          loot = rand() % 100 + 1;
                          loot = loot * dlvl;
                          cout << "You have killed a Dwarf!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
                              }
                          
                          
                          health = maxhealth;
                          mainmenu();
                          
                          }
               
               
void fightt () {
     
            troll = 75;
            bool done = false;

              is <= 0
              system ("cls");
                  
                    
                    
                         do {
                             
                         dmg = 0;
                         mdmg = 0;
                         
                         if (health <= 0){
                         cout << "You have died." << endl << endl; 
                         cout << "Press Enter to return to the Main Menu.\n\n";
                         health = maxhealth;
                         cin.ignore();
                         cin.get();
                         mainmenu();
                    }
                               
                         system ("cls");
                         cout << "Your health is: " << health << endl << endl;
                         cout << "The Troll's heath is: " << troll << endl << endl << endl;
                         cout << "Do you want to: " << endl << endl;
                         cout << "1. Attack." << endl << endl;
                         cout << "2. Heal." << endl << endl;
                         cout << "3. Go to Main menu." << endl << endl;
                         cin >> choice;
                           if (choice == 1){
                              do {
                              
                              system ("cls");
                              
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";
                              cin >> choice;
                              switch (choice){
                                     case 1:
                                          done = true;
                                          tmelee();
                                     break;
                                     case 2:
                                          done = true;
                                          tspell();
                                     break;
                                     default:
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                     }
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                                    system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }               
                               
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
                              
                       
                                   // press any key code to go back to the main fighting menu.
                                }
                           else if (choice == 3){mainmenu ();}
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                            } while (troll> 0);
                                 
                          
                          system("cls");
                          
               if (troll <= 0){
                          expe = 0;
                          expe = rand() % 10 + 1;
                          expe = expe * tlvl;
                          currentexp = currentexp + expe;
                          loot = rand() % 100 + 1;
                          loot = loot * tlvl;
                          cout << "You have killed a Troll!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
                              }
                          
                          
                          health = maxhealth;
                          mainmenu();
                          
                          }
               
               

void fightG () {
     
            giant = 100;
            
            bool done = false;

              // do loop here, until the monsters health is <= 0
              system ("cls");
                  
                    
                    
                         do {
                             
                         dmg = 0;
                         mdmg = 0;
                         
                         if (health <= 0){
                         cout << "You have died." << endl << endl; // if you died from the fight then it will return to the main menu
                         cout << "Press Enter to return to the Main Menu.\n\n";
                         health = maxhealth;
                         cin.ignore();
                         cin.get();
                         mainmenu();
                    }
                               
                         system ("cls");
                         cout << "Your health is: " << health << endl << endl;
                         cout << "The Giant's heath is: " << giant << endl << endl << endl;
                         cout << "Do you want to: " << endl << endl;
                         cout << "1. Attack." << endl << endl;
                         cout << "2. Heal." << endl << endl;
                         cout << "3. Go to Main menu." << endl << endl;
                         cin >> choice;
                           if (choice == 1){
                              do {
                              
                              system ("cls");
                              
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";
                              cin >> choice;
                              switch (choice){
                                     case 1:
                                          done = true;
                                          Gmelee();
                                     break;
                                     case 2:
                                          done = true;
                                          Gspell();
                                     break;
                                     default:
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                     }
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                                    system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }               
                               
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
                              
                       
                                   // press any key code to go back to the main fighting menu.
                                }
                           else if (choice == 3){mainmenu ();}
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                            } while (giant > 0);
                                 
                          
                          system("cls");
                          
               if (giant <= 0){
                          expe = 0;
                          expe = rand() % 10 + 1;
                          expe = expe * Glvl;
                          currentexp = currentexp + expe;
                          loot = rand() % 100 + 1;
                          loot = loot * Glvl;
                          cout << "You have killed a Giant!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
                              }
                          
                          
                          health = maxhealth;
                          mainmenu();
                          
                          }


void mainmenu (){
     
    bool done = false;
    int choice;
    int goblin = 25; // monsters health.
    int dwarf = 50;
    int troll = 75;
    int giant = 100;
    int glvl = 1; // monsters level
    int dlvl = 2;
    int tlvl = 3;
    int Glvl = 4;
    
    do {

    system ("cls");
    cout << "Main menu." << endl << endl; // Main menu
    cout << "Your health is: " << health << "\n\n";
    cout << "You have: " << money << " Gold.\n\n";
    cout << "You have: " << points << " Attribute points.\n\n";
    cout << "You have: " << currentexp << " Experience.\n\n";
    cout << "You need: " << (lvl * 50) - currentexp << " Experience to level up\n\n";
    cout << "What would you like to do " << name << "?" << endl << endl;
    cout << "1. Fight." << endl << endl;
    cout << "2. Go to the Shop." << endl << endl;
    cout << "3. Go to the Arena." << endl << endl;
    cout << "4. Check Your Invintory.\n\n";
    if (points > 0){
    cout << "5. Spend Attribute Points.\n\n";
}
    if (health != maxhealth){
    cout << "6. Heal.\n\n";
}
    cout << "7. Exit.\n\n";
    cin >> choice;
    if (choice == 1){
               do {
               system ("cls");
               cout << "You have chosen to fight." << endl << endl; // who they choose to fight
               cout << "Who would you like to fight?" << endl << endl;
               cout << "1. Goblin." << endl << endl;
               cout << "2. Dwarf." << endl << endl;
               cout << "3. Troll." << endl << endl;
               cout << "4. Giant." << endl << endl;
               cin >> choice;
               
                   if (choice == 1){
                         fightg();
                                 }
                                 
                   else if (choice == 2){
                         fightd();
                                 }
                                 
                   else if (choice == 3){
                         fightt();
                                 }
                                 
                   else if (choice == 4){
                         fightG();
                         }
                   
                   else {
                        cout << "That is not a choice. please try again." << endl << endl;
                        cout <<  "\nPress Enter to retry.\n\n";
                        cin.ignore();
                        cin.get();
                        
                        }
                 }  while (choice != 1 || 2 || 3 || 4);
          }
    else if (choice == 2) {
         shop();
         }
    else if (choice == 3) {
         arena();
         }
    else if (choice == 4){
         invin();
         }
    else if (points > 0 & choice == 5){
      attpoints();
         }
    else if (health < maxhealth & choice == 6){
         heal();
         }
    else if (choice == 7){
         exit();
         done = true;
         }
    else {
                        system("cls");
                        cout << "\nThat is not a choice. please try again." << endl << endl;
                        cout <<  "Press Enter to continue.\n \n";
                        cin.ignore();
                        cin.get();
                        }
                        

} while (done != true);
}




int main (){

     cout << "Hello, Welcome." <<  endl << endl; // title screen


     cout << "What do you want your name to be?" << endl << endl;
     getline(cin,name);
     system ("cls");
     cout << "Congratulations " << name << " What do you want your class to be?"  <<  endl << endl; // this will determine base stats
     cout << "1. Warrior" <<  endl << endl;
     cout <<  "2. Mage" <<  endl << endl;
     cout <<  "3. Healer" <<  endl << endl;
     cin >>  typeofclass;
     
        
  
         if (typeofclass == 1){
            maxhealth = 50;
            system ("cls");
            yourclass = 1;
            cout <<  "You have chosen to be a Warrior.\n" <<  endl << endl; // gives stats for this person
            health = 50;
            mana = 1;
            str = 3;
            def = 3;
            }
         else if (typeofclass == 2){
            maxhealth = 25;
            system ("cls");
            yourclass = 2;
            cout <<  "You have chosen to be a Mage.\n" <<  endl << endl;
            cout << "A note for mages: \n\n";
            cout << "The higher your Mana, the more Spells you get to use.\n\n";
            health = 25;
            mana = 5;
            str = 1;
            def = 1;
            }
         else if (typeofclass == 3){
            maxhealth = 25;
            system ("cls");
            yourclass = 3;      
            cout <<  "You have chosen to be a Healer.\n";
            health = 25;
            mana = 4;
            str = 1;
            def = 1;
            }
         else {
            cout <<  "Sorry, thats not a right number, please try again." <<  endl;
}

      
          
      cout << "Your Stats are:" << endl << endl;
      cout << "Health " << health << endl << endl << "Mana " << mana << endl << endl;
      cout << "Strength " << str << endl << endl << "Defense " << def << endl << endl;
      cout <<  "Press Enter to continue.\n \n";
      cin.ignore();
      cin.get();
      
      mainmenu();
      
      
cin.ignore();
cin.get();





}



void shop(){
     system ("cls");
     if (money <= 0){
                     cout << "You Have No Money!\n\n";
                     cout << "Press Enter To Return To the Main Menu.\n";
                     cin.ignore();
                     cin.get();
                     mainmenu();
                     }
     bool done;
     done = false;
     cout << "Welcome to the Shop.\n\n\n";
     cout << "You Have: " << money << " Gold.\n\n\n";
     cout << "1. Weak Health Potion.              $50\n\n";
     cout << "2. Lesser Health Potion.            $100\n\n";
     cout << "3. Health Potion.                   $200\n\n";
     cout << "4. Greater Health Potion.           $300\n\n";
     cout << "5. Add 10 to Max Health.            $250\n\n";
     cout << "6. Add 1 to Mana.                   $250\n\n";
     cout << "7. Add 1 to Strength.               $250\n\n";
     cout << "8. Add 1 to Defense.                $250\n\n";
     cout << "9. Go to the Main Menu.\n\n";
     cin >> choice;
     while (done != true){
     if (choice == 1 && money >= 50){
                system("cls");
                money = money - 50;
                WeakHPotion = WeakHPotion + 1;
                cout << "You Just Bought A Weak Healing Potion.\n\n";
                cout << "Now You Have: " << WeakHPotion << " Weak Healing Potions.\n\n";
                cout << "Press Enter To Return To the Shop.\n";
                cin.ignore();
                cin.get();
                shop();
                }
     else if (choice == 2 && money >= 100){
                system("cls");
                money = money - 100;
                LesserHPotion = LesserHPotion + 1;
                cout << "You Just Bought A Lesser Healing Potion.\n\n";
                cout << "Now You Have: " << LesserHPotion << " Lesser Healing Potions.\n\n";
                cout << "Press Enter To Return To the Shop.\n";
                cin.ignore();
                cin.get();
                shop();
                }
     else if (choice == 3 && money >= 200){
                system("cls");
                money = money - 200;
                HealthPotion = HealthPotion + 1;
                cout << "You Just Bought A Health Potion.\n\n";
                cout << "Now You Have: " << HealthPotion << " Health Potions.\n\n";
                cout << "Press Enter To Return To the Shop.\n";
                cin.ignore();
                cin.get();
                shop();
                }
     else if (choice == 4 && money >= 300){
                system("cls");
                money = money - 300;
                GreaterHPotion = GreaterHPotion + 1;
                cout << "You Just Bought A Greater Healing Potion.\n\n";
                cout << "Now You Have: " << GreaterHPotion << " Greater Healing Potions.\n\n";
                cout << "Press Enter To Return To the Shop.\n";
                cin.ignore();
                cin.get();
                shop();
                }
     else if (choice == 5 && money >= 250){
                system("cls");
                money = money - 250;
                maxhealth = maxhealth + 10;
                cout << "You Just Added 10 To Your Max Health.\n\n";
                cout << "Your Max Health is now: " << maxhealth << ".\n\n";
                cout << "Press Enter To Return To the Shop.\n";
                cin.ignore();
                cin.get();
                shop();
                }
     else if (choice == 6 && money >= 250){
                system("cls");
                money = money - 250;
                mana = mana + 1;
                cout << "You Just Bought A Mana Point.\n\n";
                cout << "Now You Have: " << mana << " Mana.\n\n";
                cout << "Press Enter To Return To the Shop.\n";
                cin.ignore();
                cin.get();
                shop();
                }
     else if (choice == 7 && money >= 250){
                system("cls");
                money = money - 250;
                str = str + 1;
                cout << "You Just Bought A Strength Point.\n\n";
                cout << "Now You Have: " << str << " Strength.\n\n";
                cout << "Press Enter To Return To the Shop.\n";
                cin.ignore();
                cin.get();
                shop();
                }
     else if (choice == 8 && money >= 250){
                system("cls");
                money = money - 250;
                def = def + 1;
                cout << "You Just Bought A Defense Point.\n\n";
                cout << "Now You Have: " << def << " Defense.\n\n";
                cout << "Press Enter To Return To the Shop.\n";
                cin.ignore();
                cin.get();
                shop();
                }
     else if (choice == 9){
                done = true;
                system("cls");
                cout << "To Return To the Main Menu Press Enter.\n";
                cin.ignore();
                cin.get();
                mainmenu();
                }
                
                
     
     if (choice == 1 && money < 50){
                done = true;
                system("cls");
                cout << "You Dont Have Enough Money.\n\n";
                cout << "Press Enter To Continue.\n";
                cin.ignore();
                cin.get();
                }
                
     else if (choice == 2 && money < 100){
                done = true;
                system("cls");
                cout << "You Dont Have Enough Money.\n\n";
                cout << "Press Enter To Continue.\n";
                cin.ignore();
                cin.get();
                }
                
     else if (choice == 3 && money < 200){
                done = true;
                system("cls");
                cout << "You Dont Have Enough Money.\n\n";
                cout << "Press Enter To Continue.\n";
                cin.ignore();
                cin.get();
                }
                
     else if (choice == 4 && money < 300){
                done = true;      
                system("cls");
                cout << "You Dont Have Enough Money.\n\n";
                cout << "Press Enter To Continue.\n";
                cin.ignore();
                cin.get();
                }
                
     else if (choice == 5 && money < 250){
                done = true;
                system("cls");
                cout << "You Dont Have Enough Money.\n\n";
                cout << "Press Enter To Continue.\n";
                cin.ignore();
                cin.get();
                }
                
     else if (choice == 6 && money < 250){
                done = true;
                system("cls");
                cout << "You Dont Have Enough Money.\n\n";
                cout << "Press Enter To Continue.\n";
                cin.ignore();
                cin.get();
                }
                
     else if (choice == 7 && money < 250){
                done = true;
                system("cls");
                cout << "You Dont Have Enough Money.\n\n";
                cout << "Press Enter To Continue.\n";
                cin.ignore();
                cin.get();
                }
                
     else if (choice == 8 && money < 250){
                done = true;
                system("cls");
                cout << "You Dont Have Enough Money.\n\n";
                cout << "Press Enter To Continue.\n";
                cin.ignore();
                cin.get();
                }
     }
     cout << "Press Enter To Return To the Main Menu.\n";
     cin.ignore();
     cin.get();
     mainmenu();
     }
     
void invin() {
     system ("cls");
     cout << "Your Invintory: \n\n";
     cout << "Weak Health Potions: " << WeakHPotion << ".\n\n";
     cout << "Lesser Health Potions: " << LesserHPotion << ".\n\n";
     cout << "Health Potions: " << HealthPotion << ".\n\n";
     cout << "Greater Health Potions: " << GreaterHPotion << ".\n\n";
     cout << "Press Enter to Return To The Main Menu.\n";
     cin.ignore();
     cin.get();
     mainmenu();
     }
     
     
void arena() {
     system ("cls");
     cout << "This Is the Arena.\n\n";
     cout << "You Will Have To fight And Beat 5 Random Monsters To Beat the Game...\n\n";
     cout << "But Be Warned... The Final Boss May Be Very Hard To Beat...\n\n";
     cout << "1. Continue... I'm Not Scared.\n\n";
     cout << "2. Take Me Back to the Main Menu! I'm Not Ready!\n";
     cin >> choice;
     while (choice != 1 || 2){
     if (choice == 1){
                arenafight();
                }
     else if (choice == 2){
          mainmenu();
          }
          }
     
     }
     
     
void arenafight(){
     bool done;
     done = false;
     system("cls");
     cout << "Welcome " << name;
     cout << "\n\nThis Arena Will Test Your Skill.\n\n";
     cout << "Press Enter To Start the Battles.\n";
     cin.ignore();
     cin.get();
     system("cls");
     
     arenamonsterhealth1 = health * 2;
     cout << "Your Health is: " << health << "\n\n";
     cout << "Your Enemies Health is: " << arenamonsterhealth1 << "\n\n";
     cout << "Do You Want To: \n\n";
     cout << "1. Attack.\n\n";
     cout << "2. heal.\n\n";
     cout << "3. Return To the Main Menu.\n\n";
     
     
      cin >> choice;
                           if (choice == 1){
                              
                              do{
                              system ("cls");
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";
                              cin >> choice;
                              switch (choice){
                                     
                                     case 1:
                                          done = true;
                                          A1melee();
                                     break;
                                     case 2:
                                          done = true;
                                          A1spell();
                                     break;
                                     default:
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                     
                                     }
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                                    system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth){
                                             health = maxhealth;
                                          }               
                               
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
                              
                       
                                   // press any key code to go back to the main fighting menu.
                                }
                           else if (choice == 3){
                                mainmenu();
                                }
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                            } while (arenamonsterhealth1 > 0);
                                 
                          
                          system("cls");
                          
               if (arenamonsterhealth1 <= 0){
                          expe = 0;
                          expe = rand() % 250 + 1;
                          currentexp = currentexp + expe;
                          loot = rand() % 1000 + 1;
                          cout << "You have killed a Giant!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
                              }
                          
                          
                          health = maxhealth;
                          
                          
     if (arenamonsterhealth1 <= 0){
                             system ("cls");
                             cout << "You Have Defeated Your First Arena Monster.\n\n";
                             cout << "To Continue Fighting The Monsters Press Enter.\n\n";
                             cin.ignore();
                             cin.get();
                              
                              
                              
                              do {
                              arenamonsterhealth1 = health * 2;
                              cout << "Your Health is: " << health << "\n\n";
                              cout << "Your Enemies Health is: " << arenamonsterhealth1 << "\n\n";
                              cout << "Do You Want To: \n\n";
                              cout << "1. Attack.\n\n";
                              cout << "2. heal.\n\n";
                              cout << "3. Return To the Main Menu.\n\n";   
                                  
                              if (choice == 1){
                                         do {
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";
                              cin >> choice;
                              switch (choice){
                                     case 1:
                                          done = true;
                                          A2melee();
                                     break;
                                     case 2:
                                          done = true;
                                          A2spell();
                                     break;
                                     default:
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                     }
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                                    system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }               
                               
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
                              
                       
                                   // press any key code to go back to the main fighting menu.
                                }
                           else if (choice == 3){mainmenu ();}
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                            } while (arenamonsterhealth2 > 0);
                                 
                          
                          system("cls");
                          
               if (arenamonsterhealth2 <= 0){
                          expe = 0;
                          expe = rand() % 250 + 1;
                          currentexp = currentexp + expe;
                          loot = rand() % 1000 + 1;
                          cout << "You have killed a Giant!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
                              }
                              
                              
                if (arenamonsterhealth1 <= 0 && arenamonsterhealth2 <= 0){
                             system ("cls");
                             cout << "You Have Defeated Your Second Arena Monster.\n\n";
                             cout << "To Continue Fighting The Monsters Press Enter.\n\n";
                             cin.ignore();
                             cin.get();
                              
                              
                              
                              do {
                              arenamonsterhealth3 = health * 3;
                              cout << "Your Health is: " << health << "\n\n";
                              cout << "Your Enemies Health is: " << arenamonsterhealth3 << "\n\n";
                              cout << "Do You Want To: \n\n";
                              cout << "1. Attack.\n\n";
                              cout << "2. heal.\n\n";
                              cout << "3. Return To the Main Menu.\n\n";   
                                  
                              if (choice == 1){
                                         do {
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";
                              cin >> choice;
                              switch (choice){
                                     case 1:
                                          done = true;
                                          A3melee();
                                     break;
                                     case 2:
                                          done = true;
                                          A3spell();
                                     break;
                                     default:
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                     }
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                                    system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }               
                               
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
                              
                       
                                   // press any key code to go back to the main fighting menu.
                                }
                           else if (choice == 3){mainmenu ();}
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                            } while (arenamonsterhealth3 > 0);
                                 
                          
                          system("cls");
                          
               if (arenamonsterhealth3 <= 0){
                          expe = 0;
                          expe = rand() % 250 + 1;
                          currentexp = currentexp + expe;
                          loot = rand() % 1000 + 1;
                          cout << "You have killed a Giant!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
                          
                          
                          health = maxhealth;
                             }
                             
                             
     
     
     
     
     
     
     
      if (arenamonsterhealth1 <= 0 && arenamonsterhealth2 <= 0 && arenamonsterhealth3 <= 3){
                             system ("cls");
                             cout << "You Have Defeated Your First Arena Monster.\n\n";
                             cout << "To Continue Fighting The Monsters Press Enter.\n\n";
                             cin.ignore();
                             cin.get();
                              
                              
                              
                              do {
                              arenamonsterhealth4 = health * 3;
                              cout << "Your Health is: " << health << "\n\n";
                              cout << "Your Enemies Health is: " << arenamonsterhealth4 << "\n\n";
                              cout << "Do You Want To: \n\n";
                              cout << "1. Attack.\n\n";
                              cout << "2. heal.\n\n";
                              cout << "3. Return To the Main Menu.\n\n";   
                                  
                              if (choice == 1){
                                         do {
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";
                              cin >> choice;
                              switch (choice){
                                     case 1:
                                          done = true;
                                          A4melee();
                                     break;
                                     case 2:
                                          done = true;
                                          A4spell();
                                     break;
                                     default:
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                     }
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                                    system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }               
                               
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
                              
                       
                                   // press any key code to go back to the main fighting menu.
                                }
                           else if (choice == 3){mainmenu ();}
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                            } while (arenamonsterhealth4 > 0);
                                 
                          
                          system("cls");
                          
               if (arenamonsterhealth4 <= 0){
                          expe = 0;
                          expe = rand() % 250 + 1;
                          currentexp = currentexp + expe;
                          loot = rand() % 1000 + 1;
                          cout << "You have killed a Giant!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
                                      
                                      
                                      
                if (arenamonsterhealth1 <= 0 && arenamonsterhealth2 <= 0 && arenamonsterhealth3 <= 0 && arenamonsterhealth4 <= 0){
                             system ("cls");
                             cout << "You Have Defeated Your First Arena Monster.\n\n";
                             cout << "To Continue Fighting The Monsters Press Enter.\n\n";
                             cin.ignore();
                             cin.get();
                              
                              
                              
                              do {
                              arenaboss = health * 4;
                              cout << "Your Health is: " << health << "\n\n";
                              cout << "Your Enemies Health is: " << arenaboss << "\n\n";
                              cout << "Do You Want To: \n\n";
                              cout << "1. Attack.\n\n";
                              cout << "2. heal.\n\n";
                              cout << "3. Return To the Main Menu.\n\n";   
                                  
                              if (choice == 1){
                                         do {
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";
                              cin >> choice;
                              switch (choice){
                                     case 1:
                                          done = true;
                                          bossmelee();
                                     break;
                                     case 2:
                                          done = true;
                                          bossspell();
                                     break;
                                     default:
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                     }
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                                    system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth){
                                             health = maxhealth;
                                          }               
                                          }
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
                               
                               
                              
                       
                                   // press any key code to go back to the main fighting menu.
                                }
                           else if (choice == 3){
                                mainmenu();
                                }
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                                
                            } while (arenaboss > 0);
                            }  
                          
                          system("cls");
                          
               if (arenaboss <= 0){
                          expe = 0;
                          expe = rand() % 250 + 1;
                          currentexp = currentexp + expe;
                          loot = rand() % 1000 + 1;
                          cout << "You have killed a Giant!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                          }
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
     
     cout << "Coming Soon.\n\n";
     cout << "Press Enter To Return To The Main Menu.\n";
     cin.ignore();
     cin.get();
     mainmenu();
     
     
     
     }
     }
     }
     }
     }
     
     
     
     
     
void attpoints(){
     bool done = false;
     while (done != true){
           if (points <= 0){
                      system ("cls");
                      cout << "You have no more Points.\n";
                      cout << "Press Enter to return to the Main Menu.\n";
                      cin.ignore();
                      cin.get(); 
                      mainmenu();
                      
                      }
     system ("cls");
     cout << "You have: " << points << " Points left.\n\n";
     cout << "Your Stats are:" << endl << endl;
     cout << "Health " << health << endl << endl << "Mana " << mana << endl << endl;
     cout << "Strength " << str << endl << endl << "Defense " << def << endl << endl;
     cout << "Would you like to:" << endl;
     cout << "\n\n1. Add 10 to Your Health.";
     cout << "\n\n2. Add 1 to Strength.";
     cout << "\n\n3. Add 1 to Defense.";
     cout << "\n\n4. Add 1 to Mana.\n";
     cout << "\n5. Go to main menu.\n\n";
     cin >> choice;
     cout << "\n\n";
         
          switch (choice){
                 case 1:
                      system ("cls");
                      points = points - 1;
                      maxhealth = maxhealth + 10;
                      health = maxhealth;
                      cout << "You added 10 to your health, Your health is now: " << maxhealth << ".\n";
                      cout << "\nPress Enter to add more.\n";
                      cin.ignore();
                      cin.get(); 
                 break;
                 
                 case 2:
                      system ("cls");
                      points = points - 1;
                      str = str + 1;
                      cout << "You added 1 to your Strength, Your Strength is now: " << str << ".\n";
                      cout << "\nPress Enter to add more.\n";
                      cin.ignore();
                      cin.get(); 
                 break;
                 
                 case 3:
                      system ("cls");
                      points = points - 1;
                      def = def + 1;
                      cout << "You added 1 to your Defense, Your Defense is now: " << def << ".\n";
                      cout << "\nPress Enter to add more.\n";
                      cin.ignore();
                      cin.get(); 
                 break;
                 
                 case 4:
                      system ("cls");
                      points = points - 1;
                      mana = mana + 1;
                      cout << "You added 1 to your Mana, Your Mana is now: " << mana << ".\n";
                      cout << "\nPress Enter to add more.\n";
                      cin.ignore();
                      cin.get(); 
                 break;
                 case 5:
                      done = true;
                 break;
                
          
                }
                 }
     cout << "\nPress Enter to Go to the main menu \n";
     cin.ignore();
     cin.get();
     mainmenu();
     }
     
     
void heal(){
     system("cls");
     health = maxhealth;
     cout << "You have chosen to heal.\n\n";
     cout << "Your health is now: " << health << ".\n\n";
     cout << "\nPress Enter to Go to the main menu \n";
     cin.ignore();
     cin.get();
     mainmenu();
     
     }
     
void exit(){
     system("cls");
     cout << "Thank you for playing: " << name << ".\n\n";
     cout << "I Hope you had a fun time playing.\n\n";
     cout << "Please come play again soon.\n\n";
     cout << "To exit, Press enter.\n\n";
     cin.ignore();
     cin.get();
      exit(0);
      exit(EXIT_SUCCESS);
      exit(EXIT_FAILURE);
     }
     

void gmelee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / glvl;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               goblin = goblin - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void gspell(){
     system("cls");
     if (yourclass == 2){                    
                   gmagic();
                   }      
     else if (yourclass == 3){
                   gclasshealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void gmagic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                gfireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                gfirebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                gfrostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                glightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                glightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                gsuperstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void gclasshealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void gsuperstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / glvl;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               goblin = goblin - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void glightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 25 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / glvl;
                               cout <<  "You Cast a Lightning Bolt and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               goblin = goblin - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void glightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 20 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / glvl;
                               cout <<  "You Cast a Lightning Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               goblin = goblin - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void gfrostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 15 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / glvl;
                               cout <<  "You Cast a Frostbolt and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               goblin = goblin - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void gfirebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / glvl;
                               cout <<  "You Cast a Firebolt and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               goblin = goblin - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void gfireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 5 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / glvl;
                               cout <<  "You Cast a Fireball and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               goblin = goblin - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
     
     
     









void dmelee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * dlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / dlvl;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               dwarf = dwarf - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void dspell(){
     system("cls");
     if (yourclass == 2){                    
                   dmagic();
                   }      
     else if (yourclass == 3){
                   dclasshealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void dmagic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                dfireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                dfirebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                dfrostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                dlightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                dlightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                dsuperstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void dclasshealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void dsuperstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * dlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / dlvl;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               dwarf = dwarf - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void dlightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * dlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 25 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / dlvl;
                               cout <<  "You Cast a Lightning Bolt and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               dwarf = dwarf - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void dlightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * dlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 20 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / dlvl;
                               cout <<  "You Cast a Lightning Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               dwarf = dwarf - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void dfrostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * dlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 15 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / dlvl;
                               cout <<  "You Cast a Frostbolt and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               dwarf = dwarf - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void dfirebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * dlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / dlvl;
                               cout <<  "You Cast a Firebolt and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               dwarf = dwarf - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void dfireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * dlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 5 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / dlvl;
                               cout <<  "You Cast a Fireball and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               dwarf = dwarf - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
     
     
     
     
     
     
     
     
     
     

void tmelee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * tlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / tlvl;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               troll = troll - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void tspell(){
     system("cls");
     if (yourclass == 2){                    
     tmagic();
                   }      
     else if (yourclass == 3){
                   tclasshealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void tmagic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                tfireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                tfirebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                tfrostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                tlightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                tlightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                tsuperstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void tclasshealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void tsuperstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * tlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / tlvl;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               troll = troll - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void tlightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * tlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 25 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / tlvl;
                               cout <<  "You Cast a Lightning Bolt and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               troll = troll - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void tlightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * tlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 20 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / tlvl;
                               cout <<  "You Cast a Lightning Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               troll = troll - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void tfrostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * tlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 15 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / tlvl;
                               cout <<  "You Cast a Frostbolt and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               troll = troll - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void tfirebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * tlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / tlvl;
                               cout <<  "You Cast a Firebolt and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               troll = troll - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void tfireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * tlvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 5 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / tlvl;
                               cout <<  "You Cast a Fireball and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               troll = troll - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     

void Gmelee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * Glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / Glvl;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               giant = giant - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void Gspell(){
     system("cls");
     if (yourclass == 2){                    
                   Gmagic();
                   }      
     else if (yourclass == 3){
                   Gclasshealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void Gmagic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                Gfireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                Gfirebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                Gfrostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                Glightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                Glightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                Gsuperstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void Gclasshealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void Gsuperstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * Glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / Glvl;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               giant = giant - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void Glightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * Glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 25 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / Glvl;
                               cout <<  "You Cast a Lightning Bolt and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               giant = giant - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void Glightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * Glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 20 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / Glvl;
                               cout <<  "You Cast a Lightning Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               giant = giant - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void Gfrostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * Glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 15 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / Glvl;
                               cout <<  "You Cast a Frostbolt and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               giant = giant - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void Gfirebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * Glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / Glvl;
                               cout <<  "You Cast a Firebolt and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               giant = giant - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void Gfireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * Glvl;
                               mdmg = mdmg / def;
                               dmg = rand() % 5 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / Glvl;
                               cout <<  "You Cast a Fireball and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               giant = giant - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }








     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     

void bossmelee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() %10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / 2;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void bossspell(){
     system("cls");
     if (yourclass == 2){                    
                   bossmagic();
                   }      
     else if (yourclass == 3){
                   bossclasshealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void bossmagic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                bossfireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                bossfirebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                bossfrostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                bosslightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                bosslightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                bosssuperstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void bossclasshealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void bosssuperstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void bosslightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void bosslightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void bossfrostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void bossfirebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void bossfireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }











     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     

void A1melee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() %10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / 2;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void A1spell(){
     system("cls");
     if (yourclass == 2){                    
                   A1magic();
                   }      
     else if (yourclass == 3){
                   A1classhealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void A1magic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                A1fireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                A1firebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                A1frostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                A1lightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                A1lightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                A1superstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void A1classhealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void A1superstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A1lightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 25 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A1lightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 20 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A1frostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 15 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A1firebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A1fireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 5 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
     
     
     
     
     
     
     
     
     
     
     
     
     
     void A2melee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() %10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / 2;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth2 = arenamonsterhealth2 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void A2spell(){
     system("cls");
     if (yourclass == 2){                    
                   A1magic();
                   }      
     else if (yourclass == 3){
                   A1classhealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void A2magic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                A2fireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                A2firebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                A2frostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                A2lightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                A2lightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                A2superstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void A2classhealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void A2superstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth2 = arenamonsterhealth2 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A2lightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 25 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth2 = arenamonsterhealth2 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A2lightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 20 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A2frostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 15 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth2 = arenamonsterhealth2 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A2firebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth2 = arenamonsterhealth2 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A2fireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 5 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth2 = arenamonsterhealth2 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }













void A3melee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() %10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / 2;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void A3spell(){
     system("cls");
     if (yourclass == 2){                    
                   A3magic();
                   }      
     else if (yourclass == 3){
                   A3classhealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void A3magic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                A3fireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                A3firebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                A3frostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                A3lightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                A3lightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                A3superstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void A3classhealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void A3superstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A3lightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 25 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A3lightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 20 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A3frostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 15 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A3firebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A3fireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 5 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     void A4melee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() %10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / 2;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void A4spell(){
     system("cls");
     if (yourclass == 2){                    
                   A4magic();
                   }      
     else if (yourclass == 3){
                   A4classhealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void A4magic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                A4fireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                A4firebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                A4frostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                A4lightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                A4lightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                A4superstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void A4classhealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void A4superstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A4lightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 25 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A4lightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 20 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A4frostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 15 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A4firebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A4fireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 5 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }


heres the code to the arena:

\*Here is where it sends To the battle section.*\
     
void arenafight(){
     bool done;
     done = false;
     system("cls");
     cout << "Welcome " << name;
     cout << "\n\nThis Arena Will Test Your Skill.\n\n";
     cout << "Press Enter To Start the Battles.\n";
     cin.ignore();
     cin.get();
     system("cls");
     
     arenamonsterhealth1 = health * 2;
     cout << "Your Health is: " << health << "\n\n";
     cout << "Your Enemies Health is: " << arenamonsterhealth1 << "\n\n";
     cout << "Do You Want To: \n\n";
     cout << "1. Attack.\n\n";
     cout << "2. heal.\n\n";
     cout << "3. Return To the Main Menu.\n\n";
     
     
      cin >> choice;
                           if (choice == 1){
                              
                              do{
                              system ("cls");
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";
                              cin >> choice;
                              switch (choice){
                                     
                                     case 1:
                                          done = true;
                                          A1melee();
                                     break;
                                     case 2:
                                          done = true;
                                          A1spell();
                                     break;
                                     default:
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                     
                                     }
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                                    system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth){
                                             health = maxhealth;
                                          }               
                               
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
                              
                       
                                   // press any key code to go back to the main fighting menu.
                                }
                           else if (choice == 3){
                                mainmenu();
                                }
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                            } while (arenamonsterhealth1 > 0);
                                 
                          
                          system("cls");
                          
               if (arenamonsterhealth1 <= 0){
                          expe = 0;
                          expe = rand() % 250 + 1;
                          currentexp = currentexp + expe;
                          loot = rand() % 1000 + 1;
                          cout << "You have killed a Giant!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
                              }
                          
                          
                          health = maxhealth;
                          
                          
     if (arenamonsterhealth1 <= 0){
                             system ("cls");
                             cout << "You Have Defeated Your First Arena Monster.\n\n";
                             cout << "To Continue Fighting The Monsters Press Enter.\n\n";
                             cin.ignore();
                             cin.get();
                              
                              
                              
                              do {
                              arenamonsterhealth1 = health * 2;
                              cout << "Your Health is: " << health << "\n\n";
                              cout << "Your Enemies Health is: " << arenamonsterhealth1 << "\n\n";
                              cout << "Do You Want To: \n\n";
                              cout << "1. Attack.\n\n";
                              cout << "2. heal.\n\n";
                              cout << "3. Return To the Main Menu.\n\n";   
                                  
                              if (choice == 1){
                                         do {
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";
                              cin >> choice;
                              switch (choice){
                                     case 1:
                                          done = true;
                                          A2melee();
                                     break;
                                     case 2:
                                          done = true;
                                          A2spell();
                                     break;
                                     default:
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                     }
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                                    system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }               
                               
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
                              
                       
                                   // press any key code to go back to the main fighting menu.
                                }
                           else if (choice == 3){mainmenu ();}
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                            } while (arenamonsterhealth2 > 0);
                                 
                          
                          system("cls");
                          
               if (arenamonsterhealth2 <= 0){
                          expe = 0;
                          expe = rand() % 250 + 1;
                          currentexp = currentexp + expe;
                          loot = rand() % 1000 + 1;
                          cout << "You have killed a Giant!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
                              }
                              
                              
                if (arenamonsterhealth1 <= 0 && arenamonsterhealth2 <= 0){
                             system ("cls");
                             cout << "You Have Defeated Your Second Arena Monster.\n\n";
                             cout << "To Continue Fighting The Monsters Press Enter.\n\n";
                             cin.ignore();
                             cin.get();
                              
                              
                              
                              do {
                              arenamonsterhealth3 = health * 3;
                              cout << "Your Health is: " << health << "\n\n";
                              cout << "Your Enemies Health is: " << arenamonsterhealth3 << "\n\n";
                              cout << "Do You Want To: \n\n";
                              cout << "1. Attack.\n\n";
                              cout << "2. heal.\n\n";
                              cout << "3. Return To the Main Menu.\n\n";   
                                  
                              if (choice == 1){
                                         do {
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";
                              cin >> choice;
                              switch (choice){
                                     case 1:
                                          done = true;
                                          A3melee();
                                     break;
                                     case 2:
                                          done = true;
                                          A3spell();
                                     break;
                                     default:
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                     }
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                                    system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }               
                               
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
                              
                       
                                   // press any key code to go back to the main fighting menu.
                                }
                           else if (choice == 3){mainmenu ();}
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                            } while (arenamonsterhealth3 > 0);
                                 
                          
                          system("cls");
                          
               if (arenamonsterhealth3 <= 0){
                          expe = 0;
                          expe = rand() % 250 + 1;
                          currentexp = currentexp + expe;
                          loot = rand() % 1000 + 1;
                          cout << "You have killed a Giant!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
                          
                          
                          health = maxhealth;
                             }
                             
                             
     
     
     
     
     
     
     
      if (arenamonsterhealth1 <= 0 && arenamonsterhealth2 <= 0 && arenamonsterhealth3 <= 3){
                             system ("cls");
                             cout << "You Have Defeated Your First Arena Monster.\n\n";
                             cout << "To Continue Fighting The Monsters Press Enter.\n\n";
                             cin.ignore();
                             cin.get();
                              
                              
                              
                              do {
                              arenamonsterhealth4 = health * 3;
                              cout << "Your Health is: " << health << "\n\n";
                              cout << "Your Enemies Health is: " << arenamonsterhealth4 << "\n\n";
                              cout << "Do You Want To: \n\n";
                              cout << "1. Attack.\n\n";
                              cout << "2. heal.\n\n";
                              cout << "3. Return To the Main Menu.\n\n";   
                                  
                              if (choice == 1){
                                         do {
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";
                              cin >> choice;
                              switch (choice){
                                     case 1:
                                          done = true;
                                          A4melee();
                                     break;
                                     case 2:
                                          done = true;
                                          A4spell();
                                     break;
                                     default:
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                     }
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                                    system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }               
                               
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
                              
                       
                                   // press any key code to go back to the main fighting menu.
                                }
                           else if (choice == 3){mainmenu ();}
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                            } while (arenamonsterhealth4 > 0);
                                 
                          
                          system("cls");
                          
               if (arenamonsterhealth4 <= 0){
                          expe = 0;
                          expe = rand() % 250 + 1;
                          currentexp = currentexp + expe;
                          loot = rand() % 1000 + 1;
                          cout << "You have killed a Giant!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
                                      
                                      
                                      
                if (arenamonsterhealth1 <= 0 && arenamonsterhealth2 <= 0 && arenamonsterhealth3 <= 0 && arenamonsterhealth4 <= 0){
                             system ("cls");
                             cout << "You Have Defeated Your First Arena Monster.\n\n";
                             cout << "To Continue Fighting The Monsters Press Enter.\n\n";
                             cin.ignore();
                             cin.get();
                              
                              
                              
                              do {
                              arenaboss = health * 4;
                              cout << "Your Health is: " << health << "\n\n";
                              cout << "Your Enemies Health is: " << arenaboss << "\n\n";
                              cout << "Do You Want To: \n\n";
                              cout << "1. Attack.\n\n";
                              cout << "2. heal.\n\n";
                              cout << "3. Return To the Main Menu.\n\n";   
                                  
                              if (choice == 1){
                                         do {
                              cout << "What type of attack do you want to use?\n\n";
                              cout << "1. Melee.\n\n";
                              cout << "2. A Spell.\n\n";
                              cin >> choice;
                              switch (choice){
                                     case 1:
                                          done = true;
                                          bossmelee();
                                     break;
                                     case 2:
                                          done = true;
                                          bossspell();
                                     break;
                                     default:
                                          cout << "That is not a choice.\n\n";
                                          cout << "Press Enter to continue.\n\n";
                                          cin.ignore();
                                          cin.get();
                                     }
                                     } while (done != true);
                                     }
                               
                           else if (choice == 2){
                                    system("cls"); 
                               cout << "Which Potion Do You Want To Use?\n\n";   
                               if (WeakHPotion > 0){
                                               cout << "1. Weak Healing Potion.         + 10 Health.\n\n";
                                               }
                                               
                               if (LesserHPotion > 0){
                                               cout << "2. Lesser Healing Potion.       + 25 Health.\n\n";
                                               }
                                               
                               if (HealthPotion > 0){
                                               cout << "3. Health Potion.               + 50 Health.\n\n";
                                               }
                               if (GreaterHPotion > 0){
                                               cout << "4. Greater Healing Potion.      + 100 Health.\n\n";
                                               }
                               cin >> choice;
                               if (choice == 1 && WeakHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 10.\n\n";
                                          health = health + 10;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }  
                                          
                               else if (choice == 2 && LesserHPotion > 0){
                                          system("cls");     
                                          cout << "Your Health Has Increased by 25.\n\n";
                                          health = health + 25;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 3 && HealthPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 50.\n\n";
                                          health = health + 50;
                                          if (health > maxhealth)
                                             health = maxhealth;
                                          }   
                                                      
                               else if (choice == 4 && GreaterHPotion > 0){
                                          system("cls"); 
                                          cout << "Your Health Has Increased by 100.\n\n";
                                          health = health + 100;
                                          if (health > maxhealth){
                                             health = maxhealth;
                                          }               
                                          }
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
                               
                               
                              
                       
                                   // press any key code to go back to the main fighting menu.
                                }
                           else if (choice == 3){
                                mainmenu();
                                }
                           else {
                                cout << "That is not a choice. please try again." << endl;
                                cout << "To continue fighing press Enter." << endl;
                                cin.ignore();
                                cin.get();
                                }
                                
                            } while (arenaboss > 0);
                            }  
                          
                          system("cls");
                          
               if (arenaboss <= 0){
                          expe = 0;
                          expe = rand() % 250 + 1;
                          currentexp = currentexp + expe;
                          loot = rand() % 1000 + 1;
                          cout << "You have killed a Giant!\n";
                          cout << "\nYour loot is: ";
                          cout << loot << " Gold\n\n";
                          cout << "You also got: " << expe << " experience.\n\n";
                          cout << "Your total experience is: " << currentexp << ".\n\n";
                          cout << "\nPress Enter to continue.\n\n";
                          money = money + loot;
                          cin.ignore();
                          cin.get();
                          }
                            if    (currentexp >= lvl * 50){
                                      system ("cls");
                                      currentexp = currentexp - (lvl * 50);
                                      lvl = lvl + 1;
                                      points = points + 3;
                                      cout << "Congratulations " << name << "\n\n";
                                      cout << "You have Leveled up!\n\n";
                                      cout << "You are now level: " << lvl << "\n\n";
                                      cout << "You have Gained 3 Attribute points and 50 gold!\n\n";
                                      cin.ignore();
                                      cout << "\nPress Enter to continue.\n\n";
                                      cin.get();
                                      }
     
     cout << "Coming Soon.\n\n";
     cout << "Press Enter To Return To The Main Menu.\n";
     cin.ignore();
     cin.get();
     mainmenu();
     
     
     
     }
     }
     }
     }
     }

\*This is the battle part.*\

void bossmelee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() %10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / 2;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void bossspell(){
     system("cls");
     if (yourclass == 2){                    
                   bossmagic();
                   }      
     else if (yourclass == 3){
                   bossclasshealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void bossmagic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                bossfireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                bossfirebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                bossfrostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                bosslightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                bosslightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                bosssuperstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void bossclasshealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void bosssuperstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void bosslightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void bosslightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void bossfrostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void bossfirebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void bossfireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenaboss = arenaboss - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }











     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     

void A1melee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() %10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / 2;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void A1spell(){
     system("cls");
     if (yourclass == 2){                    
                   A1magic();
                   }      
     else if (yourclass == 3){
                   A1classhealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void A1magic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                A1fireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                A1firebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                A1frostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                A1lightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                A1lightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                A1superstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void A1classhealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void A1superstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A1lightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 25 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A1lightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 20 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A1frostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 15 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A1firebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A1fireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 5 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
     
     
     
     
     
     
     
     
     
     
     
     
     
     void A2melee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() %10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / 2;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth2 = arenamonsterhealth2 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void A2spell(){
     system("cls");
     if (yourclass == 2){                    
                   A1magic();
                   }      
     else if (yourclass == 3){
                   A1classhealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void A2magic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                A2fireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                A2firebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                A2frostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                A2lightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                A2lightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                A2superstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void A2classhealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void A2superstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth2 = arenamonsterhealth2 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A2lightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 25 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth2 = arenamonsterhealth2 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A2lightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 20 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth1 = arenamonsterhealth1 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A2frostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 15 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth2 = arenamonsterhealth2 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A2firebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth2 = arenamonsterhealth2 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A2fireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 5 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth2 = arenamonsterhealth2 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }













void A3melee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() %10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / 2;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void A3spell(){
     system("cls");
     if (yourclass == 2){                    
                   A3magic();
                   }      
     else if (yourclass == 3){
                   A3classhealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void A3magic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                A3fireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                A3firebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                A3frostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                A3lightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                A3lightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                A3superstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void A3classhealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void A3superstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A3lightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 25 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A3lightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 20 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A3frostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 15 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A3firebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A3fireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 5 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth3 = arenamonsterhealth3 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     
     void A4melee (){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() %10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * str;
                               dmg = dmg / 2;
                               cout <<  "You hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
                               
     }
     
     
void A4spell(){
     system("cls");
     if (yourclass == 2){                    
                   A4magic();
                   }      
     else if (yourclass == 3){
                   A4classhealing();
          }
          
     cout << "Press Enter to continue.\n\n";

      
     }
     
     
void A4magic(){
     bool done = false;
     cout << "What Spell do you want to cast?\n\n";
     if (mana >= 0){
              cout << "1. Fireball.\n\n";
              }
              
     if (mana >= 5){
              cout << "2. FireBolt.\n\n";
              }
              
     if (mana >= 10){
              cout << "3. FrostBolt.\n\n";
              }
              
     if (mana >= 15){
              cout << "4. Lightning Strike.\n\n";
              }
              
     if (mana >= 20){
              cout << "5. LightningBolt.\n\n";
              }
              
     if (mana >= 25){
              cout << "6. SuperStrike.\n\n";
              }
     cin >> choice;
     do {
     if (mana >= 0 & choice == 1){
                done = true;
                A4fireball();
                }
     else if (mana >= 5 & choice == 2){
          done = true;
                A4firebolt();
                }
                
     else if (mana >= 10 & choice == 3){
          done = true;
                A4frostbolt();
                }
                
     else if (mana >= 15 & choice == 4){
          done = true;
                A4lightningstrike();
                }
                
     else if (mana >= 20 & choice == 5){
          done = true;
                A4lightningbolt();
                }
                
                
     else if (mana >= 25 & choice == 6){
          done = true;
                A4superstrike();
                }
                
     else {
          cout << "That is not a choice.\n\n";
          cout << "Press Enter to continue.\n\n";
          cin.ignore();
          cin.get();
          }
     }
     while (done != true);
}
     
     
void A4classhealing(){
     system("cls");
     cout << "A work in Progress.\n\n";
     cout << "Press Enter to continue.\n\n";
     cin.ignore();
     cin.get();
     }
     

void A4superstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 30 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A4lightningbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 25 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A4lightningstrike(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 20 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A4frostbolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 15 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A4firebolt(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 10 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
void A4fireball(){
     system("cls");
                               dmg = 0;
                               mdmg = 0;
                               mdmg = rand() % 10 + 1;
                               mdmg = mdmg * str;
                               mdmg = mdmg / def;
                               dmg = rand() % 5 + 1;
                               dmg = dmg * mana;
                               dmg = dmg / 2;
                               cout <<  "You Cast a Super Strike and hit your enemy for: " << dmg << endl << endl << endl;
                               health = health - mdmg;
                               arenamonsterhealth4 = arenamonsterhealth4 - dmg;
                               cout <<  "Your enemy hit you for:" <<  mdmg << endl << endl << endl;
                               cout << "To continue fighing press Enter." << endl;
                               cin.ignore();
                               cin.get();
     }
skorm909
Junior Poster
111 posts since Feb 2010
Reputation Points: 10
Solved Threads: 3
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: