From 2891f4e2cfa806f042471c524209ef6272b7335f Mon Sep 17 00:00:00 2001 From: Abdullaahi Farah Date: Mon, 4 Mar 2019 19:18:35 +0000 Subject: [PATCH 1/2] Added placeholder descriptions for heroes --- Database/Game_Database.sqlite | Bin 45056 -> 45056 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/Database/Game_Database.sqlite b/Database/Game_Database.sqlite index 8dc658456894f1dfaa281d58abe9c5e64c3cadc0..eca21553ce72ddcf56634df77e271d7976d8082d 100644 GIT binary patch delta 381 zcmZp8z|`=7X@WGP%0wAwRuu+4m4=NebNMCt*%>(b<}&l&;d{ovn|}s>Dc@oK0Dd*T zxtkRQn)&KgI5`<*6`7cr7#TU8QWJ|yauf3$6_QfH3_Zp;h7*j3LNyfGI2k47!K&Ci zO7lumiyRd)z_cFY5{3ngOWcg)nK&6mrI|#51~K_2rl&e8s0}^u*Q!?|I)EFfg`OMuU*f<#_AyRA}rFkW(MT|=r7BDVx zGm>D1%diF%Wu_K~l`tM+)M5CgVmtyhG%S_KGVTxeb!f;0;K%AMAQ5<3%b4W&J tY8vANhG~q40yHF;I2lEGnM8qZXYx% Date: Mon, 4 Mar 2019 19:23:07 +0000 Subject: [PATCH 2/2] Added heroSelection.cpp --- src/heroSelection.cpp | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 src/heroSelection.cpp diff --git a/src/heroSelection.cpp b/src/heroSelection.cpp new file mode 100644 index 0000000..83e1fff --- /dev/null +++ b/src/heroSelection.cpp @@ -0,0 +1,43 @@ +#include "../include/mainMenu.hpp" +#include "../include/Game.hpp" +#include +#include +#include +#include +#include "../include/GameWindow.hpp" +using namespace std; + +int main() +{ + initscr(); + GameWindow selectionWin(0,0,0,0); + GameWindow heroDescr(0,0,0,0); + getch(); + int selectedHeroes [5] = { }; + int heroChoice; + int i; + + vector> heroNames = + { + {"Warrior","Fearless warrior and weapon expert. A good choice for players who like a good combination of damage and speed.\n Abilities :\n 1)Shield Bash(attacks the enemy hero with a shield and has a chance to stun the other hero for 1 turn )\n 2)Spear Charge(sprints towards the enemy to stab him with the spear, ignores armor and has slight chance to cause bleed for 3 turns"}, + {"Mage","Mage of the famous dragon academy of sorcery. This mage is able to attack from a distance with devastating spells.\n Abilities:\n 1)Magic Arrow(shoots an arrow made up of magic)\n 2)Curse(decreases the damage,defense and speed of a chosen enemy hero for 2 turns)"}, + {"Thief","A lowly man who resorted to thievery in order to make it through the day. This thief relies on high damage and poison in order to kill his enemies.\n Abilities:\n 1)Poison Dagger(does not deal a lot of damage however it has a big chance to poison the enemy and deal damage for 3 turns)\n 2)Parry(if the thief is attacked by an enemy hero immediately after using this ability there is a 50% chance that the enemy hero will miss and get stunned for 2 turns)"}, + {"Knight","A noble knight equipped with high defense gear and an 'ultra_great_sword' that crushes everything in it's way.\n Abilities:\n 1)Block(with his mighty 'great_shield' the knight is able to block an attack for the whole team however the attack will still do some minor damage)\n 2)Iron skin(buffs the defence of the knight for 2 turns)"}, + {"Cleric","This pious cleric is able to cast holy miracles in order to aid those around him.\n Abilities:\n 1)Divine Blessing(buffs a chosen hero in the party increasing dmg,speed and defence for 2 turns)\n 2)Grand heal(Heals a chosen hero in the party for 25% of his hp however it takes a long time to cast)"}, + {"Hunter","This man is a famous hunter of beasts and man alike. He will strike down every enemy from afar with his deadly arrows.\n Abilities:\n 1)Poison Arrow(shoots a poisonous arrow that has a chance to poison the enemy for 3 turns)\n 2)Aerial strike(shoots an arrow at every hero at once however there's a 30% chance of missing)"}, + {"Paladin","Holy man whose sole duty is to purge to wicked from the world with the aid of his holy hammer.\n Abilities:\n 1)Minor Heal(Is able to heal himself for 10% of his hp)\n 2)Hammer Bash(Attack an enemy hero with a high chance to stun him for 1 turn)"}, + {"Beastman","This deprived man was abandonded in the wilderness. In order to survive he had to adapt to his surroundings and abandon his humanity and any notion of civilization prior to his exile.\n Abilities:\n 1)Bite(charge at an enemy hero to bite his throat. The attack has a medium chance to deal bleed damage for 3 turns)\n 2)Howl(Shout at an enemy hero to intimidate him. The targeted heroes losses all buffs aplied on him and, his speed and defence are decreased for 1 turn)"}, + {"Alchemist","The alchemist is able to craft potions capable of aiding the allies or damage the enemy.\n Abilities:\n 1)Fire Bomb(once thrown it deals damage and has a chance to set the enemy on fire)\n 2)Mana and Healing Potion(restores a little hp and mp)"}, + }; + + for ( i=0; i<=5; ++i) + { + heroChoice=selectionWin.Menu(hero,heroDescr); + string to_print = "You've selected " + heroNames[heroChoice]; + heroDescr.Print(to_print.c_str()); + getch(); + endwin(); + selectedHeroes[i] = heroChoice; + } + return selectedHeroes; +} \ No newline at end of file