*Fix usage of EffectValueMultiplier in spell code.
*Remove some obsolete code from spell class. *Rename some spellmod and dbc column names to be more accurate. --HG-- branch : trunk
This commit is contained in:
1 parent
3c027962ba
commit
30d31ca40a
10 files changed
+73
-162
No files matched your search
@@ -1896,6 +1896,26 @@ int32 SpellMgr::CalculateSpellEffectBaseAmount(int32 value, SpellEntry const * s
|
||||
return value - 1;
|
||||
}
|
||||
|
||||
float SpellMgr::CalculateSpellEffectValueMultiplier(SpellEntry const * spellEntry, uint8 effIndex, Unit * caster, Spell const * spell)
|
||||
{
|
||||
float multiplier = spellEntry->EffectValueMultiplier[effIndex];
|
||||
|
||||
if (caster)
|
||||
if (Player * modOwner = caster->GetSpellModOwner())
|
||||
modOwner->ApplySpellMod(spellEntry->Id, SPELLMOD_VALUE_MULTIPLIER, multiplier);
|
||||
return multiplier;
|
||||
}
|
||||
|
||||
float SpellMgr::CalculateSpellEffectDamageMultiplier(SpellEntry const * spellEntry, uint8 effIndex, Unit * caster, Spell const * spell)
|
||||
{
|
||||
float multiplier = spellEntry->EffectDamageMultiplier[effIndex];
|
||||
|
||||
if (caster)
|
||||
if (Player * modOwner = caster->GetSpellModOwner())
|
||||
modOwner->ApplySpellMod(spellEntry->Id, SPELLMOD_DAMAGE_MULTIPLIER, multiplier);
|
||||
return multiplier;
|
||||
}
|
||||
|
||||
SpellEntry const* SpellMgr::SelectAuraRankForPlayerLevel(SpellEntry const* spellInfo, uint32 playerLevel) const
|
||||
{
|
||||
// ignore passive spells
|
||||
|
||||
Reference in new issue
Block a user