summaryrefslogtreecommitdiff
path: root/src/gui/windows/killstats.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-03-06 00:39:58 +0300
committerAndrei Karas <akaras@inbox.ru>2014-03-06 23:06:15 +0300
commit6b291b6515825f4ce0e09df5dec7ea1b619b63a7 (patch)
treef26a35a21cde34f45538a191b2196bf7c81d2693 /src/gui/windows/killstats.cpp
parent833e498f54c1d33be94c09214315b368cccaec06 (diff)
downloadplus-6b291b6515825f4ce0e09df5dec7ea1b619b63a7.tar.gz
plus-6b291b6515825f4ce0e09df5dec7ea1b619b63a7.tar.bz2
plus-6b291b6515825f4ce0e09df5dec7ea1b619b63a7.tar.xz
plus-6b291b6515825f4ce0e09df5dec7ea1b619b63a7.zip
improve a bit different code.
Diffstat (limited to 'src/gui/windows/killstats.cpp')
-rw-r--r--src/gui/windows/killstats.cpp14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/gui/windows/killstats.cpp b/src/gui/windows/killstats.cpp
index 710875a3c..f4557a460 100644
--- a/src/gui/windows/killstats.cpp
+++ b/src/gui/windows/killstats.cpp
@@ -27,6 +27,7 @@
#include "gui/widgets/layout.h"
#include "actormanager.h"
+#include "client.h"
#include "game.h"
#include "being/localplayer.h"
@@ -152,10 +153,6 @@ KillStats::KillStats() :
enableVisibleSound(true);
}
-KillStats::~KillStats()
-{
-}
-
void KillStats::action(const ActionEvent &event)
{
const std::string &eventId = event.getId();
@@ -303,6 +300,15 @@ void KillStats::recalcStats()
m1minExpNum = newExp;
}
+ if (curTime != 0 && mLastHost == 0xFF6B66 && cur_time > 1)
+ {
+ const int newExp = PlayerInfo::getAttribute(PlayerInfo::EXP_NEEDED);
+ if (m1minExpTime != 0)
+ m1minSpeed = newExp - m1minExpNum;
+ mStatsReUpdated = true;
+ m1minExpNum = newExp;
+ }
+
if (curTime - m5minExpTime > 60*5)
{
const int newExp = PlayerInfo::getAttribute(PlayerInfo::EXP);