Core/Auras: Fix refresh of auras with spellmodifiers applied to currently cast spell.

This commit is contained in:
QAston
2011-06-21 19:59:17 +02:00
parent 65233f8e66
commit c4818f1892
5 changed files with 25 additions and 4 deletions
@@ -826,6 +826,7 @@ bool Aura::ModStackAmount(int32 num, AuraRemoveMode removeMode)
if (refresh)
{
RefreshSpellMods();
RefreshTimers();
// reset charges
@@ -835,6 +836,13 @@ bool Aura::ModStackAmount(int32 num, AuraRemoveMode removeMode)
return false;
}
void Aura::RefreshSpellMods()
{
for (Aura::ApplicationMap::const_iterator appIter = m_applications.begin(); appIter != m_applications.end(); ++appIter)
if (Player * player = appIter->second->GetTarget()->ToPlayer())
player->RestoreAllSpellMods(0, this);
}
bool Aura::IsPassive() const
{
return IsPassiveSpell(GetSpellProto());