fix(Scripts/Temple of AhnQiraj): Adjusted Sartura's event timers. (#13187)

This commit is contained in:
UltraNix
2022-10-06 03:36:08 +02:00
committed by GitHub
parent 5235373363
commit 29ea8a2e59
2 changed files with 11 additions and 13 deletions

View File

@@ -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.

View File

@@ -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;
}
}