From: Daniel Karbach Date: Wed, 8 Aug 2012 18:59:20 +0000 (+0200) Subject: added initializer lists to Hero and Monster models X-Git-Url: http://git.localhorst.tv/?a=commitdiff_plain;h=d7927b645a22776d6e1e1c209365e8f74c4350e9;hp=e16f1b77f9d7f09d232cfe34e4fc8b4be06f571d;p=l2e.git added initializer lists to Hero and Monster models --- diff --git a/src/battle/Hero.cpp b/src/battle/Hero.cpp index faaf841..3fbd320 100644 --- a/src/battle/Hero.cpp +++ b/src/battle/Hero.cpp @@ -9,13 +9,28 @@ namespace battle { -Hero::Hero() { - // TODO Auto-generated constructor stub +Hero::Hero() +: name("") +, sprite(0) + +, maxHealth(0) +, health(0) +, maxMana(0) +, mana(0) + +, attack(0) +, defense(0) +, agility(0) +, intelligence(0) +, gut(0) +, magicResistance(0) + +, level(0) +, ip(0) { } Hero::~Hero() { - // TODO Auto-generated destructor stub } diff --git a/src/battle/Monster.cpp b/src/battle/Monster.cpp index 1a52b79..acbe6cf 100644 --- a/src/battle/Monster.cpp +++ b/src/battle/Monster.cpp @@ -9,14 +9,35 @@ namespace battle { -Monster::Monster() { - // TODO Auto-generated constructor stub +Monster::Monster() +: name("") +, sprite(0) +, dropItem(0) +, attackScript(0) +, defenseScript(0) + +, maxHealth(0) +, health(0) +, maxMana(0) +, mana(0) + +, attack(0) +, defense(0) +, agility(0) +, intelligence(0) +, gut(0) +, magicResistance(0) + +, expReward(0) +, goldReward(0) + +, level(0) +, dropChance(0) { } Monster::~Monster() { - // TODO Auto-generated destructor stub } -} /* namespace battle */ +}