aboutsummaryrefslogtreecommitdiff
path: root/src/server/scripts/EasternKingdoms/ScarletMonastery
diff options
context:
space:
mode:
authortreeston <treeston.mmoc@gmail.com>2016-09-03 17:21:22 +0200
committerjoschiwald <joschiwald.trinity@gmail.com>2017-02-19 15:09:02 +0100
commitdd0df772df4603b95dc133dc9b896e5fc8e3bdf8 (patch)
tree4be78ca038ae1337985b264c2d8ff37728492c49 /src/server/scripts/EasternKingdoms/ScarletMonastery
parent5654fb93431a3b3866b0d5e585099e289383bad1 (diff)
Scripts/Events: Globally fix all ExecuteEvent loops to check UNIT_STATE_CASTING after each iteration, instead of just checking it once initially.
Fixes and closes #17892. (cherry picked from commit ac62d7156f93bf86f57dbad1f24f14031322fd5a) Drycoding is bad, mmkay? (cherry picked from commit ed83a35fbeeb7f9005fe4792225fb50700791c6f)
Diffstat (limited to 'src/server/scripts/EasternKingdoms/ScarletMonastery')
-rw-r--r--src/server/scripts/EasternKingdoms/ScarletMonastery/boss_arcanist_doan.cpp3
-rw-r--r--src/server/scripts/EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp3
2 files changed, 6 insertions, 0 deletions
diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_arcanist_doan.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_arcanist_doan.cpp
index 5016214f828..cad5668aec8 100644
--- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_arcanist_doan.cpp
+++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_arcanist_doan.cpp
@@ -105,6 +105,9 @@ class boss_arcanist_doan : public CreatureScript
default:
break;
}
+
+ if (me->HasUnitState(UNIT_STATE_CASTING))
+ return;
}
if (_healthAbove50Pct && HealthBelowPct(50))
diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp
index 3b25f39feb4..8816caacaa8 100644
--- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp
+++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp
@@ -102,6 +102,9 @@ class boss_azshir_the_sleepless : public CreatureScript
default:
break;
}
+
+ if (me->HasUnitState(UNIT_STATE_CASTING))
+ return;
}
DoMeleeAttackIfReady();