mirror of
https://github.com/mangosfour/server.git
synced 2025-12-16 13:37:00 +00:00
[12203] Improve EffectTeleUnitsFaceCaster and target-selection for position targets
* Let EffectTeleUnitsFaceCaster use a destination for teleporting if provided * Expect to add caster for TARGET_RANDOM_NEARBY_LOC, TARGET_RANDOM_CIRCUMFERENCE_POINT only for summon spells (or similar spells)
This commit is contained in:
parent
6ba3c19a22
commit
d2679caf85
3 changed files with 12 additions and 5 deletions
|
|
@ -1946,7 +1946,10 @@ void Spell::SetTargetMap(SpellEffectIndex effIndex, uint32 targetMode, UnitList&
|
|||
m_caster->GetClosePoint(dest_x, dest_y, dest_z, 0.0f, radius, angle);
|
||||
m_targets.setDestination(dest_x, dest_y, dest_z);
|
||||
|
||||
targetUnitMap.push_back(m_caster);
|
||||
// This targetMode is often used as 'last' implicitTarget for positive spells, that just require coordinates
|
||||
// and no unitTarget (e.g. summon effects). As MaNGOS always needs a unitTarget we add just the caster here.
|
||||
if (IsPositiveSpell(m_spellInfo))
|
||||
targetUnitMap.push_back(m_caster);
|
||||
break;
|
||||
}
|
||||
case TARGET_91:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue