diff options
| author | Wyrserth <wyrserth@protonmail.com> | 2019-06-05 17:05:10 +0200 |
|---|---|---|
| committer | ccrs <ccrs@users.noreply.github.com> | 2019-06-05 21:49:52 +0200 |
| commit | 1cb01700b11641634e556d5d4e519476446943d3 (patch) | |
| tree | a900541a5251ccaebe5130d41ffb46003eff14c3 /src/server/scripts | |
| parent | 7b2defe5a0e645ab88e48df2d8e5417e4977d41c (diff) | |
Script/ZulGurub: allow Hakkar to cast Mind Control only if more than one unit is currently fighting him.
Also fix target type - it should always target the current tank.
Diffstat (limited to 'src/server/scripts')
| -rw-r--r-- | src/server/scripts/EasternKingdoms/ZulGurub/boss_hakkar.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_hakkar.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_hakkar.cpp index 0ca52584c76..e3015b4db35 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_hakkar.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_hakkar.cpp @@ -127,9 +127,16 @@ class boss_hakkar : public CreatureScript // events.ScheduleEvent(EVENT_CAUSE_INSANITY, 35s, 45s); break; case EVENT_WILL_OF_HAKKAR: - DoCast(SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true), SPELL_WILL_OF_HAKKAR); + { + // Mind Control is only triggered when there is more than one unit currently fighting Hakkar, including pets/guardians + // But it is only actually cast on the player with the highest threat + std::list<Unit*> unitList; + SelectTargetList(unitList, 2, SELECT_TARGET_MAXTHREAT, 0, 0.0f, false); + if (unitList.size() > 1) + DoCast(SelectTarget(SELECT_TARGET_MAXTHREAT, 0, 100, true), SPELL_WILL_OF_HAKKAR); events.ScheduleEvent(EVENT_WILL_OF_HAKKAR, 25s, 35s); break; + } case EVENT_ENRAGE: if (!me->HasAura(SPELL_ENRAGE)) DoCast(me, SPELL_ENRAGE); |
