From e5382ee21538e4383a39b4dc0de274e856bb663b Mon Sep 17 00:00:00 2001 From: treeston Date: Tue, 7 Jun 2016 14:17:11 +0200 Subject: Scripts/Instances: Fix a bug that would cause the Hodir encounter to never properly begin. Tagging issue #17302. --- src/server/scripts/Northrend/Ulduar/Ulduar/boss_hodir.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/server/scripts/Northrend') diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_hodir.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_hodir.cpp index 86068a1ecba..c03a1c6fbc1 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_hodir.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_hodir.cpp @@ -30,6 +30,8 @@ Destroying of Toasty Fires */ +/* @todo Hodir aggro behavior is wonky. He gets set to _PASSIVE, but never to _AGGRESSIVE unless you kill an ice block which doesn't spawn unless you have*/ + enum HodirYells { SAY_AGGRO = 0, @@ -375,7 +377,7 @@ class boss_hodir : public CreatureScript Talk(SAY_SLAY); } - void DamageTaken(Unit* /*who*/, uint32& damage) override + void DamageTaken(Unit* who, uint32& damage) override { if (damage >= me->GetHealth()) { @@ -403,6 +405,12 @@ class boss_hodir : public CreatureScript _JustDied(); } + else if (!me->IsInCombat()) + { + me->SetReactState(REACT_AGGRESSIVE); + me->AI()->DoZoneInCombat(); + me->AI()->AttackStart(who); + } } void UpdateAI(uint32 diff) override -- cgit v1.2.3