From 771c3b175ed28228cfd49648ab8a4e7ad818906d Mon Sep 17 00:00:00 2001 From: "Michael Cook (mackal)" Date: Tue, 1 Aug 2017 13:09:18 -0400 Subject: [PATCH] Fix AffectedBySpellExcludingSlot --- zone/spell_effects.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/zone/spell_effects.cpp b/zone/spell_effects.cpp index fc9cd51a3..6a50ab142 100644 --- a/zone/spell_effects.cpp +++ b/zone/spell_effects.cpp @@ -5963,7 +5963,8 @@ bool Mob::TryDeathSave() { bool Mob::AffectedBySpellExcludingSlot(int slot, int effect) { - for (int i = 0; i <= EFFECT_COUNT; i++) + int buff_count = GetMaxTotalSlots(); + for (int i = 0; i < buff_count; i++) { if (i == slot) continue;