Core/Units: fixed a typo that was causing units without mana to deal no spell damage anymore
This commit is contained in:
1 parent
6b0f11d6b9
commit
7a08639397
1 file changed
+1
-1
@@ -6725,7 +6725,7 @@ float Unit::SpellDamagePctDone(Unit* victim, SpellInfo const* spellProto, Damage
|
||||
}
|
||||
|
||||
// Add SPELL_AURA_MOD_DAMAGE_FROM_MANA percent bonus
|
||||
if (GetPowerIndex(POWER_MANA) != MAX_POWERS)
|
||||
if (HasAuraType(SPELL_AURA_MOD_DAMAGE_FROM_MANA) && GetMaxPower(POWER_MANA))
|
||||
{
|
||||
float totalBonus = (owner->GetTotalAuraMultiplierByMiscMask(SPELL_AURA_MOD_DAMAGE_FROM_MANA, spellProto->GetSchoolMask()) - 1.f) * 100.f;
|
||||
float manaPct = 100.f* ((float)GetPower(POWER_MANA) / GetMaxPower(POWER_MANA));
|
||||
|
||||
Reference in new issue
Block a user