diff --git a/src/common/Utilities/EventMap.h b/src/common/Utilities/EventMap.h index 1ed115e42..1d3df6222 100644 --- a/src/common/Utilities/EventMap.h +++ b/src/common/Utilities/EventMap.h @@ -182,12 +182,9 @@ public: void RescheduleEvent(uint32 eventId, Milliseconds minTime, Milliseconds maxTime, uint32 group = 0, uint32 phase = 0); /** - * @name RescheduleEvent - * @brief Cancels the given event and reschedules it. - * @param eventId The id of the event. - * @param time The time in milliseconds until the event occurs. - * @param group The group which the event is associated to. Has to be between 1 and 8. 0 means it has no group. - * @param phase The phase in which the event can occur. Has to be between 1 and 8. 0 means it can occur in all phases. + * @name RepeatEvent + * @brief Repeats the most recently executed event. + * @param time Time until the event occurs as std::chrono type. */ void RepeatEvent(uint32 time); @@ -199,6 +196,7 @@ public: void Repeat(Milliseconds time); /** + * @name RepeatEvent * @brief Repeats the most recently executed event. * @param minTime The minimum time until the event occurs as std::chrono type. diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_sartura.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_sartura.cpp index 2cb8072a8..46de14dcc 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_sartura.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_sartura.cpp @@ -97,7 +97,7 @@ struct boss_sartura : public BossAI { BossAI::EnterCombat(who); Talk(SAY_AGGRO); - events.ScheduleEvent(EVENT_SARTURA_WHIRLWIND, 30000); + events.ScheduleEvent(EVENT_SARTURA_WHIRLWIND, 12s, 22s); events.ScheduleEvent(EVENT_SARTURA_AGGRO_RESET, urand(45000, 55000)); events.ScheduleEvent(EVENT_SPELL_BERSERK, 10 * 60000); events.ScheduleEvent(EVENT_SARTURA_SUNDERING_CLEAVE, 2400ms, 3s); @@ -155,7 +155,7 @@ struct boss_sartura : public BossAI case EVENT_SARTURA_WHIRLWIND_END: events.CancelEvent(EVENT_SARTURA_WHIRLWIND_RANDOM); whirlwind = false; - events.ScheduleEvent(EVENT_SARTURA_WHIRLWIND, urand(25000, 40000)); + events.ScheduleEvent(EVENT_SARTURA_WHIRLWIND, 5s, 11s); break; case EVENT_SARTURA_AGGRO_RESET: if (aggroReset == false) @@ -239,9 +239,9 @@ struct npc_sartura_royal_guard : public ScriptedAI void EnterCombat(Unit* /*who*/) override { - events.ScheduleEvent(EVENT_GUARD_WHIRLWIND, 30000); + events.ScheduleEvent(EVENT_GUARD_WHIRLWIND, 6s, 10s); events.ScheduleEvent(EVENT_GUARD_AGGRO_RESET, urand(45000, 55000)); - events.ScheduleEvent(EVENT_GUARD_KNOCKBACK, 10000); + events.ScheduleEvent(EVENT_GUARD_KNOCKBACK, 12s, 16s); } void UpdateAI(uint32 diff) override @@ -259,7 +259,7 @@ struct npc_sartura_royal_guard : public ScriptedAI DoCastSelf(SPELL_GUARD_WHIRLWIND); whirlwind = true; events.ScheduleEvent(EVENT_GUARD_WHIRLWIND_RANDOM, urand(3000, 7000)); - events.ScheduleEvent(EVENT_GUARD_WHIRLWIND_END, 15000); + events.ScheduleEvent(EVENT_GUARD_WHIRLWIND_END, 8s); break; case EVENT_GUARD_WHIRLWIND_RANDOM: if (whirlwind == true) @@ -276,7 +276,7 @@ struct npc_sartura_royal_guard : public ScriptedAI case EVENT_GUARD_WHIRLWIND_END: events.CancelEvent(EVENT_GUARD_WHIRLWIND_RANDOM); whirlwind = false; - events.ScheduleEvent(EVENT_GUARD_WHIRLWIND, urand(25000, 40000)); + events.ScheduleEvent(EVENT_GUARD_WHIRLWIND, 500ms, 9s); break; case EVENT_GUARD_AGGRO_RESET: if (aggroReset == true) @@ -313,7 +313,7 @@ struct npc_sartura_royal_guard : public ScriptedAI break; case EVENT_GUARD_KNOCKBACK: DoCastVictim(SPELL_GUARD_KNOCKBACK); - events.RepeatEvent(urand(10000, 20000)); + events.Repeat(21s, 37s); break; } }