Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include "the_commends_choice.h"
- #include <iostream>
- #include "../entry_to_game/choice_the_hero.h"
- #include "../classes_charackter/class_defender.h"
- #include "../classes_charackter/class_lycanthrope.h"
- #include "../classes_charackter/class_mage.h"
- #include "../classes_charackter/class_ninja.h"
- #include "../classes_charackter/class_shaman.h"
- #include "../classes_charackter/class_warrior.h"
- #include "../classes_charackter/class_mefiksos.h"
- #include "../entry_to_game/sleep_and_clear.h"
- #include "../instructions/instructions.h"
- #include <conio.h>
- #include "../entry_to_game/choice_the_hero.h"
- #include <cstdlib>
- #include "../entry_to_game/the_last_game.h"
- #include "../fight_with_monster/monsters_vs_heros.h"
- void checkTheCommends()
- {
- unsigned char commendWhatMakeTheHero;
- for(;;){
- commendWhatMakeTheHero=getch();
- switch(commendWhatMakeTheHero){
- case 'W':
- case 'w':
- system("cls");
- if(heroWithWhoYouPlay=='1' || theLastCharackter=='1'){
- Defender::defender().oneMoveToUpDefender();
- Defender::defender().positionDefender();
- }else if(heroWithWhoYouPlay=='2' || theLastCharackter=='2'){
- Lycanthrope::lycanthrope().oneMoveToUpLycanthrope();
- Lycanthrope::lycanthrope().positionLycanthrope();
- }else if(heroWithWhoYouPlay=='3' || theLastCharackter=='3'){
- Mage::mage().oneMoveToUpMage();
- Mage::mage().positionMage();
- }else if(heroWithWhoYouPlay=='4' || theLastCharackter=='4'){
- Ninja::ninja().oneMoveToUpNinja();
- Ninja::ninja().positionNinja();
- }else if(heroWithWhoYouPlay=='5' || theLastCharackter=='5'){
- Shaman::shaman().oneMoveToUpShaman();
- Shaman::shaman().positionShaman();
- }else if(heroWithWhoYouPlay=='6' || theLastCharackter=='6'){
- Warrior::warrior().oneMoveToUpWarrior();
- Warrior::warrior().positionWarrior();
- }else if(heroWithWhoYouPlay==',' || theLastCharackter==','){
- Mefiksos::mefiksos().oneMoveToUpMefiksos();
- Mefiksos::mefiksos().positionMefiksos();
- }else{}
- break;
- case 'S':
- case 's':
- system("cls");
- if(heroWithWhoYouPlay=='1' || theLastCharackter=='1'){
- Defender::defender().oneMoveToDownDefender();
- Defender::defender().positionDefender();
- }else if(heroWithWhoYouPlay=='2' || theLastCharackter=='2'){
- Lycanthrope::lycanthrope().oneMoveToDownLycanthrope();
- Lycanthrope::lycanthrope().positionLycanthrope();
- }else if(heroWithWhoYouPlay=='3' || theLastCharackter=='3'){
- Mage::mage().oneMoveToDownMage();
- Mage::mage().positionMage();
- }else if(heroWithWhoYouPlay=='4' || theLastCharackter=='4'){
- Ninja::ninja().oneMoveToDownNinja();
- Ninja::ninja().positionNinja();
- }else if(heroWithWhoYouPlay=='5' || theLastCharackter=='5'){
- Shaman::shaman().oneMoveToDownShaman();
- Shaman::shaman().positionShaman();
- }else if(heroWithWhoYouPlay=='6' || theLastCharackter=='5'){
- Warrior::warrior().oneMoveToDownWarrior();
- Warrior::warrior().positionWarrior();
- }else if(heroWithWhoYouPlay==',' || theLastCharackter==','){
- Mefiksos::mefiksos().oneMoveToDownMefiksos();
- Mefiksos::mefiksos().positionMefiksos();
- }else{}
- break;
- case 'A':
- case 'a':
- system("cls");
- if(heroWithWhoYouPlay=='1' || theLastCharackter=='1'){
- Defender::defender().oneMoveToLeftDefender();
- Defender::defender().positionDefender();
- }else if(heroWithWhoYouPlay=='2' || theLastCharackter=='2'){
- Lycanthrope::lycanthrope().oneMoveToLeftLycanthrope();
- Lycanthrope::lycanthrope().positionLycanthrope();
- }else if(heroWithWhoYouPlay=='3' || theLastCharackter=='3'){
- Mage::mage().oneMoveToLeftMage();
- Mage::mage().positionMage();
- }else if(heroWithWhoYouPlay=='4' || theLastCharackter=='4'){
- Ninja::ninja().oneMoveToLeftNinja();
- Ninja::ninja().positionNinja();
- }else if(heroWithWhoYouPlay=='5' || theLastCharackter=='5'){
- Shaman::shaman().oneMoveToLeftShaman();
- Shaman::shaman().positionShaman();
- }else if(heroWithWhoYouPlay=='6' || theLastCharackter=='6'){
- Warrior::warrior().oneMoveToLeftWarrior();
- Warrior::warrior().positionWarrior();
- }else if(heroWithWhoYouPlay==',' || theLastCharackter==','){
- Mefiksos::mefiksos().oneMoveToLeftMefiksos();
- Mefiksos::mefiksos().positionMefiksos();
- }else{}
- break;
- case 'D':
- case 'd':
- system("cls");
- if(heroWithWhoYouPlay=='1' || theLastCharackter=='1'){
- Defender::defender().oneMoveToRightDefender();
- Defender::defender().positionDefender();
- }else if(heroWithWhoYouPlay=='2' || theLastCharackter=='2'){
- Lycanthrope::lycanthrope().oneMoveToRightLycanthrope();
- Lycanthrope::lycanthrope().positionLycanthrope();
- }else if(heroWithWhoYouPlay=='3' || theLastCharackter=='3'){
- Mage::mage().oneMoveToRightMage();
- Mage::mage().positionMage();
- }else if(heroWithWhoYouPlay=='4' || theLastCharackter=='4'){
- Ninja::ninja().oneMoveToRightNinja();
- Ninja::ninja().positionNinja();
- }else if(heroWithWhoYouPlay=='5' || theLastCharackter=='5'){
- Shaman::shaman().oneMoveToRightShaman();
- Shaman::shaman().positionShaman();
- }else if(heroWithWhoYouPlay=='6' || theLastCharackter=='6'){
- Warrior::warrior().oneMoveToRightWarrior();
- Warrior::warrior().positionWarrior();
- }else if(heroWithWhoYouPlay==',' || theLastCharackter==','){
- Mefiksos::mefiksos().oneMoveToRightMefiksos();
- Mefiksos::mefiksos().positionMefiksos();
- }else{}
- break;
- system ("cls");
- case 'E':///ekwipunek
- case 'e':
- std::cout<<" ==============================\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" ==============================\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" ==============================\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" ==============================\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" | | | | | |\n";
- std::cout<<" ==============================\n";
- break;
- case 'H':
- case 'h':
- system("cls");
- instructions();
- break;
- case 'T':///pokazanie statystyk i skili
- case 't':
- system("cls");
- if(heroWithWhoYouPlay=='1' || theLastCharackter=='1'){
- Defender::defender().howSeeTheAttributsDefender();
- }else if(heroWithWhoYouPlay=='2' || theLastCharackter=='2'){
- Lycanthrope::lycanthrope().howSeeTheAttributsLycanthrope();
- }else if(heroWithWhoYouPlay=='3' || theLastCharackter=='3'){
- Mage::mage().howSeeTheAttributsMage();
- }else if(heroWithWhoYouPlay=='4' || theLastCharackter=='4'){
- Ninja::ninja().howSeeTheAttributsNinja();
- }else if(heroWithWhoYouPlay=='5' || theLastCharackter=='5'){
- Shaman::shaman().howSeeTheAttributsShaman();
- }else if(heroWithWhoYouPlay=='6' || theLastCharackter=='6'){
- Warrior::warrior().howSeeTheAttributsWarrior();
- }else if(heroWithWhoYouPlay==',' || theLastCharackter==','){
- Mefiksos::mefiksos().howSeeTheAttributsMefiksos();
- }else{}
- break;
- case 'F':///walka z potworami
- case 'f':
- system("cls");
- fighting();
- break;
- case '1':
- system("cls");
- ///skill 1
- break;
- case '2':
- system("cls");
- ///skill 2
- break;
- case '3':
- system("cls");
- ///skill 3
- break;
- case '4':
- system("cls");
- /// skill 4
- break;
- case '5':
- system("cls");
- ///skill 5
- break;
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement