summaryrefslogtreecommitdiff
path: root/src/localplayer.cpp
diff options
context:
space:
mode:
authorJared Adams <jaxad0127@gmail.com>2009-07-06 13:06:12 -0600
committerJared Adams <jaxad0127@gmail.com>2009-07-06 13:06:12 -0600
commit851f67cd9975b090b051decb1deab6b0489d14c5 (patch)
tree05e4256f0ec5128cc0bee41b3992f3c8c0111926 /src/localplayer.cpp
parente0de8a124bf94b79d9d64e5406b21e8598a05d56 (diff)
downloadmana-851f67cd9975b090b051decb1deab6b0489d14c5.tar.gz
mana-851f67cd9975b090b051decb1deab6b0489d14c5.tar.bz2
mana-851f67cd9975b090b051decb1deab6b0489d14c5.tar.xz
mana-851f67cd9975b090b051decb1deab6b0489d14c5.zip
Merge some player stats
Diffstat (limited to 'src/localplayer.cpp')
-rw-r--r--src/localplayer.cpp16
1 files changed, 6 insertions, 10 deletions
diff --git a/src/localplayer.cpp b/src/localplayer.cpp
index 2f8761e7..240f0a65 100644
--- a/src/localplayer.cpp
+++ b/src/localplayer.cpp
@@ -94,13 +94,11 @@ LocalPlayer::LocalPlayer(int id, int job, Map *map):
mAttackRange(0),
ATK(0), MATK(0), DEF(0), MDEF(0), HIT(0), FLEE(0),
ATK_BONUS(0), MATK_BONUS(0), DEF_BONUS(0), MDEF_BONUS(0), FLEE_BONUS(0),
- mStatPoint(0), mSkillPoint(0),
- mStatsPointsToAttribute(0),
+ mSkillPoint(0),
mEquipment(new Equipment),
#endif
mInStorage(false),
#ifdef EATHENA_SUPPORT
- mXp(0),
mTargetTime(-1),
#endif
mLastTarget(-1),
@@ -843,13 +841,13 @@ std::pair<int, int> LocalPlayer::getExperience(int skill)
return std::pair<int, int> (mExpCurrent.at(skill), mExpNext.at(skill));
}
-#else
+#endif
-void LocalPlayer::setXp(int xp)
+void LocalPlayer::setLevelProgress(int percent)
{
- if (mMap && xp > mXp)
+ if (mMap && percent > percent)
{
- const std::string text = toString(xp - mXp) + " xp";
+ const std::string text = toString(percent - percent) + " xp";
// Show XP number
particleEngine->addTextRiseFadeOutEffect(
@@ -859,11 +857,9 @@ void LocalPlayer::setXp(int xp)
&guiPalette->getColor(Palette::EXP_INFO),
gui->getInfoParticleFont(), true);
}
- mXp = xp;
+ mLevelProgress = percent;
}
-#endif
-
void LocalPlayer::pickedUp(const std::string &item)
{
if (mMap)