diff options
author | Shauren <shauren.trinity@gmail.com> | 2025-01-09 17:48:41 +0100 |
---|---|---|
committer | Ovahlord <dreadkiller@gmx.de> | 2025-01-09 20:56:16 +0100 |
commit | b6b985a8221f0229e49d4a3722f3d05acf692c42 (patch) | |
tree | 85f36ef70ca9c810ad0d7505f2e870277315a247 /src/server/game/Spells/SpellScript.cpp | |
parent | 9e26bf6a7f7dcf0802ca87cb976da7b5df24ff56 (diff) |
Core/Spells: Replace MAX_SPELL_EFFECTS loop limits with correct upper bound depending on how many effects the spell has
(cherry picked from commit 561b122364525deaee815ad900a78f1323c37776)
# Conflicts:
# src/server/game/Spells/Spell.cpp
Diffstat (limited to 'src/server/game/Spells/SpellScript.cpp')
-rw-r--r-- | src/server/game/Spells/SpellScript.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/server/game/Spells/SpellScript.cpp b/src/server/game/Spells/SpellScript.cpp index 79087620742..f8eb76085ab 100644 --- a/src/server/game/Spells/SpellScript.cpp +++ b/src/server/game/Spells/SpellScript.cpp @@ -118,7 +118,7 @@ uint32 SpellScriptBase::EffectHook::GetAffectedEffectsMask(SpellInfo const* spel uint32 mask = 0; if (_effIndex == EFFECT_ALL || _effIndex == EFFECT_FIRST_FOUND) { - for (uint8 i = 0; i < MAX_SPELL_EFFECTS; ++i) + for (uint8 i = 0; i < spellInfo->GetEffects().size(); ++i) { if (_effIndex == EFFECT_FIRST_FOUND && mask) return mask; |