From 50e8de103b65be3addb1f0fefb4ed4bf13d5a30a Mon Sep 17 00:00:00 2001 From: Treeston Date: Mon, 11 Sep 2017 16:13:35 +0200 Subject: Scripts/Naxxramas: Fix an edge case crash with people teleporting out of the dungeon during the Patchwerk encounter (tagging #20247) --- src/server/scripts/Northrend/Naxxramas/boss_patchwerk.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/server/scripts/Northrend/Naxxramas/boss_patchwerk.cpp b/src/server/scripts/Northrend/Naxxramas/boss_patchwerk.cpp index eeb5f7b18bc..d3b9da4f99d 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; } -- cgit v1.2.3