diff options
| author | Treeston <treeston.mmoc@gmail.com> | 2020-07-14 01:35:25 +0200 |
|---|---|---|
| committer | Peter Keresztes Schmidt <carbenium@outlook.com> | 2020-07-17 17:05:55 +0200 |
| commit | 896b68d5c297b06587645caebc98b704978ecaa7 (patch) | |
| tree | 14952aaccd9419ce4e67831e12c81b988fc280f5 /src/server/scripts/Northrend | |
| parent | 235cdc2fd5c72e8dd8a91fb53a1b90babef24047 (diff) | |
Core/Time: Rename GetGameTime{System, Steady}Point methods
The names are a bit unhandy. Rename them (shorter but still meaningful).
GetGameTimeSystemPoint() -> GetSystemTime()
GetGameTimeSteadyPoint() -> Now()
Also add 2 new typedefs:
typedef std::chrono::steady_clock::time_point TimePoint;
typedef std::chrono::system_clock::time_point SystemTimePoint;
Closes #25042
Diffstat (limited to 'src/server/scripts/Northrend')
| -rw-r--r-- | src/server/scripts/Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp index 044c99ebfd2..39a41dd1b10 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp @@ -854,7 +854,7 @@ class npc_high_overlord_saurfang_igb : public CreatureScript _controller.SetTransport(creature->GetTransport()); me->SetRegenerateHealth(false); me->m_CombatDistance = 70.0f; - _firstMageCooldown = GameTime::GetGameTimeSteadyPoint() + 60s; + _firstMageCooldown = GameTime::Now() + 60s; _axethrowersYellCooldown = time_t(0); _rocketeersYellCooldown = time_t(0); } @@ -864,7 +864,7 @@ class npc_high_overlord_saurfang_igb : public CreatureScript ScriptedAI::InitializeAI(); _events.Reset(); - _firstMageCooldown = GameTime::GetGameTimeSteadyPoint() + 60s; + _firstMageCooldown = GameTime::Now() + 60s; _axethrowersYellCooldown = time_t(0); _rocketeersYellCooldown = time_t(0); } @@ -916,7 +916,7 @@ class npc_high_overlord_saurfang_igb : public CreatureScript } else if (action == ACTION_SPAWN_MAGE) { - std::chrono::steady_clock::time_point now = GameTime::GetGameTimeSteadyPoint(); + TimePoint now = GameTime::Now(); if (_firstMageCooldown > now) _events.ScheduleEvent(EVENT_SUMMON_MAGE, std::chrono::duration_cast<Milliseconds>(_firstMageCooldown - now)); else @@ -1093,7 +1093,7 @@ class npc_high_overlord_saurfang_igb : public CreatureScript EventMap _events; PassengerController _controller; InstanceScript* _instance; - std::chrono::steady_clock::time_point _firstMageCooldown; + TimePoint _firstMageCooldown; time_t _axethrowersYellCooldown; time_t _rocketeersYellCooldown; }; @@ -1118,7 +1118,7 @@ class npc_muradin_bronzebeard_igb : public CreatureScript _controller.SetTransport(creature->GetTransport()); me->SetRegenerateHealth(false); me->m_CombatDistance = 70.0f; - _firstMageCooldown = GameTime::GetGameTimeSteadyPoint() + 60s; + _firstMageCooldown = GameTime::Now() + 60s; _riflemanYellCooldown = time_t(0); _mortarYellCooldown = time_t(0); } @@ -1128,7 +1128,7 @@ class npc_muradin_bronzebeard_igb : public CreatureScript ScriptedAI::InitializeAI(); _events.Reset(); - _firstMageCooldown = GameTime::GetGameTimeSteadyPoint() + 60s; + _firstMageCooldown = GameTime::Now() + 60s; _riflemanYellCooldown = time_t(0); _mortarYellCooldown = time_t(0); } @@ -1180,7 +1180,7 @@ class npc_muradin_bronzebeard_igb : public CreatureScript } else if (action == ACTION_SPAWN_MAGE) { - std::chrono::steady_clock::time_point now = GameTime::GetGameTimeSteadyPoint(); + TimePoint now = GameTime::Now(); if (_firstMageCooldown > now) _events.ScheduleEvent(EVENT_SUMMON_MAGE, std::chrono::duration_cast<Milliseconds>(_firstMageCooldown - now)); else @@ -1361,7 +1361,7 @@ class npc_muradin_bronzebeard_igb : public CreatureScript EventMap _events; PassengerController _controller; InstanceScript* _instance; - std::chrono::steady_clock::time_point _firstMageCooldown; + TimePoint _firstMageCooldown; time_t _riflemanYellCooldown; time_t _mortarYellCooldown; }; |
