[11989] Add support to call spell_scripts in more cases

* Support to script Dummy spells with spell_scripts
* Support to script TriggerSpell spells which have no existing triggered spell
Note that the order which spell-effect actually triggers the DB script is well-defined (SCRIPT_EFFECT before DUMMY before other)

Signed-off-by: Schmoozerd <schmoozerd@scriptdev2.com>
This commit is contained in:
Schmoozerd 2012-05-08 17:28:30 +02:00
parent dd1d913ff2
commit 83d7d86255
9 changed files with 86 additions and 22 deletions

View file

@ -846,7 +846,7 @@ void Spell::AddUnitTarget(Unit* pVictim, SpellEffectIndex effIndex)
TargetInfo target;
target.targetGUID = targetGUID; // Store target GUID
target.effectMask = immuned ? 0 : (1 << effIndex); // Store index of effect if not immuned
target.processed = false; // Effects not apply on target
target.processed = false; // Effects not applied on target
// Calculate hit result
target.missCondition = m_caster->SpellHitResult(pVictim, m_spellInfo, m_canReflect);