aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Spells/SpellMgr.cpp
diff options
context:
space:
mode:
authorariel- <ariel-@users.noreply.github.com>2018-01-23 11:40:15 -0300
committerShauren <shauren.trinity@gmail.com>2021-08-28 15:59:11 +0200
commit1e1415a49128d034c8d48aa8cbb5d157200371b0 (patch)
tree20477671803bb9af5157272e0ffb470e27c98fc1 /src/server/game/Spells/SpellMgr.cpp
parentf2cc3adbc5d5f55fc1352b3866d04bfb54ae6b43 (diff)
Core/Spells: rework part 1: Improved positive detection logic
(cherry picked from commit efeae33495c8b57ae04aeeb382ee85099ac0b600)
Diffstat (limited to 'src/server/game/Spells/SpellMgr.cpp')
-rw-r--r--src/server/game/Spells/SpellMgr.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/server/game/Spells/SpellMgr.cpp b/src/server/game/Spells/SpellMgr.cpp
index 57eff46b809..78fe53bb051 100644
--- a/src/server/game/Spells/SpellMgr.cpp
+++ b/src/server/game/Spells/SpellMgr.cpp
@@ -2925,7 +2925,6 @@ void SpellMgr::LoadSpellInfoCustomAttributes()
continue;
}
- // TODO: validate attributes
for (SpellInfo const& spellInfo : spells)
{
if (attributes & SPELL_ATTR0_CU_SHARE_DAMAGE)
@@ -3079,9 +3078,6 @@ void SpellMgr::LoadSpellInfoCustomAttributes()
break;
}
}
-
- if (!spellInfoMutable->_IsPositiveEffect(effect->EffectIndex, false))
- spellInfoMutable->NegativeEffects[effect->EffectIndex] = true;
}
// spells ignoring hit result should not be binary
@@ -3167,6 +3163,8 @@ void SpellMgr::LoadSpellInfoCustomAttributes()
spellInfoMutable->AttributesCu |= SPELL_ATTR0_CU_SCHOOLMASK_NORMAL_WITH_MAGIC;
}
+ spellInfoMutable->_InitializeSpellPositivity();
+
if (talentSpells.count(spellInfoMutable->Id))
spellInfoMutable->AttributesCu |= SPELL_ATTR0_CU_IS_TALENT;