Merge branch 'master' into Playerbot
This commit is contained in:
@@ -50,6 +50,7 @@ enum Spells
|
||||
SPELL_ENRAGE = 46587,
|
||||
SPELL_EMPOWER = 45366,
|
||||
SPELL_DARK_FLAME = 45345,
|
||||
SPELL_FIREBLAST = 45232,
|
||||
|
||||
//Lady Sacrolash spells
|
||||
SPELL_SHADOWFORM = 45455,
|
||||
@@ -78,6 +79,21 @@ struct boss_sacrolash : public BossAI
|
||||
{
|
||||
boss_sacrolash(Creature* creature) : BossAI(creature, DATA_EREDAR_TWINS), _isSisterDead(false) {}
|
||||
|
||||
bool CheckInRoom() override
|
||||
{
|
||||
if (me->GetExactDist2d(me->GetHomePosition()) >= 50.f)
|
||||
{
|
||||
DoCastAOE(SPELL_FIREBLAST, true);
|
||||
|
||||
if (Creature* alythess = instance->GetCreature(DATA_ALYTHESS))
|
||||
alythess->AI()->DoCastAOE(SPELL_FIREBLAST, true);
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void Reset() override
|
||||
{
|
||||
DoCastSelf(SPELL_SHADOWFORM, true);
|
||||
@@ -104,7 +120,11 @@ struct boss_sacrolash : public BossAI
|
||||
Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f);
|
||||
if (!target)
|
||||
target = me->GetVictim();
|
||||
me->CastSpell(target, SPELL_CONFLAGRATION, false);
|
||||
|
||||
DoCast(target, SPELL_CONFLAGRATION);
|
||||
|
||||
if (Creature* alythess = instance->GetCreature(DATA_ALYTHESS))
|
||||
alythess->AI()->Talk(EMOTE_CONFLAGRATION, target);
|
||||
}, 30s, 35s);
|
||||
}
|
||||
}
|
||||
@@ -190,6 +210,13 @@ struct boss_alythess : public BossAI
|
||||
sacrolash->Respawn(true);
|
||||
}
|
||||
|
||||
void AttackStart(Unit* who) override
|
||||
{
|
||||
if (who && who->isTargetableForAttack() && me->GetReactState() != REACT_PASSIVE)
|
||||
if (me->Attack(who, false))
|
||||
me->AddThreat(who, 0.0f);
|
||||
}
|
||||
|
||||
void DoAction(int32 param) override
|
||||
{
|
||||
if (param == ACTION_SISTER_DIED)
|
||||
@@ -200,12 +227,16 @@ struct boss_alythess : public BossAI
|
||||
me->CastSpell(me, SPELL_EMPOWER, true);
|
||||
|
||||
scheduler.CancelGroup(GROUP_SPECIAL_ABILITY);
|
||||
ScheduleTimedEvent(20s, [&] {
|
||||
ScheduleTimedEvent(20s, 26s, [&] {
|
||||
Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f);
|
||||
if (!target)
|
||||
target = me->GetVictim();
|
||||
DoCast(target, SPELL_SHADOW_NOVA);
|
||||
}, 30s, 35s);
|
||||
|
||||
if (Creature * sacrolash = instance->GetCreature(DATA_SACROLASH))
|
||||
sacrolash->AI()->Talk(EMOTE_SHADOW_NOVA, target);
|
||||
|
||||
}, 20s, 26s);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -226,9 +257,9 @@ struct boss_alythess : public BossAI
|
||||
DoCastSelf(SPELL_PYROGENICS);
|
||||
}, 15s);
|
||||
|
||||
ScheduleTimedEvent(20s, [&] {
|
||||
me->CastCustomSpell(SPELL_FLAME_SEAR, SPELLVALUE_MAX_TARGETS, 5, me, TRIGGERED_NONE);
|
||||
}, 15s);
|
||||
ScheduleTimedEvent(10s, 15s, [&] {
|
||||
me->CastCustomSpell(SPELL_FLAME_SEAR, SPELLVALUE_MAX_TARGETS, urand(4, 5), me, TRIGGERED_NONE);
|
||||
}, 10s, 15s);
|
||||
|
||||
scheduler.Schedule(20s, GROUP_SPECIAL_ABILITY, [this](TaskContext context) {
|
||||
Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f);
|
||||
|
||||
@@ -49,6 +49,12 @@ enum Spells
|
||||
SPELL_ENCAPSULATE_CHANNEL = 45661,
|
||||
|
||||
//Flight phase
|
||||
SPELL_TRIGGER_TOP_STRAFE = 45586,
|
||||
SPELL_TRIGGER_MIDDLE_STRAFE = 45622,
|
||||
SPELL_TRIGGER_BOTTOM_STRAFE = 45623,
|
||||
SPELL_STRAFE_TOP = 45585,
|
||||
SPELL_STRAFE_MIDDLE = 45633,
|
||||
SPELL_STRAFE_BOTTOM = 45635,
|
||||
SPELL_SUMMON_DEMONIC_VAPOR = 45391,
|
||||
SPELL_DEMONIC_VAPOR_SPAWN_TRIGGER = 45388, // Triggers visual beam
|
||||
SPELL_DEMONIC_VAPOR_PERIODIC = 45411, // Spawns cloud and deals damage
|
||||
@@ -110,18 +116,17 @@ public:
|
||||
|
||||
bool Execute(uint64 /*execTime*/, uint32 /*diff*/) override
|
||||
{
|
||||
std::list<Creature*> creatureList;
|
||||
_caster->GetCreaturesWithEntryInRange(creatureList, 70.0f, NPC_FOG_TRIGGER);
|
||||
for (auto const& creature : creatureList)
|
||||
switch (_currentLane)
|
||||
{
|
||||
if (_caster->GetExactDist2d(creature) <= 11.0f)
|
||||
{
|
||||
creature->CastSpell(creature, SPELL_FOG_OF_CORRUPTION, true);
|
||||
continue;
|
||||
}
|
||||
|
||||
if (!_currentLane && creature->GetPositionX() > 1510.0f)
|
||||
creature->CastSpell(creature, SPELL_FOG_OF_CORRUPTION, true);
|
||||
case 0: // top
|
||||
_caster->CastSpell(_caster, SPELL_STRAFE_TOP, true);
|
||||
break;
|
||||
case 1: // middle
|
||||
_caster->CastSpell(_caster, SPELL_STRAFE_MIDDLE, true);
|
||||
break;
|
||||
case 2: // bottom
|
||||
_caster->CastSpell(_caster, SPELL_STRAFE_BOTTOM, true);
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
@@ -183,6 +188,12 @@ struct boss_felmyst : public BossAI
|
||||
Talk(YELL_KILL);
|
||||
}
|
||||
|
||||
void SpellHitTarget(Unit* target, const SpellInfo* spell) override
|
||||
{
|
||||
if (spell->Id == SPELL_STRAFE_TOP || spell->Id == SPELL_STRAFE_MIDDLE || spell->Id == SPELL_STRAFE_BOTTOM)
|
||||
target->CastSpell(target, SPELL_FOG_OF_CORRUPTION, true);
|
||||
}
|
||||
|
||||
void JustDied(Unit* killer) override
|
||||
{
|
||||
BossAI::JustDied(killer);
|
||||
@@ -297,15 +308,8 @@ struct boss_felmyst : public BossAI
|
||||
case POINT_LANE:
|
||||
Talk(EMOTE_BREATH);
|
||||
me->m_Events.AddEventAtOffset([&] {
|
||||
me->m_Events.AddEvent(new CorruptTriggers(me, _currentLane), me->m_Events.CalculateTime(0));
|
||||
me->m_Events.AddEvent(new CorruptTriggers(me, _currentLane), me->m_Events.CalculateTime(500));
|
||||
me->m_Events.AddEvent(new CorruptTriggers(me, _currentLane), me->m_Events.CalculateTime(1000));
|
||||
me->m_Events.AddEvent(new CorruptTriggers(me, _currentLane), me->m_Events.CalculateTime(1500));
|
||||
me->m_Events.AddEvent(new CorruptTriggers(me, _currentLane), me->m_Events.CalculateTime(2000));
|
||||
me->m_Events.AddEvent(new CorruptTriggers(me, _currentLane), me->m_Events.CalculateTime(2500));
|
||||
me->m_Events.AddEvent(new CorruptTriggers(me, _currentLane), me->m_Events.CalculateTime(3000));
|
||||
me->m_Events.AddEvent(new CorruptTriggers(me, _currentLane), me->m_Events.CalculateTime(3500));
|
||||
me->m_Events.AddEvent(new CorruptTriggers(me, _currentLane), me->m_Events.CalculateTime(4000));
|
||||
for (uint8 i = 0; i < 16; ++i)
|
||||
me->m_Events.AddEvent(new CorruptTriggers(me, _currentLane), me->m_Events.CalculateTime(i*250));
|
||||
}, 5s);
|
||||
|
||||
me->m_Events.AddEventAtOffset([&] {
|
||||
|
||||
@@ -450,6 +450,7 @@ struct boss_kiljaeden : public BossAI
|
||||
if (me->GetReactState() == REACT_PASSIVE)
|
||||
return;
|
||||
ScriptedAI::EnterEvadeMode(why);
|
||||
me->DespawnOrUnsummon();
|
||||
}
|
||||
|
||||
void AttackStart(Unit* who) override
|
||||
|
||||
@@ -293,7 +293,7 @@ class spell_entropius_void_zone_visual_aura : public AuraScript
|
||||
void Register() override
|
||||
{
|
||||
OnEffectApply += AuraEffectApplyFn(spell_entropius_void_zone_visual_aura::HandleApply, EFFECT_0, SPELL_AURA_DUMMY, AURA_EFFECT_HANDLE_REAL);
|
||||
OnEffectRemove += AuraEffectRemoveFn(spell_entropius_void_zone_visual_aura::HandleApply, EFFECT_0, SPELL_AURA_DUMMY, AURA_EFFECT_HANDLE_REAL);
|
||||
OnEffectRemove += AuraEffectRemoveFn(spell_entropius_void_zone_visual_aura::HandleRemove, EFFECT_0, SPELL_AURA_DUMMY, AURA_EFFECT_HANDLE_REAL);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -319,7 +319,7 @@ class spell_dk_death_and_decay : public SpellScript
|
||||
|
||||
// Xinef: include AOE damage reducing auras
|
||||
if (target)
|
||||
damage = target->CalculateAOEDamageReduction(damage, GetSpellInfo()->SchoolMask, caster);
|
||||
damage = target->CalculateAOEDamageReduction(damage, GetSpellInfo()->SchoolMask, false);
|
||||
|
||||
SetHitDamage(damage);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user