fix(Script/Skadi): Emotes (#11625)
* Added Grauf deep breath emote * Renamed flame visual to properly reflect spell name Freezing Cloud * Removed defined text, now uses creature_text for emotes Co-authored-by: ChrisCGalbraith <chriscgalbraith@gmai.com>
This commit is contained in:
committed by
GitHub
parent
aeb260c3cc
commit
ac8a6b4328
@@ -28,11 +28,14 @@ enum Misc
|
|||||||
// TEXTS
|
// TEXTS
|
||||||
SAY_AGGRO = 0,
|
SAY_AGGRO = 0,
|
||||||
SAY_KILL = 1,
|
SAY_KILL = 1,
|
||||||
EMOTE_RANGE = 2,
|
|
||||||
SAY_DEATH = 3,
|
SAY_DEATH = 3,
|
||||||
SAY_DRAKE_DEATH = 5,
|
SAY_DRAKE_DEATH = 5,
|
||||||
SAY_DRAKE_BREATH = 6,
|
SAY_DRAKE_BREATH = 6,
|
||||||
|
|
||||||
|
// EMOTES
|
||||||
|
EMOTE_DEEP_BREATH = 0,
|
||||||
|
EMOTE_RANGE = 1,
|
||||||
|
|
||||||
// SPELLS
|
// SPELLS
|
||||||
SPELL_CRUSH_N = 50234,
|
SPELL_CRUSH_N = 50234,
|
||||||
SPELL_CRUSH_H = 59330,
|
SPELL_CRUSH_H = 59330,
|
||||||
@@ -41,9 +44,9 @@ enum Misc
|
|||||||
SPELL_WHIRLWIND_N = 50228,
|
SPELL_WHIRLWIND_N = 50228,
|
||||||
SPELL_WHIRLWIND_H = 50228,
|
SPELL_WHIRLWIND_H = 50228,
|
||||||
|
|
||||||
SPELL_FLAME_VISUAL = 47592,
|
SPELL_FREEZING_CLOUD_VISUAL = 47592,
|
||||||
SPELL_FLAME_BREATH_N = 47579,
|
SPELL_FREEZING_CLOUD_N = 47579,
|
||||||
SPELL_FLAME_BREATH_H = 60020,
|
SPELL_FREEZING_CLOUD_H = 60020,
|
||||||
|
|
||||||
SPELL_LAUNCH_HARPOON = 48642,
|
SPELL_LAUNCH_HARPOON = 48642,
|
||||||
|
|
||||||
@@ -95,8 +98,6 @@ static Position SkadiPosition[] =
|
|||||||
{490.76f, -517.389f, 123.368f, 0.0f}
|
{490.76f, -517.389f, 123.368f, 0.0f}
|
||||||
};
|
};
|
||||||
|
|
||||||
#define EMOTE_IN_RANGE "Skadi the Ruthless is within range of the harpoon launchers"
|
|
||||||
|
|
||||||
enum phase
|
enum phase
|
||||||
{
|
{
|
||||||
PHASE_NONE,
|
PHASE_NONE,
|
||||||
@@ -323,8 +324,8 @@ public:
|
|||||||
|
|
||||||
void SpellHitTarget(Unit* target, SpellInfo const* spellInfo) override
|
void SpellHitTarget(Unit* target, SpellInfo const* spellInfo) override
|
||||||
{
|
{
|
||||||
if (spellInfo->Id == 47593) // SPELL_FLAME_VISUAL trigger
|
if (spellInfo->Id == 47593) // SPELL_FREEZING_CLOUD_VISUAL trigger
|
||||||
target->CastSpell(target, me->GetMap()->IsHeroic() ? SPELL_FLAME_BREATH_H : SPELL_FLAME_BREATH_N, true);
|
target->CastSpell(target, me->GetMap()->IsHeroic() ? SPELL_FREEZING_CLOUD_H : SPELL_FREEZING_CLOUD_N, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
void SpawnFlameTriggers(uint8 point)
|
void SpawnFlameTriggers(uint8 point)
|
||||||
@@ -341,13 +342,13 @@ public:
|
|||||||
{
|
{
|
||||||
Creature* cr;
|
Creature* cr;
|
||||||
if ((cr = me->SummonCreature(NPC_BREATH_TRIGGER, 483, -484.9f, 105, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 30000)))
|
if ((cr = me->SummonCreature(NPC_BREATH_TRIGGER, 483, -484.9f, 105, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 30000)))
|
||||||
cr->CastSpell(cr, cr->GetMap()->IsHeroic() ? SPELL_FLAME_BREATH_H : SPELL_FLAME_BREATH_N, true);
|
cr->CastSpell(cr, cr->GetMap()->IsHeroic() ? SPELL_FREEZING_CLOUD_H : SPELL_FREEZING_CLOUD_N, true);
|
||||||
if ((cr = me->SummonCreature(NPC_BREATH_TRIGGER, 471.0f, -484.7f, 105, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 30000)))
|
if ((cr = me->SummonCreature(NPC_BREATH_TRIGGER, 471.0f, -484.7f, 105, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 30000)))
|
||||||
cr->CastSpell(cr, cr->GetMap()->IsHeroic() ? SPELL_FLAME_BREATH_H : SPELL_FLAME_BREATH_N, true);
|
cr->CastSpell(cr, cr->GetMap()->IsHeroic() ? SPELL_FREEZING_CLOUD_H : SPELL_FREEZING_CLOUD_N, true);
|
||||||
|
|
||||||
for (uint8 j = 0; j < 7; j++)
|
for (uint8 j = 0; j < 7; j++)
|
||||||
if ((cr = me->SummonCreature(NPC_BREATH_TRIGGER, 477.0f, -507.0f + (j * 3), 105.0f, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 30000)))
|
if ((cr = me->SummonCreature(NPC_BREATH_TRIGGER, 477.0f, -507.0f + (j * 3), 105.0f, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 30000)))
|
||||||
cr->CastSpell(cr, cr->GetMap()->IsHeroic() ? SPELL_FLAME_BREATH_H : SPELL_FLAME_BREATH_N, true);
|
cr->CastSpell(cr, cr->GetMap()->IsHeroic() ? SPELL_FREEZING_CLOUD_H : SPELL_FREEZING_CLOUD_N, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -357,15 +358,14 @@ public:
|
|||||||
{
|
{
|
||||||
case 0:
|
case 0:
|
||||||
case 1:
|
case 1:
|
||||||
me->RemoveAurasDueToSpell(SPELL_FLAME_VISUAL);
|
me->RemoveAurasDueToSpell(SPELL_FREEZING_CLOUD_VISUAL);
|
||||||
me->SetFacingTo(M_PI * 2);
|
me->SetFacingTo(M_PI * 2);
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
case 3:
|
case 3:
|
||||||
if (m_pInstance)
|
if (m_pInstance)
|
||||||
m_pInstance->SetData(SKADI_IN_RANGE, 1);
|
m_pInstance->SetData(SKADI_IN_RANGE, 1);
|
||||||
|
Talk(EMOTE_RANGE);
|
||||||
me->TextEmote(EMOTE_IN_RANGE, nullptr, true);
|
|
||||||
me->SetFacingTo(M_PI);
|
me->SetFacingTo(M_PI);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -466,8 +466,9 @@ public:
|
|||||||
me->GetMotionMaster()->MovePoint(targetPoint, SkadiPosition[targetPoint].GetPositionX(), SkadiPosition[targetPoint].GetPositionY(), SkadiPosition[targetPoint].GetPositionZ());
|
me->GetMotionMaster()->MovePoint(targetPoint, SkadiPosition[targetPoint].GetPositionX(), SkadiPosition[targetPoint].GetPositionY(), SkadiPosition[targetPoint].GetPositionZ());
|
||||||
if (targetPoint <= 1)
|
if (targetPoint <= 1)
|
||||||
{
|
{
|
||||||
|
Talk(EMOTE_DEEP_BREATH);
|
||||||
SpawnFlameTriggers(targetPoint);
|
SpawnFlameTriggers(targetPoint);
|
||||||
me->CastSpell(me, SPELL_FLAME_VISUAL, false);
|
me->CastSpell(me, SPELL_FREEZING_CLOUD_VISUAL, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (m_pInstance)
|
if (m_pInstance)
|
||||||
|
|||||||
Reference in New Issue
Block a user