]> git.localhorst.tv Git - l2e.git/blobdiff - src/common/Hero.h
added experience as a common hero property
[l2e.git] / src / common / Hero.h
index caa8f4dba2a5e71c1074c0be28021c6f1a3d3aea..6c03eee0ae4cc7f06adb9b251979599b342354da 100644 (file)
@@ -19,6 +19,9 @@ namespace common {
 
 class Hero {
 
+public:
+       static const int TYPE_ID = 301;
+
 public:
        Hero();
        ~Hero() { }
@@ -44,6 +47,7 @@ public:
        const Stats &GetStats() const { return stats; }
 
        Uint8 Level() const { return level; }
+       int Experience() const { return experience; }
 
        Item *Weapon() { return weapon; }
        Item *Armor() { return armor; }
@@ -69,6 +73,7 @@ public:
        const std::vector<const Spell *> &Spells() const { return spells; }
 
        graphics::Sprite *BattleSprite() { return battleSprite; }
+       const graphics::Sprite *BattleSprite() const { return battleSprite; }
        graphics::Animation *MeleeAnimation() { return meleeAnimation; }
        graphics::Animation *AttackAnimation() { return attackAnimation; }
        graphics::Animation *SpellAnimation() { return spellAnimation; }
@@ -100,6 +105,7 @@ private:
        Stats stats;
 
        int level;
+       int experience;
 
        Item *weapon;
        Item *armor;