Skip to content

Commit

Permalink
Icecrown: Spell 58203 Scripted Pt.2
Browse files Browse the repository at this point in the history
effect added
  • Loading branch information
Grz3s committed Dec 8, 2024
1 parent f5564a8 commit 50f7b21
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/game/AI/ScriptDevAI/scripts/northrend/icecrown.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1318,7 +1318,7 @@ struct ControlEidolonWatcher : public SpellScript
};

// 58203 - Iron Chain
struct IronChain : public SpellScript
struct IronChain : public SpellScript, public AuraScript
{
SpellCastResult OnCheckCast(Spell* spell, bool /*strict*/) const override
{
Expand All @@ -1328,6 +1328,16 @@ struct IronChain : public SpellScript

return SPELL_CAST_OK;
}
void OnApply(Aura* aura, bool apply) const override
{
Unit* caster = aura->GetCaster();
if (!caster || !aura->GetTarget()->IsCreature())
return;
if (!apply)
return;

aura->GetTarget()->GetMotionMaster()->MoveFollow(aura->GetCaster(), 2.0f, M_PI_F, true);
}
};

void AddSC_icecrown()
Expand Down

0 comments on commit 50f7b21

Please sign in to comment.