diff options
| author | xinef1 <w.szyszko2@gmail.com> | 2017-03-02 02:19:25 +0100 |
|---|---|---|
| committer | Shauren <shauren.trinity@gmail.com> | 2019-08-17 20:04:14 +0200 |
| commit | 60663d1374beef3103f4787152654034fa4a8897 (patch) | |
| tree | 38e07d44442ad903a9729536942e8e253a072274 /src/server/scripts/Events | |
| parent | 98180ecdc179386270e93b80c0db8344b659557f (diff) | |
Ensure that all actions are compared to fixed point in time (ie. world update start) (#18910)
- Actions will not be dependent on processing moment
- Increased GameObjects cooldown resolution to milliseconds, fixes arming time of traps to be exactly one second and not something from range (1000, 1999)
- Created GameTime namespace and UpdateTime class and moved there some code out of world
(cherrypicked from 7567cafec84080d26ea513242a1f540a823b8f9d)
Diffstat (limited to 'src/server/scripts/Events')
| -rw-r--r-- | src/server/scripts/Events/fireworks_show.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/server/scripts/Events/fireworks_show.cpp b/src/server/scripts/Events/fireworks_show.cpp index 4712090b032..a052063bf26 100644 --- a/src/server/scripts/Events/fireworks_show.cpp +++ b/src/server/scripts/Events/fireworks_show.cpp @@ -20,6 +20,7 @@ #include "EventMap.h" #include "GameObject.h" #include "GameObjectAI.h" +#include "GameTime.h" #include "CreatureAIImpl.h" #include "GameEventMgr.h" #include "World.h" @@ -796,7 +797,7 @@ public: { _events.Update(diff); - time_t time = sWorld->GetGameTime(); + time_t time = GameTime::GetGameTime(); tm localTm; localtime_r(&time, &localTm); |
