#include "UnitAI.h"
- Todo:
- : Add more checks from Spell::CheckCast
◆ SpellTargetSelector()
SpellTargetSelector::SpellTargetSelector |
( |
Unit * |
caster, |
|
|
uint32 |
spellId |
|
) |
| |
419 :
421{
423}
#define ASSERT
Definition Errors.h:68
#define sSpellMgr
Definition SpellMgr.h:825
SpellInfo const * _spellInfo
Definition UnitAI.h:116
Unit const * _caster
Definition UnitAI.h:115
References _spellInfo, and ASSERT.
◆ operator()()
bool SpellTargetSelector::operator() |
( |
Unit const * |
target | ) |
const |
426{
427 if (!target)
428 return false;
429
431 return false;
432
433
437
438 if (target && target !=
_caster)
439 {
441 {
442
444 return false;
445 }
447 return false;
448
450 {
452 return false;
453 }
455 return false;
456 }
457
458 return true;
459}
std::uint32_t uint32
Definition Define.h:107
@ SPELL_CAST_OK
Definition SharedDefines.h:1138
@ SPELL_RANGE_MELEE
Definition Spell.h:91
@ SPELL_RANGE_RANGED
Definition Spell.h:92
SpellRangeEntry const * RangeEntry
Definition SpellInfo.h:369
SpellCastResult CheckTarget(Unit const *caster, WorldObject const *target, bool implicit=true) const
Definition SpellInfo.cpp:1759
bool IsWithinCombatRange(Unit const *obj, float dist2compare) const
Definition Unit.cpp:649
float GetSpellMinRangeForTarget(Unit const *target, SpellInfo const *spellInfo) const
Definition Unit.cpp:15227
bool IsWithinMeleeRange(Unit const *obj, float dist=0.f) const
Definition Unit.cpp:665
float GetSpellMaxRangeForTarget(Unit const *target, SpellInfo const *spellInfo) const
Definition Unit.cpp:15207
uint32 Flags
Definition DBCStructure.h:1798
References _caster, _spellInfo, SpellInfo::CheckTarget(), SpellRangeEntry::Flags, Unit::GetSpellMaxRangeForTarget(), Unit::GetSpellMinRangeForTarget(), Unit::IsWithinCombatRange(), Unit::IsWithinMeleeRange(), SpellInfo::RangeEntry, SPELL_CAST_OK, SPELL_RANGE_MELEE, and SPELL_RANGE_RANGED.
◆ _caster
Unit const* SpellTargetSelector::_caster |
|
private |
◆ _spellInfo
SpellInfo const* SpellTargetSelector::_spellInfo |
|
private |
The documentation for this struct was generated from the following files:
- azerothcore-wotlk/src/server/game/AI/CoreAI/UnitAI.h
- azerothcore-wotlk/src/server/game/AI/CoreAI/UnitAI.cpp