aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTreeston <treeston.mmoc@gmail.com>2017-09-11 16:13:35 +0200
committerShauren <shauren.trinity@gmail.com>2020-08-29 00:14:50 +0200
commitbece27ef3fe346452da5fd1c0ff947ea18686680 (patch)
tree1a2ac1f88b7d8e3e8e127be617ca7cdf4d22abce /src
parent1108164f1b56e8bd4b90e3ed9beb046d5399735a (diff)
Scripts/Naxxramas: Fix an edge case crash with people teleporting out of the dungeon during the Patchwerk encounter (tagging #20247)
(cherry picked from commit 50e8de103b65be3addb1f0fefb4ed4bf13d5a30a)
Diffstat (limited to 'src')
-rw-r--r--src/server/scripts/Northrend/Naxxramas/boss_patchwerk.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/server/scripts/Northrend/Naxxramas/boss_patchwerk.cpp b/src/server/scripts/Northrend/Naxxramas/boss_patchwerk.cpp
index 5393c0db2fd..22cc46fae4a 100644
--- a/src/server/scripts/Northrend/Naxxramas/boss_patchwerk.cpp
+++ b/src/server/scripts/Northrend/Naxxramas/boss_patchwerk.cpp
@@ -131,11 +131,11 @@ public:
if ((*it)->GetVictim() != currentVictim)
secondThreat = *it;
- if ((!secondThreat || Is25ManRaid()) && (++it != end))
+ if ((!secondThreat || Is25ManRaid()) && (++it != end && (*it)->IsAvailable()))
{
if ((*it)->GetVictim() != currentVictim)
(secondThreat ? thirdThreat : secondThreat) = *it;
- if (!thirdThreat && Is25ManRaid() && (++it != end))
+ if (!thirdThreat && Is25ManRaid() && (++it != end && (*it)->IsAvailable()))
thirdThreat = *it;
}