fix(Scripts/DTK): Update Tharon'ja timers (#23765)

This commit is contained in:
Andrew
2025-11-18 19:11:26 -03:00
committed by GitHub
parent fdbc8afeda
commit 539581aa7a

View File

@@ -59,7 +59,6 @@ enum Misc
EVENT_SPELL_EYE_BEAM = 4, EVENT_SPELL_EYE_BEAM = 4,
EVENT_SPELL_LIGHTNING_BREATH = 5, EVENT_SPELL_LIGHTNING_BREATH = 5,
EVENT_SPELL_POISON_CLOUD = 6, EVENT_SPELL_POISON_CLOUD = 6,
EVENT_SPELL_TURN_FLESH = 7,
EVENT_TURN_FLESH_REAL = 9, EVENT_TURN_FLESH_REAL = 9,
EVENT_TURN_BONES_REAL = 10, EVENT_TURN_BONES_REAL = 10,
EVENT_KILL_TALK = 11 EVENT_KILL_TALK = 11
@@ -77,9 +76,7 @@ public:
struct boss_tharon_jaAI : public BossAI struct boss_tharon_jaAI : public BossAI
{ {
boss_tharon_jaAI(Creature* creature) : BossAI(creature, DATA_THARON_JA) boss_tharon_jaAI(Creature* creature) : BossAI(creature, DATA_THARON_JA) { }
{
}
void Reset() override void Reset() override
{ {
@@ -88,15 +85,23 @@ public:
me->ApplySpellImmune(0, IMMUNITY_EFFECT, SPELL_EFFECT_KNOCK_BACK_DEST, true); me->ApplySpellImmune(0, IMMUNITY_EFFECT, SPELL_EFFECT_KNOCK_BACK_DEST, true);
me->SetDisplayId(me->GetNativeDisplayId()); me->SetDisplayId(me->GetNativeDisplayId());
me->CastSpell(me, SPELL_CLEAR_GIFT, true); me->CastSpell(me, SPELL_CLEAR_GIFT, true);
ScheduleHealthCheckEvent(55, [&] {
Talk(SAY_FLESH);
me->GetThreatMgr().ResetAllThreat();
me->CastSpell((Unit*)nullptr, SPELL_TURN_FLESH, false);
events.Reset();
events.ScheduleEvent(EVENT_TURN_FLESH_REAL, 3s);
}, false);
} }
void JustEngagedWith(Unit* who) override void JustEngagedWith(Unit* who) override
{ {
Talk(SAY_AGGRO); Talk(SAY_AGGRO);
BossAI::JustEngagedWith(who); BossAI::JustEngagedWith(who);
events.ScheduleEvent(EVENT_SPELL_CURSE_OF_LIFE, 5s); events.ScheduleEvent(EVENT_SPELL_CURSE_OF_LIFE, 13s, 24s);
events.ScheduleEvent(EVENT_SPELL_SHADOW_VOLLEY, 8s, 10s); events.ScheduleEvent(EVENT_SPELL_SHADOW_VOLLEY, 6s, 29s);
events.ScheduleEvent(EVENT_SPELL_TURN_FLESH, 1s);
} }
void KilledUnit(Unit* /*victim*/) override void KilledUnit(Unit* /*victim*/) override
@@ -144,24 +149,11 @@ public:
{ {
case EVENT_SPELL_CURSE_OF_LIFE: case EVENT_SPELL_CURSE_OF_LIFE:
DoCastRandomTarget(SPELL_CURSE_OF_LIFE, 0, 30.0f, false); DoCastRandomTarget(SPELL_CURSE_OF_LIFE, 0, 30.0f, false);
events.ScheduleEvent(EVENT_SPELL_CURSE_OF_LIFE, 13s); events.ScheduleEvent(EVENT_SPELL_CURSE_OF_LIFE, 11s, 28s);
break; break;
case EVENT_SPELL_SHADOW_VOLLEY: case EVENT_SPELL_SHADOW_VOLLEY:
DoCastAOE(SPELL_SHADOW_VOLLEY); DoCastAOE(SPELL_SHADOW_VOLLEY);
events.ScheduleEvent(EVENT_SPELL_SHADOW_VOLLEY, 9s); events.ScheduleEvent(EVENT_SPELL_SHADOW_VOLLEY, 6s, 29s);
break;
case EVENT_SPELL_TURN_FLESH:
if (me->HealthBelowPct(50))
{
Talk(SAY_FLESH);
me->GetThreatMgr().ResetAllThreat();
me->CastSpell((Unit*)nullptr, SPELL_TURN_FLESH, false);
events.Reset();
events.ScheduleEvent(EVENT_TURN_FLESH_REAL, 3s);
return;
}
events.ScheduleEvent(EVENT_SPELL_TURN_FLESH, 1s);
break; break;
case EVENT_TURN_FLESH_REAL: case EVENT_TURN_FLESH_REAL:
DoCastSelf(SPELL_DUMMY, true); DoCastSelf(SPELL_DUMMY, true);