mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-16 10:30:27 +00:00
i.e. world update start
This commit is contained in:
committed by
Francesco Borzì
parent
1b7522ff0e
commit
51b8773528
@@ -20,6 +20,7 @@
|
||||
#include "ObjectMgr.h"
|
||||
#include "World.h"
|
||||
#include "Group.h"
|
||||
#include "GameTime.h"
|
||||
#include "InstanceScript.h"
|
||||
#include "ScriptMgr.h"
|
||||
|
||||
@@ -77,7 +78,7 @@ InstanceSave* InstanceSaveManager::AddInstanceSave(uint32 mapId, uint32 instance
|
||||
}
|
||||
else
|
||||
{
|
||||
resetTime = time(NULL) + 3*DAY; // normals expire after 3 days even if someone is still bound to them, cleared on startup
|
||||
resetTime = GameTime::GetGameTime() + 3*DAY; // normals expire after 3 days even if someone is still bound to them, cleared on startup
|
||||
extendedResetTime = 0;
|
||||
}
|
||||
InstanceSave* save = new InstanceSave(mapId, instanceId, difficulty, resetTime, extendedResetTime);
|
||||
@@ -239,7 +240,7 @@ void InstanceSaveManager::LoadInstances()
|
||||
|
||||
void InstanceSaveManager::LoadResetTimes()
|
||||
{
|
||||
time_t now = time(NULL);
|
||||
time_t now = GameTime::GetGameTime();
|
||||
time_t today = (now / DAY) * DAY;
|
||||
|
||||
// load the global respawn times for raid/heroic instances
|
||||
@@ -400,7 +401,7 @@ void InstanceSaveManager::ScheduleReset(time_t time, InstResetEvent event)
|
||||
|
||||
void InstanceSaveManager::Update()
|
||||
{
|
||||
time_t now = time(NULL);
|
||||
time_t now = GameTime::GetGameTime();
|
||||
time_t t;
|
||||
bool resetOccurred = false;
|
||||
|
||||
@@ -499,7 +500,7 @@ void InstanceSaveManager::_ResetOrWarnAll(uint32 mapid, Difficulty difficulty, b
|
||||
if (!mapEntry->Instanceable())
|
||||
return;
|
||||
|
||||
time_t now = time(NULL);
|
||||
time_t now = GameTime::GetGameTime();
|
||||
|
||||
if (!warn)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user