[11220] Implement support positive persistent auras

Note this alos have bad side: if some spell wrongly checks as possitive then it will work wrong after.
So report if any.
This commit is contained in:
VladimirMangos 2011-03-05 23:01:56 +03:00
parent 8f3d97d955
commit d3947b2026
5 changed files with 10 additions and 6 deletions

View file

@ -96,6 +96,7 @@ bool DynamicObject::Create( uint32 guidlow, Unit *caster, uint32 spellId, SpellE
m_radius = radius;
m_effIndex = effIndex;
m_spellId = spellId;
m_positive = IsPositiveEffect(m_spellId, m_effIndex);
return true;
}
@ -127,7 +128,7 @@ void DynamicObject::Update(uint32 update_diff, uint32 p_time)
if(m_radius)
{
// TODO: make a timer and update this in larger intervals
MaNGOS::DynamicObjectUpdater notifier(*this, caster);
MaNGOS::DynamicObjectUpdater notifier(*this, caster, m_positive);
Cell::VisitAllObjects(this, notifier, m_radius);
}