Scripts/Spells: Fixed crash in spell_pri_atonement

Port From (https://github.com/TrinityCore/TrinityCore/commit/0f09fc355aea4745b711e4c2ba4dfdb731453f1f)
This commit is contained in:
hondacrx
2022-09-07 15:40:03 -04:00
parent 04afbd8f33
commit c8964bd420
+1 -1
View File
@@ -256,7 +256,7 @@ namespace Scripts.Spells.Priest
foreach (uint effectIndex in new[] { 0, 1, 2 })
{
AuraEffect sinOfTheMany = GetTarget().GetAuraEffect(SpellIds.SinsOfTheMany, effectIndex);
AuraEffect sinOfTheMany = GetUnitOwner().GetAuraEffect(SpellIds.SinsOfTheMany, effectIndex);
if (sinOfTheMany != null)
sinOfTheMany.ChangeAmount((int)damageByStack[Math.Min(_appliedAtonements.Count, damageByStack.Length - 1)]);
}