From 1a09bfc2751d6fa6ec8b04c6d08e4b53f37796e5 Mon Sep 17 00:00:00 2001 From: hondacrx Date: Fri, 7 Jan 2022 17:03:52 -0500 Subject: [PATCH] Core/Spells: Fixed Spell::GetUnitTargetCountForEffect incorrectly counting missed targets instead of hit targets Port From (https://github.com/TrinityCore/TrinityCore/commit/570e882d024991b44ccfd2fb2891a25ee054587b) --- Source/Game/Spells/Spell.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Game/Spells/Spell.cs b/Source/Game/Spells/Spell.cs index c03ffc3a6..1486aa624 100644 --- a/Source/Game/Spells/Spell.cs +++ b/Source/Game/Spells/Spell.cs @@ -1866,7 +1866,7 @@ namespace Game.Spells public long GetUnitTargetCountForEffect(uint effect) { - return m_UniqueTargetInfo.Count(targetInfo => targetInfo.MissCondition == SpellMissInfo.Miss && (targetInfo.EffectMask & (1 << (int)effect)) != 0); + return m_UniqueTargetInfo.Count(targetInfo => targetInfo.MissCondition == SpellMissInfo.None && (targetInfo.EffectMask & (1 << (int)effect)) != 0); } public long GetGameObjectTargetCountForEffect(uint effect)