From 6c44316d8e7d94bb28beafe32c649d46cf9240f4 Mon Sep 17 00:00:00 2001 From: QAston Date: Tue, 14 Apr 2009 19:09:08 +0200 Subject: *Correct positivity of some spells --HG-- branch : trunk --- src/game/SpellAuras.cpp | 24 +++++++++++------------- src/game/SpellMgr.cpp | 18 +++++++++++++++++- 2 files changed, 28 insertions(+), 14 deletions(-) (limited to 'src') diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp index 3c427706d19..5479ea7f7c2 100644 --- a/src/game/SpellAuras.cpp +++ b/src/game/SpellAuras.cpp @@ -426,24 +426,22 @@ m_auraSlot(MAX_AURAS), m_auraLevel(1), m_procCharges(0), m_stackAmount(1),m_aura // Aura is positive when it is casted by friend and at least one aura is positive // or when it is casted by enemy and at least one aura is negative bool swap=false; - if (!caster || caster==target) - m_positive=IsPositiveSpell(m_spellProto->Id); + if (!caster || caster==target) // caster == target - 1 negative effect is enough for aura to be negative + m_positive = false; else - { m_positive = !caster->IsHostileTo(m_target); - for (uint8 i=0;i positive) if(spellproto->CalculateSimpleValue(effIndex) > 0) - return false; + { + if (!deep) + { + bool negative = true; + for (uint8 i=0;i