Core/Spells: calculate crit chance only for spells that do damage/healing

Port From (https://github.com/TrinityCore/TrinityCore/commit/85e5509e91a1370b16851d375a26121797870921)
This commit is contained in:
hondacrx
2021-06-23 22:06:49 -04:00
parent 89586e9495
commit 9e23ca4b04
6 changed files with 80 additions and 43 deletions
+1 -1
View File
@@ -6872,7 +6872,7 @@ namespace Game.Spells
}
}
float critChance = m_caster.SpellCritChanceDone(m_spellInfo, m_spellSchoolMask, m_attackType);
float critChance = m_caster.SpellCritChanceDone(this, null, m_spellSchoolMask, m_attackType);
targetInfo.crit = RandomHelper.randChance(unit.SpellCritChanceTaken(m_caster, this, null, m_spellSchoolMask, critChance, m_attackType));
}