Core/Spells: Implement using different difficulty data from all spell related db2s, not just SpellEffect and SpellPower

This commit is contained in:
Shauren
2020-06-12 01:29:18 +02:00
parent 1cdd1d0249
commit c7306439e7
101 changed files with 1631 additions and 1796 deletions

View File

@@ -656,7 +656,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
// unless target is outside spell range, out of mana, or LOS.
bool _allowMove = false;
SpellInfo const* spellInfo = sSpellMgr->AssertSpellInfo(e.action.cast.spell);
SpellInfo const* spellInfo = sSpellMgr->AssertSpellInfo(e.action.cast.spell, me->GetMap()->GetDifficultyID());
std::vector<SpellPowerCost> costs = spellInfo->CalcPowerCost(me, spellInfo->GetSchoolMask());
bool hasPower = true;
for (SpellPowerCost const& cost : costs)