mirror of
https://github.com/mangosfour/server.git
synced 2025-12-20 16:37:04 +00:00
[11288] Check IsPositiveEffect in IsPositiveSpell only for existed effects.
Thanks to NoFantasy for problem research. Also make IsPositiveEffect use SpellEntry* arg instead spell id.
This commit is contained in:
parent
dae28ae93a
commit
989d229968
9 changed files with 24 additions and 21 deletions
|
|
@ -783,7 +783,7 @@ void Spell::prepareDataForTriggerSystem()
|
|||
// avoid triggering negative hit for only positive targets
|
||||
m_negativeEffectMask = 0x0;
|
||||
for (int i = 0; i < MAX_EFFECT_INDEX; ++i)
|
||||
if (!IsPositiveEffect(m_spellInfo->Id, SpellEffectIndex(i)))
|
||||
if (!IsPositiveEffect(m_spellInfo, SpellEffectIndex(i)))
|
||||
m_negativeEffectMask |= (1<<i);
|
||||
|
||||
// Hunter traps spells (for Entrapment trigger)
|
||||
|
|
@ -1832,7 +1832,7 @@ void Spell::SetTargetMap(SpellEffectIndex effIndex, uint32 targetMode, UnitList&
|
|||
SpellTargets targetB = SPELL_TARGETS_AOE_DAMAGE;
|
||||
|
||||
// Select friendly targets for positive effect
|
||||
if (IsPositiveEffect(m_spellInfo->Id, effIndex))
|
||||
if (IsPositiveEffect(m_spellInfo, effIndex))
|
||||
targetB = SPELL_TARGETS_FRIENDLY;
|
||||
|
||||
UnitList tempTargetUnitMap;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue