diff options
Diffstat (limited to 'src/game/Level2.cpp')
-rw-r--r-- | src/game/Level2.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/game/Level2.cpp b/src/game/Level2.cpp index dc9d84bf4c8..106c573dc35 100644 --- a/src/game/Level2.cpp +++ b/src/game/Level2.cpp @@ -42,7 +42,7 @@ #include "GlobalEvents.h" #include "OutdoorPvPWG.h" #include "OutdoorPvPMgr.h" - +#include "TimeMgr.h" #include "TargetedMovementGenerator.h" // for HandleNpcUnFollowCommand #include "CreatureGroups.h" @@ -79,7 +79,7 @@ bool ChatHandler::HandleMuteCommand(const char* args) if(HasLowerSecurity (target,target_guid,true)) return false; - time_t mutetime = time(NULL) + notspeaktime*60; + time_t mutetime = sGameTime.GetGameTime() + notspeaktime*60; if (target) target->GetSession()->m_muteTime = mutetime; @@ -536,7 +536,7 @@ bool ChatHandler::HandleGameObjectTargetCommand(const char* args) if(target) { - int32 curRespawnDelay = target->GetRespawnTimeEx()-time(NULL); + int32 curRespawnDelay = target->GetRespawnTimeEx()-sGameTime.GetGameTime(); if(curRespawnDelay < 0) curRespawnDelay = 0; @@ -3502,8 +3502,8 @@ bool ChatHandler::HandleEventInfoCommand(const char* args) std::string endTimeStr = TimeToTimestampStr(eventData.end); uint32 delay = gameeventmgr.NextCheck(event_id); - time_t nextTime = time(NULL)+delay; - std::string nextStr = nextTime >= eventData.start && nextTime < eventData.end ? TimeToTimestampStr(time(NULL)+delay) : "-"; + time_t nextTime = sGameTime.GetGameTime()+delay; + std::string nextStr = nextTime >= eventData.start && nextTime < eventData.end ? TimeToTimestampStr(sGameTime.GetGameTime()+delay) : "-"; std::string occurenceStr = secsToTimeString(eventData.occurence * MINUTE); std::string lengthStr = secsToTimeString(eventData.length * MINUTE); |