Core/Spells: Fixed spells that scale value with master not being affected by SpellModOp::Points and SpellModOp::PointsIndex spellmods

This commit is contained in:
Shauren
2025-03-21 00:07:16 +01:00
parent 0922b9d4d9
commit bb67a42791
3 changed files with 14 additions and 22 deletions
+4 -13
View File
@@ -550,20 +550,11 @@ void Player::UpdateMastery()
if (!chrSpec)
return;
for (int32 masterySpellId : chrSpec->MasterySpellID)
{
if (Aura* aura = GetAura(masterySpellId))
{
for (auto const& [_, aura] : GetOwnedAuras())
if (aura->GetCasterGUID() == GetGUID() && aura->GetSpellInfo()->HasAttribute(SPELL_ATTR8_MASTERY_AFFECTS_POINTS))
for (AuraEffect* auraEff : aura->GetAuraEffects())
{
float mult = auraEff->GetSpellEffectInfo().BonusCoefficient;
if (G3D::fuzzyEq(mult, 0.0f))
continue;
auraEff->ChangeAmount(int32(value * mult));
}
}
}
if (G3D::fuzzyNe(auraEff->GetSpellEffectInfo().BonusCoefficient, 0.0f))
auraEff->RecalculateAmount(this);
}
void Player::UpdateVersatilityDamageDone()