summaryrefslogtreecommitdiff
path: root/src/game-server/character.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/game-server/character.hpp')
-rw-r--r--src/game-server/character.hpp21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/game-server/character.hpp b/src/game-server/character.hpp
index 8b04e8cb..fbba4eee 100644
--- a/src/game-server/character.hpp
+++ b/src/game-server/character.hpp
@@ -291,6 +291,21 @@ class Character : public Being
{ return mStatusEffects.end(); }
/**
+ * used to serialized kill count
+ */
+ int getKillCountSize() const
+ { return mKillCount.size(); }
+
+ const std::map<int, int>::const_iterator getKillCountBegin() const
+ { return mKillCount.begin(); }
+
+ const std::map<int, int>::const_iterator getKillCountEnd() const
+ { return mKillCount.end(); }
+
+ void setKillCount(int monsterId, int kills)
+ { mKillCount[monsterId] = kills; }
+
+ /**
* Gets total accumulated exp for skill
*/
int getExperience(int skill) const
@@ -303,6 +318,11 @@ class Character : public Being
{ mExperience[skill] = 0; receiveExperience(skill, value, 0); }
/**
+ * Adds one kill of the monster type to the characters kill count
+ */
+ void incrementKillCount(int monsterType);
+
+ /**
* Shortcut to get being's health
*/
int getHealth() const
@@ -425,6 +445,7 @@ class Character : public Being
unsigned char mAccountLevel; /**< Account level of the user. */
int mParty; /**< Party id of the character */
TransactionType mTransaction; /**< Trade/buy/sell action the character is involved in. */
+ std::map<int, int> mKillCount; /**< how many monsters the character has slayn of each type */
protected:
/**