diff options
| author | megamage <none@none> | 2009-03-07 14:06:09 -0600 |
|---|---|---|
| committer | megamage <none@none> | 2009-03-07 14:06:09 -0600 |
| commit | 42d681eecdd668b9d53c93acf0e205047458a781 (patch) | |
| tree | 1234761775e1d927345020dfd424aab2556afa51 /src/game/Spell.cpp | |
| parent | 520ce96257a07c0ad07a652e01a3927af0f48f6f (diff) | |
*Fix some spells without target info sent to server.
--HG--
branch : trunk
Diffstat (limited to 'src/game/Spell.cpp')
| -rw-r--r-- | src/game/Spell.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/game/Spell.cpp b/src/game/Spell.cpp index 6d34d29b644..77fbf5e3380 100644 --- a/src/game/Spell.cpp +++ b/src/game/Spell.cpp @@ -408,6 +408,13 @@ Spell::Spell( Unit* Caster, SpellEntry const *info, bool triggered, uint64 origi } } + if(!m_targets.getUnitTargetGUID() && m_spellInfo->Targets & TARGET_FLAG_UNIT) + { + if(Unit *target = ObjectAccessor::GetUnit(*m_caster, m_caster->GetUInt64Value(UNIT_FIELD_TARGET))) + if(IsValidSingleTargetSpell(target)) + m_targets.setUnitTarget(target); + } + CleanupTargetList(); } |
