mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-17 02:50:29 +00:00
Core/Account: Add total time played in account (#1003)
This saves the total time played on the account, even if your characters have been deleted.
This commit is contained in:
@@ -1633,6 +1633,7 @@ void Player::Update(uint32 p_time)
|
||||
uint32 elapsed = uint32(now - m_Last_tick);
|
||||
m_Played_time[PLAYED_TIME_TOTAL] += elapsed; // Total played time
|
||||
m_Played_time[PLAYED_TIME_LEVEL] += elapsed; // Level played time
|
||||
GetSession()->SetTotalTime(GetSession()->GetTotalTime() + elapsed);
|
||||
m_Last_tick = now;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user