#include "UnitAI.h"
◆ PowerUsersSelector()
PowerUsersSelector::PowerUsersSelector |
( |
Unit const * |
unit, |
|
|
Powers |
power, |
|
|
float |
dist, |
|
|
bool |
playerOnly, |
|
|
bool |
withTank = true |
|
) |
| |
|
inline |
◆ operator()()
bool PowerUsersSelector::operator() |
( |
Unit const * |
target | ) |
const |
|
inline |
145 {
147 return false;
148
150 return false;
151
152 if (target->getPowerType() !=
_power)
153 return false;
154
156 return false;
157
159 return false;
160
161 if (_dist < 0.0f && _me->IsWithinCombatRange(target, -
_dist))
162 return false;
163
164 return true;
165 }
Unit * GetCurrentVictim() const
Definition ThreatMgr.h:212
bool IsWithinCombatRange(Unit const *obj, float dist2compare) const
Definition Unit.cpp:648
ThreatMgr & GetThreatMgr()
Definition Unit.h:912
References _dist, _me, _playerOnly, _power, _withTank, ThreatMgr::GetCurrentVictim(), Unit::getPowerType(), Unit::GetThreatMgr(), Object::IsPlayer(), and Unit::IsWithinCombatRange().
◆ _dist
float const PowerUsersSelector::_dist |
◆ _me
Unit const* PowerUsersSelector::_me |
◆ _playerOnly
bool const PowerUsersSelector::_playerOnly |
◆ _power
Powers const PowerUsersSelector::_power |
◆ _withTank
bool const PowerUsersSelector::_withTank |
The documentation for this struct was generated from the following file:
- azerothcore-wotlk/src/server/game/AI/CoreAI/UnitAI.h