GRA RPG  DM & KK
Projekt na PO3
Wizzard Class Reference

Class Wizzard Inherits a champion. More...

#include <Wizzard.h>

Inheritance diagram for Wizzard:
Champion

Public Member Functions

 Wizzard (const unsigned id, const std::string n, unsigned int l, unsigned int e, double m, int he, int st, int de, int ma, int def, int lu)
 Constructor Archer cause a champion constructor. More...
 
virtual int attack () override
 Virtual function attack. More...
 
virtual Wizzardclone () const
 Virtual function clone to clone object. More...
 
- Public Member Functions inherited from Champion
 Champion (const unsigned id, const std::string n, unsigned int l, unsigned int e, double m, int he, int st, int de, int ma, int def, int lu)
 Constructor Champion. More...
 
virtual int block ()
 Virtual function block. More...
 
int heal ()
 Function return Helath the value to heal the hero. More...
 
void setHealth (int hp)
 Function set Health. More...
 
int getHealth () const
 Function get Health champion. More...
 
std::string getName ()
 Function get Name champion. More...
 
void addHealth (int hp)
 Function add Health. More...
 
void addStrength (int stren)
 Function add Strength. More...
 
void addDexterity (int dex)
 Function add Dexterity. More...
 
void addMagic (int mag)
 Function add Magic. More...
 
void addDefence (int def)
 Function add Health. More...
 
void addLuck (int luc)
 Function add Lucky. More...
 
void addMoney (int mon)
 Function add Money. More...
 
void addExperience (int exp)
 Function add Experience. More...
 
void takeMoney (double mon)
 Function add Money. More...
 
int getId ()
 Get Id. More...
 
int getExperince ()
 Get Experience. More...
 
int getLevel ()
 Get Level. More...
 
int getMoney ()
 Get Money. More...
 
int getStrength ()
 Get Strength. More...
 
int getDexterity ()
 Get Dexterity. More...
 
int getMagic ()
 Get Magic. More...
 
int getDefence ()
 Get Defence. More...
 
int getLuck ()
 Get Lucky. More...
 

Additional Inherited Members

- Protected Attributes inherited from Champion
const unsigned int id_champion
 
const std::string name
 
unsigned int level
 
unsigned int experience
 
double money
 
int health
 
int strength
 
int dexterity
 
int magic
 
int defence
 
int luck
 

Detailed Description

Class Wizzard Inherits a champion.

Constructor & Destructor Documentation

◆ Wizzard()

Wizzard::Wizzard ( const unsigned  id,
const std::string  n,
unsigned int  l,
unsigned int  e,
double  m,
int  he,
int  st,
int  de,
int  ma,
int  def,
int  lu 
)
inline

Constructor Archer cause a champion constructor.

Parameters
id- Id champion in database
n- Name champion
l- Level champion
e- Experience champion
m- Money champion
he- Health champion
st- Strength champion
de- Dexerity Champion
ma- Magic champion
def- Defence champion
lu- Lucky champion

Member Function Documentation

◆ attack()

int Wizzard::attack ( )
overridevirtual

Virtual function attack.

Returns
value attack

Reimplemented from Champion.

◆ clone()

virtual Wizzard* Wizzard::clone ( ) const
inlinevirtual

Virtual function clone to clone object.

Returns
Pointer object Archer

Implements Champion.