diff options
Diffstat (limited to 'src/localplayer.cpp')
-rw-r--r-- | src/localplayer.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/localplayer.cpp b/src/localplayer.cpp index cc270296..fa8db881 100644 --- a/src/localplayer.cpp +++ b/src/localplayer.cpp @@ -40,6 +40,7 @@ LocalPlayer *player_node = NULL; LocalPlayer::LocalPlayer(Uint32 id, Uint16 job, Map *map): Player(id, job, map), + mXp(0), mAttackRange(0), mInventory(new Inventory()), mTarget(NULL), mPickUpTarget(NULL), @@ -426,3 +427,12 @@ void LocalPlayer::revive() outMsg.writeInt16(0x00b2); outMsg.writeInt8(0); } + +void LocalPlayer::refreshXp(Uint32 xp) +{ + if (mTarget && xp > mXp) + { + mTarget->showXP(xp-mXp); + } + mXp = xp; +} |