fix(Core/Players): Fixed getting resting exp in cities/inns. (#8020)
Fixes #7939
This commit is contained in:
parent
0c8fb1ea73
commit
cff7cc58ff
1 changed files with 2 additions and 1 deletions
|
|
@ -103,6 +103,7 @@ void Player::Update(uint32 p_time)
|
|||
}
|
||||
}
|
||||
|
||||
time_t lastTick = m_Last_tick;
|
||||
if (now > m_Last_tick)
|
||||
{
|
||||
// Update items that have just a limited lifetime
|
||||
|
|
@ -231,7 +232,7 @@ void Player::Update(uint32 p_time)
|
|||
|
||||
if (HasFlag(PLAYER_FLAGS, PLAYER_FLAGS_RESTING))
|
||||
{
|
||||
if (now > m_Last_tick && _restTime > 0) // freeze update
|
||||
if (now > lastTick && _restTime > 0) // freeze update
|
||||
{
|
||||
time_t currTime = time(nullptr);
|
||||
time_t timeDiff = currTime - _restTime;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue