19 #ifndef TRINITY_GRIDNOTIFIERS_H
20 #define TRINITY_GRIDNOTIFIERS_H
50 VisibleNotifier(Player &player) : i_player(player), i_data(player.GetMapId()), vis_guids(player.m_clientGUIDs) { }
52 void SendToSelf(
void);
91 i_map(map), cell(c), p(pair), i_radius(radius) { }
115 iter->GetSource()->Update(i_timeDiff);
134 : i_source(src), i_message(msg), i_distSq(dist * dist)
136 , skipped_receiver(skipped)
140 team = player->GetTeam();
151 if (player == i_source || (team && player->GetTeam() != team) || skipped_receiver == player)
154 if (!player->HaveAtClient(i_source))
158 session->SendPacket(i_message);
175 template<
class Check>
184 : _searcher(searcher), i_object(result), i_check(check), i_mapTypeMask(mapTypeMask) { }
196 template<
class Check>
205 : _searcher(searcher), i_object(result), i_check(check), i_mapTypeMask(mapTypeMask) { }
217 template<
class Check>
226 : i_mapTypeMask(mapTypeMask), _searcher(searcher), i_objects(objects), i_check(check) { }
246 : i_mapTypeMask(mapTypeMask), _searcher(searcher), i_do(_do) { }
253 if (itr->GetSource()->IsInPhase(_searcher))
254 i_do(itr->GetSource());
262 if (itr->GetSource()->IsInPhase(_searcher))
263 i_do(itr->GetSource());
270 if (itr->GetSource()->IsInPhase(_searcher))
271 i_do(itr->GetSource());
279 if (itr->GetSource()->IsInPhase(_searcher))
280 i_do(itr->GetSource());
288 if (itr->GetSource()->IsInPhase(_searcher))
289 i_do(itr->GetSource());
297 if (itr->GetSource()->IsInPhase(_searcher))
298 i_do(itr->GetSource());
306 template<
class Check>
314 : _searcher(searcher), i_object(result), i_check(check) { }
322 template<
class Check>
330 : _searcher(searcher), i_object(result), i_check(check) { }
337 template<
class Check>
345 : _searcher(searcher), i_objects(objects), i_check(check) { }
352 template<
class Functor>
361 if (itr->GetSource()->IsInPhase(
_searcher))
362 _func(itr->GetSource());
375 template<
class Check>
383 : _searcher(searcher), i_object(result), i_check(check) { }
392 template<
class Check>
400 : _searcher(searcher), i_object(result), i_check(check) { }
409 template<
class Check>
417 : _searcher(searcher), i_objects(objects), i_check(check) { }
427 template<
class Check>
435 : _searcher(searcher), i_object(result), i_check(check) { }
443 template<
class Check>
451 : _searcher(searcher), i_object(result), i_check(check) { }
458 template<
class Check>
466 : _searcher(searcher), i_objects(objects), i_check(check) { }
480 : _searcher(searcher), i_do(_do) { }
485 if (itr->GetSource()->IsInPhase(_searcher))
486 i_do(itr->GetSource());
494 template<
class Check>
502 : _searcher(searcher), i_object(result), i_check(check) { }
509 template<
class Check>
517 : _searcher(searcher), i_objects(objects), i_check(check) { }
524 template<
class Check>
547 : _searcher(searcher), i_do(_do) { }
552 if (itr->GetSource()->IsInPhase(_searcher))
553 i_do(itr->GetSource());
567 : i_searcher(searcher), i_dist(_dist), i_do(_do) { }
572 if (itr->GetSource()->IsInPhase(i_searcher) && itr->GetSource()->IsWithinDist(i_searcher, i_dist))
573 i_do(itr->GetSource());
587 bool operator()(Player* u);
588 bool operator()(
Corpse* u);
590 template<
class NOT_INTERESTED>
bool operator()(NOT_INTERESTED*) {
return false; }
602 bool operator()(Player* u);
603 bool operator()(
Corpse* u);
605 template<
class NOT_INTERESTED>
bool operator()(NOT_INTERESTED*) {
return false; }
829 if (!u->isTargetableForAttack(
false))
1010 m_range = (dist == 0 ? 9999 : dist);
1039 m_range = (dist == 0 ? 9999 : dist);
1040 m_force = (dist == 0 ?
false :
true);
1350 return object->GetGUID() ==
_GUID;
1399 template<
class Builder>
1418 template<
class Builder>
float i_range
Definition: GridNotifiers.h:988
void Visit(CreatureMapType &m)
Definition: GridNotifiers.h:265
Creature *const i_obj
Definition: GridNotifiers.h:1153
float x
Definition: GridNotifiers.h:1313
GameObjectFocusCheck(Unit const *unit, uint32 focusId)
Definition: GridNotifiers.h:628
PlayerWorker(WorldObject const *searcher, Do &_do)
Definition: GridNotifiers.h:546
Functor & _func
Definition: GridNotifiers.h:368
bool operator()(NOT_INTERESTED *)
Definition: GridNotifiers.h:590
bool HasAura(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint32 reqEffMask=0) const
Definition: Unit.cpp:4240
bool _reverse
Definition: GridNotifiers.h:1373
Definition: GridNotifiers.h:1069
Definition: GridNotifiers.h:902
bool _present
Definition: GridNotifiers.h:1391
Definition: GridDefines.h:78
float GetLastRange() const
Definition: GridNotifiers.h:1177
Definition: GridNotifiers.h:338
UpdateData i_data
Definition: GridNotifiers.h:46
LocalizedPacketListDo(Builder &builder)
Definition: GridNotifiers.h:1423
Definition: GridDefines.h:79
bool operator()(WorldObject *object)
Definition: GridNotifiers.h:1334
WorldObject const * _searcher
Definition: GridNotifiers.h:430
bool i_alive
Definition: GridNotifiers.h:1181
MessageDistDeliverer(WorldObject *src, WorldPacket const *msg, float dist, bool own_team_only=false, Player const *skipped=NULL)
Definition: GridNotifiers.h:133
void updateObjects(GridRefManager< T > &m)
Definition: GridNotifiers.h:112
ObjectGuid _casterGUID
Definition: GridNotifiers.h:1393
bool operator()(Unit *u)
Definition: GridNotifiers.h:782
uint32 m_uiEntry
Definition: GridNotifiers.h:1261
Definition: GridNotifiers.h:840
Unit *const i_enemy
Definition: GridNotifiers.h:987
bool operator()(WorldObject *go)
Definition: GridNotifiers.h:1321
Definition: GridNotifiers.h:176
WorldObject const & i_obj
Definition: GridNotifiers.h:684
float i_range
Definition: GridNotifiers.h:709
Definition: GridNotifiers.h:1098
GameObjectListSearcher(WorldObject const *searcher, std::list< GameObject * > &objects, Check &check)
Definition: GridNotifiers.h:344
static ObjectGuid const Empty
Definition: ObjectGuid.h:196
NearestHostileUnitCheck(Creature const *creature, float dist=0, bool playerOnly=false)
Definition: GridNotifiers.h:1008
WorldObject const * _searcher
Definition: GridNotifiers.h:199
uint32 GetMaxHealth() const
Definition: Unit.h:1427
RespawnDo()
Definition: GridNotifiers.h:616
NearestAssistCreatureInCreatureRangeCheck(Creature *obj, Unit *enemy, float range)
Definition: GridNotifiers.h:1132
NearestGameObjectFishingHole(WorldObject const &obj, float range)
Definition: GridNotifiers.h:650
Do const & i_do
Definition: GridNotifiers.h:243
float i_range
Definition: GridNotifiers.h:854
Definition: GridNotifiers.h:625
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:349
Check & i_check
Definition: GridNotifiers.h:223
Definition: GridNotifiers.h:162
GameObject *& i_object
Definition: GridNotifiers.h:310
bool operator()(Player *u)
Definition: GridNotifiers.h:1216
AnyUnfriendlyUnitInObjectRangeCheck(WorldObject const *obj, Unit const *funit, float range)
Definition: GridNotifiers.h:800
Unit const * unit
Definition: GridNotifiers.h:1245
Definition: GridNotifiers.h:885
float m_fRange
Definition: GridNotifiers.h:1327
bool operator()(Creature *u)
Definition: GridNotifiers.h:1135
float i_range
Definition: GridNotifiers.h:593
Definition: GridNotifiers.h:323
Definition: GridNotifiers.h:75
Builder & i_builder
Definition: GridNotifiers.h:1434
Definition: GridNotifiers.h:97
Definition: GridNotifiers.h:66
WorldObject const * i_obj
Definition: GridNotifiers.h:1227
bool _IsValidAttackTarget(Unit const *target, SpellInfo const *bySpell, WorldObject const *obj=NULL) const
Definition: Unit.cpp:10008
Check & i_check
Definition: GridNotifiers.h:448
float y
Definition: GridNotifiers.h:1313
Definition: GridNotifiers.h:1005
Definition: GridNotifiers.h:669
Definition: GridNotifiers.h:1188
void Visit(GameObjectMapType &m)
Definition: GridNotifiers.h:120
Definition: SpellInfo.h:326
const WorldObject * m_pObject
Definition: GridNotifiers.h:1260
void operator()(Creature *u) const
Definition: GridNotifiers.h:617
WorldObject const * i_searcher
Definition: GridNotifiers.h:562
WorldObject const * _searcher
Definition: GridNotifiers.h:461
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:521
NearestGameObjectCheck(WorldObject const &obj)
Definition: GridNotifiers.h:672
bool IsWithinLOSInMap(WorldObject const *obj) const
Definition: Object.cpp:1584
WorldObject const & i_obj
Definition: GridNotifiers.h:707
bool operator()(GameObject *go)
Definition: GridNotifiers.h:673
Definition: GridNotifiers.h:560
Map & i_map
Definition: GridNotifiers.h:86
Definition: GridNotifiers.h:376
float m_fRange
Definition: GridNotifiers.h:1280
Definition: GridNotifiers.h:814
PlayerAtMinimumRangeAway(Unit const *unit, float fMinRange)
Definition: GridNotifiers.h:1286
void Visit(PlayerMapType &m)
Definition: GridNotifiersImpl.h:549
Definition: GridNotifiers.h:474
void Visit(AreaTriggerMapType &m)
Definition: GridNotifiers.h:123
Player *& i_object
Definition: GridNotifiers.h:498
Do & i_do
Definition: GridNotifiers.h:477
Check & i_check
Definition: GridNotifiers.h:397
Check & i_check
Definition: GridNotifiers.h:432
void Visit(GridRefManager< T > &)
Definition: GridNotifiers.h:60
bool operator()(Unit *u)
Definition: GridNotifiers.h:1012
float GetLastRange() const
Definition: GridNotifiers.h:729
bool IsInPartyWith(Unit const *unit) const
Definition: Unit.cpp:14372
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:214
Definition: SharedDefines.h:3565
AnyDeadUnitSpellTargetInRangeCheck(Unit *searchObj, float range, SpellInfo const *spellInfo, SpellTargetCheckTypes check)
Definition: GridNotifiers.h:599
uint32 team
Definition: GridNotifiers.h:131
void Visit(CreatureMapType &m)
Definition: GridNotifiersImpl.h:498
UnitAuraCheck(bool present, uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty)
Definition: GridNotifiers.h:1379
bool IsInCombat() const
Definition: Unit.h:1584
void Visit(GridRefManager< T > &m)
Definition: GridNotifiers.cpp:343
float GetLastRange() const
Definition: GridNotifiers.h:660
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:318
AnyGroupedUnitInObjectRangeCheck(WorldObject const *obj, Unit const *funit, float range, bool raid)
Definition: GridNotifiers.h:861
Definition: GridNotifiers.h:1376
Unit *& i_object
Definition: GridNotifiers.h:379
float z
Definition: GridNotifiers.h:1313
bool IsValidAttackTarget(Unit const *target) const
Definition: Unit.cpp:10002
float i_range
Definition: GridNotifiers.h:1155
Definition: GridNotifiers.h:1129
Definition: ObjectGuid.h:32
void operator()(GameObject *u) const
Definition: GridNotifiers.h:618
void Visit(DynamicObjectMapType &m)
Definition: GridNotifiers.h:121
WorldObject const * _searcher
Definition: GridNotifiers.h:512
WorldObject const * _searcher
Definition: GridNotifiers.h:178
WorldObject const * _searcher
Definition: GridNotifiers.h:527
AllWorldObjectsInRange(const WorldObject *object, float maxRange)
Definition: GridNotifiers.h:1320
std::list< Player * > & i_objects
Definition: GridNotifiers.h:513
arena_t NULL
Definition: jemalloc_internal.h:624
Definition: GridNotifiers.h:307
uint32 m_uiEntry
Definition: GridNotifiers.h:1279
Definition: GridNotifiers.h:583
Check & i_check
Definition: GridNotifiers.h:327
const WorldObject * m_pObject
Definition: GridNotifiers.h:1326
Definition: GridNotifiers.h:716
std::list< GameObject * > & i_objects
Definition: GridNotifiers.h:341
void Visit(CreatureMapType &m)
Definition: GridNotifiers.h:119
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:576
bool operator()(Unit *u)
Definition: GridNotifiers.h:1075
Definition: GridNotifiers.h:1400
Definition: SharedDefines.h:2073
LocalizedPacketDo(Builder &builder)
Definition: GridNotifiers.h:1403
bool operator()(Unit *u)
Definition: GridNotifiers.h:1042
ObjectGUIDCheck(ObjectGuid GUID)
Definition: GridNotifiers.h:1347
Definition: GridNotifiers.h:741
TypeID _typeId
Definition: GridNotifiers.h:1340
Definition: GridNotifiers.h:1248
Unit *const i_funit
Definition: GridNotifiers.h:1124
uint32 i_mapTypeMask
Definition: GridNotifiers.h:220
std::list< Unit * > & i_objects
Definition: GridNotifiers.h:413
Definition: Creature.h:467
AnyUnfriendlyNoTotemUnitInObjectRangeCheck(WorldObject const *obj, Unit const *funit, float range)
Definition: GridNotifiers.h:817
float i_range
Definition: GridNotifiers.h:1126
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:301
CreatureRelocationNotifier(Creature &c)
Definition: GridNotifiers.h:78
DynamicObject * ToDynObject()
Definition: Object.h:206
void Respawn()
Definition: GameObject.cpp:1069
void Visit(GridRefManager< T > &)
Definition: GridNotifiers.h:102
Definition: GridNotifiers.h:510
WorldObject const & i_obj
Definition: GridNotifiers.h:662
FriendlyCCedInRange(Unit const *obj, float range)
Definition: GridNotifiers.h:763
float i_range
Definition: GridNotifiers.h:775
bool m_force
Definition: GridNotifiers.h:1065
bool operator()(Unit *unit) const
Definition: GridNotifiers.h:1380
UnitSearcher(WorldObject const *searcher, Unit *&result, Check &check)
Definition: GridNotifiers.h:382
uint32 GetCreatureType() const
Definition: Unit.cpp:11248
Definition: GridDefines.h:77
MostHPMissingInRange(Unit const *obj, float range, uint32 hp)
Definition: GridNotifiers.h:744
Check & i_check
Definition: GridNotifiers.h:514
GameObjectInRangeCheck(float _x, float _y, float _z, float _range, uint32 _entry=0)
Definition: GridNotifiers.h:1304
CreatureWorker(WorldObject const *searcher, Do &_do)
Definition: GridNotifiers.h:479
Unit const * _refUnit
Definition: GridNotifiers.h:880
Definition: GridNotifiers.h:525
Creature & i_creature
Definition: GridNotifiers.h:77
float i_range
Definition: GridNotifiers.h:685
float i_range
Definition: GridNotifiers.h:733
bool operator()(GameObject *go)
Definition: GridNotifiers.h:1306
Definition: UpdateData.h:59
NearestGameObjectTypeInObjectRangeCheck(WorldObject const &obj, GameobjectTypes type, float range)
Definition: GridNotifiers.h:719
bool operator()(Creature *u)
Definition: GridNotifiers.h:1105
Definition: GridNotifiers.h:960
HeightDifferenceCheck(WorldObject *go, float diff, bool reverse)
Definition: GridNotifiers.h:1360
Definition: GridNotifiers.h:858
bool CanAssistTo(const Unit *u, const Unit *enemy, bool checkfaction=true) const
Definition: Creature.cpp:2078
GameobjectTypes
Definition: SharedDefines.h:2063
bool operator()(GameObject *go)
Definition: GridNotifiers.h:696
Definition: GridNotifiers.h:444
WorldObject const * _searcher
Definition: GridNotifiers.h:412
NearestHostileUnitInAttackDistanceCheck(Creature const *creature, float dist=0)
Definition: GridNotifiers.h:1037
bool IsWithinDistInMap(WorldObject const *obj, float dist2compare, bool is3D=true) const
Definition: Object.cpp:1663
WorldObject const & i_obj
Definition: GridNotifiers.h:731
Player * ToPlayer()
Definition: Object.h:191
void Visit(CreatureMapType &m)
Definition: GridNotifiersImpl.h:511
Definition: GridNotifiers.h:495
bool operator()(Unit *u)
Definition: GridNotifiers.h:1237
Unit const * i_funit
Definition: GridNotifiers.h:954
bool _reqAlive
Definition: GridNotifiers.h:1206
float m_fRange
Definition: GridNotifiers.h:1262
Check & i_check
Definition: GridNotifiers.h:414
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:193
Do & i_do
Definition: GridNotifiers.h:544
Creature *& i_object
Definition: GridNotifiers.h:447
GameObjectSearcher(WorldObject const *searcher, GameObject *&result, Check &check)
Definition: GridNotifiers.h:313
Definition: GridNotifiers.h:410
Do & i_do
Definition: GridNotifiers.h:564
GameObjectLastSearcher(WorldObject const *searcher, GameObject *&result, Check &check)
Definition: GridNotifiers.h:329
uint32 _spellId
Definition: GridNotifiers.h:1392
GameObject *& i_object
Definition: GridNotifiers.h:326
ObjectUpdater(const uint32 diff)
Definition: GridNotifiers.h:165
Definition: GridNotifiers.h:613
Definition: GridNotifiers.h:1162
Definition: GridNotifiers.h:541
void Visit(PlayerMapType &m)
Definition: GridNotifiersImpl.h:458
Definition: DynamicObject.h:35
bool IsWithinDist(WorldObject const *obj, float dist2compare, bool is3D=true) const
Definition: Object.cpp:1658
std::vector< WorldPackets::Packet * > WorldPacketList
Definition: GridNotifiers.h:1422
void Visit(GameObjectMapType &m)
Definition: GridNotifiersImpl.h:348
WorldObject const * _searcher
Definition: GridNotifiers.h:476
void Visit(CreatureMapType &m)
Definition: GridNotifiersImpl.h:432
bool _equals
Definition: GridNotifiers.h:1341
uint32 i_spell
Definition: GridNotifiers.h:794
TypeID GetTypeId() const
Definition: Object.h:113
Definition: GridNotifiers.h:778
WorldObject const * _source
Definition: GridNotifiers.h:879
SpellInfo const * _spellInfo
Definition: GridNotifiers.h:955
Check & i_check
Definition: GridNotifiers.h:499
void Visit(GameObjectMapType &m)
Definition: GridNotifiersImpl.h:46
void operator()(Creature *u)
Definition: GridNotifiers.h:966
float range
Definition: GridNotifiers.h:1313
bool operator()(Player *u)
Definition: GridNotifiers.h:1192
FriendlyMissingBuffInRange(Unit const *obj, float range, uint32 spellid)
Definition: GridNotifiers.h:781
uint32 i_mapTypeMask
Definition: GridNotifiers.h:202
bool i_playerOnly
Definition: GridNotifiers.h:855
Definition: GridDefines.h:76
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:537
float _range
Definition: GridNotifiers.h:1205
uint32 i_hp
Definition: GridNotifiers.h:757
bool isFeared() const
Definition: Unit.h:1599
bool operator()(Unit *u)
Definition: GridNotifiers.h:940
void Visit(GameObjectMapType &m)
Definition: GridNotifiersImpl.h:184
bool operator()(Unit *u)
Definition: GridNotifiers.h:906
std::list< WorldObject * > & i_objects
Definition: GridNotifiers.h:222
WorldObject const * _searcher
Definition: GridNotifiers.h:325
Definition: GridNotifiers.h:596
bool operator()(GameObject *go) const
Definition: GridNotifiers.h:629
float GetDistance(WorldObject const *obj) const
Definition: Object.cpp:1594
float GetAggroRange(Unit const *target) const
Definition: Creature.cpp:2557
Unit const * i_funit
Definition: GridNotifiers.h:836
void Visit(GridRefManager< T > &m)
Definition: GridNotifiersImpl.h:32
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:439
Definition: GridNotifiers.h:1344
uint32 i_mapTypeMask
Definition: GridNotifiers.h:241
Unit *& i_object
Definition: GridNotifiers.h:396
float fRange
Definition: GridNotifiers.h:1298
Unit const * i_obj
Definition: GridNotifiers.h:792
WorldObject const * i_obj
Definition: GridNotifiers.h:953
PlayerSearcher(WorldObject const *searcher, Player *&result, Check &check)
Definition: GridNotifiers.h:501
float i_range
Definition: GridNotifiers.h:811
Cell & cell
Definition: GridNotifiers.h:87
const float i_radius
Definition: GridNotifiers.h:89
void operator()(Player *p)
Definition: GridNotifiersImpl.h:562
float i_range
Definition: GridNotifiers.h:756
Definition: GridNotifiers.h:353
float m_range
Definition: GridNotifiers.h:1064
WorldObject const * i_obj
Definition: GridNotifiers.h:835
bool IsAlive() const
Definition: Unit.h:1692
void Visit(PlayerMapType &m)
Definition: GridNotifiers.h:549
Definition: GridNotifiers.h:106
Definition: GridNotifiers.h:55
WorldObject const * _searcher
Definition: GridNotifiers.h:369
WorldObject const * i_obj
Definition: GridNotifiers.h:852
bool operator()(Unit *u)
Definition: GridNotifiers.h:818
UnitLastSearcher(WorldObject const *searcher, Unit *&result, Check &check)
Definition: GridNotifiers.h:399
GridType & i_grid
Definition: GridNotifiers.h:108
void SendPacket(Player *player)
Definition: GridNotifiers.h:148
void Visit(PlayerMapType &m)
Definition: GridNotifiers.h:569
ObjectGuid _GUID
Definition: GridNotifiers.h:1354
Definition: GridNotifiers.h:459
CreatureListSearcher(WorldObject const *searcher, std::list< Creature * > &objects, Check &check)
Definition: GridNotifiers.h:465
WorldObject const * _searcher
Definition: GridNotifiers.h:340
float GetLastRange() const
Definition: GridNotifiers.h:1151
Check & i_check
Definition: GridNotifiers.h:180
CreatureAI * AI() const
Definition: Creature.h:525
Definition: GridNotifiers.h:1330
Definition: GridNotifiers.h:1301
GridUpdater(GridType &grid, uint32 diff)
Definition: GridNotifiers.h:110
void Visit(PlayerMapType &m)
Definition: GridNotifiersImpl.h:529
Definition: GridNotifiers.h:926
void Visit(PlayerMapType &m)
Definition: GridNotifiers.h:118
float i_range
Definition: GridNotifiers.h:920
Definition: GridNotifiers.h:1419
#define sSpellMgr
Definition: SpellMgr.h:756
AnyDeadUnitObjectInRangeCheck(Unit *searchObj, float range)
Definition: GridNotifiers.h:586
CreatureSearcher(WorldObject const *searcher, Creature *&result, Check &check)
Definition: GridNotifiers.h:434
NearestCreatureEntryWithLiveStateInObjectRangeCheck(WorldObject const &obj, uint32 entry, bool alive, float range)
Definition: GridNotifiers.h:1165
float GetPositionZ() const
Definition: Position.h:106
AnyFriendlyUnitInObjectRangeCheck(WorldObject const *obj, Unit const *funit, float range, bool playerOnly=false)
Definition: GridNotifiers.h:843
PlayerLastSearcher(WorldObject const *searcher, Player *&result, Check &check)
Definition: GridNotifiers.h:531
Definition: GridDefines.h:75
bool operator()(Unit *u)
Definition: GridNotifiers.h:844
Definition: GridNotifiers.h:1233
Unit const * i_funit
Definition: GridNotifiers.h:853
uint32_t uint32
Definition: Define.h:150
WorldObject const * _searcher
Definition: GridNotifiers.h:395
bool IsFriendlyTo(Unit const *unit) const
Definition: Unit.cpp:7170
WorldObject const * i_obj
Definition: GridNotifiers.h:809
GameObjectTemplate const * GetGOInfo() const
Definition: GameObject.h:894
Definition: GridNotifiers.h:84
Creature const * _me
Definition: GridNotifiers.h:1093
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:388
Definition: LinkedList.h:141
bool operator()(WorldObject *object)
Definition: GridNotifiers.h:1348
WorldObject *& i_object
Definition: GridNotifiers.h:200
Builder & i_builder
Definition: GridNotifiers.h:1413
WorldPacket const * i_message
Definition: GridNotifiers.h:129
Definition: GridNotifiers.h:991
Definition: GameObject.h:880
void Visit(GameObjectMapType &m)
Definition: GridNotifiers.h:248
bool isFrozen() const
Definition: Unit.cpp:12107
AnyPlayerInObjectRangeCheck(WorldObject const *obj, float range, bool reqAlive=true)
Definition: GridNotifiers.h:1191
Definition: GridNotifiers.h:760
UnitListSearcher(WorldObject const *searcher, std::list< Unit * > &objects, Check &check)
Definition: GridNotifiers.h:416
AllGameObjectsWithEntryInRange(const WorldObject *object, uint32 entry, float maxRange)
Definition: GridNotifiers.h:1251
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:455
bool operator()(Unit *u)
Definition: GridNotifiers.h:745
ObjectTypeIdCheck(TypeID typeId, bool equals)
Definition: GridNotifiers.h:1333
Player & i_player
Definition: GridNotifiers.h:45
bool IsInPhase(uint32 phase) const
Definition: Object.h:462
void operator()(Player *p)
Definition: GridNotifiersImpl.h:589
uint32 i_entry
Definition: GridNotifiers.h:1180
WorldObject const * _searcher
Definition: GridNotifiers.h:242
uint32 entry
Definition: GameObject.h:36
void Visit(PlayerMapType &m)
Definition: GridNotifiers.h:257
bool IsInRange(float x, float y, float z, float radius) const
Definition: GameObject.cpp:1887
AnyUnitInObjectRangeCheck(WorldObject const *obj, float range)
Definition: GridNotifiers.h:888
WorldObjectSpellTargetCheck i_check
Definition: GridNotifiers.h:608
Unit const * i_funit
Definition: GridNotifiers.h:919
bool IsVisible() const
Definition: Unit.cpp:10363
Definition: GridNotifiers.h:1265
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:470
~LocalizedPacketListDo()
Definition: GridNotifiers.h:1425
PlayerListSearcher(WorldObject const *searcher, std::list< Player * > &objects, Check &check)
Definition: GridNotifiers.h:516
WorldObject const * _searcher
Definition: GridNotifiers.h:446
WorldObject const * i_obj
Definition: GridNotifiers.h:918
WorldObject *& i_object
Definition: GridNotifiers.h:179
VisibleNotifier(Player &player)
Definition: GridNotifiers.h:50
void Visit(CorpseMapType &)
Definition: GridNotifiers.h:168
NearestPlayerInObjectRangeCheck(WorldObject const *obj, float range)
Definition: GridNotifiers.h:1212
std::vector< WorldPackets::Packet * > i_data_cache
Definition: GridNotifiers.h:1414
WorldObjectLastSearcher(WorldObject const *searcher, WorldObject *&result, Check &check, uint32 mapTypeMask=GRID_MAP_TYPE_MASK_ALL)
Definition: GridNotifiers.h:204
bool operator()(WorldObject *object) const
Definition: GridNotifiers.h:1385
iterator begin()
Definition: GridRefManager.h:36
Creature const * me
Definition: GridNotifiers.h:1028
TypeID
Definition: ObjectGuid.h:27
bool operator()(Player *player)
Definition: GridNotifiers.h:1287
WorldObject const * _obj
Definition: GridNotifiers.h:1204
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:365
Definition: SharedDefines.h:2090
Check & i_check
Definition: GridNotifiers.h:380
bool operator()(Unit *unit)
Definition: GridNotifiers.h:1269
bool operator()(NOT_INTERESTED *)
Definition: GridNotifiers.h:605
Definition: GridNotifiers.h:393
Unit const *const i_searchObj
Definition: GridNotifiers.h:592
bool i_playerOnly
Definition: GridNotifiers.h:1030
GameObjectWorker(WorldObject const *searcher, Functor &func)
Definition: GridNotifiers.h:355
Definition: GridNotifiers.h:428
bool operator()(Unit *u)
Definition: GridNotifiers.h:862
uint32 i_mapTypeMask
Definition: GridNotifiers.h:181
void Visit(CorpseMapType &m)
Definition: GridNotifiers.h:122
AIRelocationNotifier(Unit &unit)
Definition: GridNotifiers.h:101
Definition: GridNotifiers.h:647
CreatureLastSearcher(WorldObject const *searcher, Creature *&result, Check &check)
Definition: GridNotifiers.h:450
float m_range
Definition: GridNotifiers.h:1029
void Respawn(bool force=false)
Definition: Creature.cpp:1697
AnyAssistCreatureInRangeCheck(Unit *funit, Unit *enemy, float range)
Definition: GridNotifiers.h:1101
void operator()(Corpse *) const
Definition: GridNotifiers.h:620
float GetLastRange() const
Definition: GridNotifiers.h:1061
SpellInfo const * i_spellInfo
Definition: GridNotifiers.h:607
Unit & i_unit
Definition: GridNotifiers.h:99
bool operator()(GameObject *go)
Definition: GridNotifiers.h:720
bool isSpawned() const
Definition: GameObject.h:951
WorldObject const * _searcher
Definition: GridNotifiers.h:309
DelayedUnitRelocation(Cell &c, CellCoord &pair, Map &map, float radius)
Definition: GridNotifiers.h:90
bool i_targetForPlayer
Definition: GridNotifiers.h:952
PlayerRelocationNotifier(Player &player)
Definition: GridNotifiers.h:68
const WorldObject * m_pObject
Definition: GridNotifiers.h:1278
Definition: ObjectGuid.h:33
NearestGameObjectEntryInObjectRangeCheck(WorldObject const &obj, uint32 entry, float range)
Definition: GridNotifiers.h:695
bool operator()(WorldObject *unit) const
Definition: GridNotifiers.h:1365
Check & i_check
Definition: GridNotifiers.h:311
void Visit(GridRefManager< T > &)
Definition: GridNotifiers.h:79
GameobjectTypes GetGoType() const
Definition: GameObject.h:964
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:556
bool _useLOS
Definition: GridNotifiers.h:1094
float i_range
Definition: GridNotifiers.h:1228
VisibleChangesNotifier(WorldObject &object)
Definition: GridNotifiers.h:59
void Visit(PlayerMapType &m)
Definition: GridNotifiersImpl.h:520
Unit const * unit
Definition: GridNotifiers.h:1297
NearestAttackableUnitInObjectRangeCheck(WorldObject const *obj, Unit const *funit, float range)
Definition: GridNotifiers.h:905
bool IsTotem() const
Definition: Unit.h:1405
PlayerDistWorker(WorldObject const *searcher, float _dist, Do &_do)
Definition: GridNotifiers.h:566
float GetLastRange() const
Definition: GridNotifiers.h:705
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:405
bool operator()(Unit *u)
Definition: GridNotifiers.h:993
Definition: GridNotifiers.h:43
Unit * GetOwner() const
Definition: Unit.cpp:7542
void Visit(DynamicObjectMapType &m)
Definition: GridNotifiers.h:283
void Visit(GameObjectMapType &m)
Definition: GridNotifiersImpl.h:381
bool operator()(GameObject *go)
Definition: GridNotifiers.h:651
#define TC_GAME_API
Definition: Define.h:134
Definition: GridNotifiers.h:1283
WorldObject const & i_obj
Definition: GridNotifiers.h:1179
Check & i_check
Definition: GridNotifiers.h:529
void Visit(CorpseMapType &m)
Definition: GridNotifiers.h:274
void Visit(PlayerMapType &)
Definition: GridNotifiers.h:167
float _difference
Definition: GridNotifiers.h:1372
Check & i_check
Definition: GridNotifiers.h:342
bool _raid
Definition: GridNotifiers.h:882
void Visit(GridRefManager< T > &m)
Definition: GridNotifiers.h:70
bool IsHostileTo(Unit const *unit) const
Definition: Unit.cpp:7165
float i_dist
Definition: GridNotifiers.h:563
Definition: GridNotifiers.h:239
float i_range
Definition: GridNotifiers.h:956
bool HasUnitState(const uint32 f) const
Definition: Unit.h:1395
WorldObjectWorker(WorldObject const *searcher, Do const &_do, uint32 mapTypeMask=GRID_MAP_TYPE_MASK_ALL)
Definition: GridNotifiers.h:245
WorldObject & i_object
Definition: GridNotifiers.h:57
float i_range
Definition: GridNotifiers.h:663
void Visit(GridRefManager< T > &)
Definition: GridNotifiers.h:92
WorldObject * i_source
Definition: GridNotifiers.h:128
float i_distSq
Definition: GridNotifiers.h:130
void Visit(CreatureMapType &m)
Definition: GridNotifiersImpl.h:392
std::set< Unit * > i_visibleNow
Definition: GridNotifiers.h:47
GuidUnorderedSet vis_guids
Definition: GridNotifiers.h:48
Unit *const i_enemy
Definition: GridNotifiers.h:1154
Definition: GridNotifiers.h:1034
WorldObjectSearcher(WorldObject const *searcher, WorldObject *&result, Check &check, uint32 mapTypeMask=GRID_MAP_TYPE_MASK_ALL)
Definition: GridNotifiers.h:183
CallOfHelpCreatureInRangeDo(Unit *funit, Unit *enemy, float range)
Definition: GridNotifiers.h:963
uint32 i_timeDiff
Definition: GridNotifiers.h:109
bool operator()(Unit *u)
Definition: GridNotifiers.h:764
Definition: GridDefines.h:74
AllCreaturesOfEntryInRange(const WorldObject *object, uint32 entry, float maxRange)
Definition: GridNotifiers.h:1268
std::unordered_set< ObjectGuid > GuidUnorderedSet
Definition: ObjectGuid.h:336
uint32 GetEntry() const
Definition: Object.h:107
Unit *const i_enemy
Definition: GridNotifiers.h:1125
uint32 i_focusId
Definition: GridNotifiers.h:643
SpellTargetCheckTypes
Definition: SpellInfo.h:118
Unit *const i_funit
Definition: GridNotifiers.h:986
Player session in the World.
Definition: WorldSession.h:882
NearestHostileUnitInAggroRangeCheck(Creature const *creature, bool useLOS=false)
Definition: GridNotifiers.h:1072
struct GameObjectTemplate::@221::@248 fishingHole
Definition: ObjectGuid.h:189
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:506
float i_range
Definition: GridNotifiers.h:837
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:489
iterator end()
Definition: GridRefManager.h:37
WorldObject const * i_obj
Definition: GridNotifiers.h:897
Check & i_check
Definition: GridNotifiers.h:463
struct GameObjectTemplate::@221::@231 spellFocus
std::vector< WorldPacketList > i_data_cache
Definition: GridNotifiers.h:1435
WorldObject const * _searcher
Definition: GridNotifiers.h:221
bool operator()(Unit *u)
Definition: GridNotifiers.h:889
Unit const * i_unit
Definition: GridNotifiers.h:642
float i_range
Definition: GridNotifiers.h:898
Check & i_check
Definition: GridNotifiers.h:201
Definition: ObjectGuid.h:35
Player *& i_object
Definition: GridNotifiers.h:528
T check(T value)
Definition: format.h:305
Creature *& i_object
Definition: GridNotifiers.h:431
void Visit(PlayerMapType &m)
Definition: GridNotifiersImpl.h:280
bool CanSeeOrDetect(WorldObject const *obj, bool ignoreStealth=false, bool distanceCheck=false, bool checkAlert=false) const
Definition: Object.cpp:1940
bool IsInRaidWith(Unit const *unit) const
Definition: Unit.cpp:14391
Definition: GridNotifiers.h:126
bool operator()(Unit *u)
Definition: GridNotifiers.h:801
uint32 entry
Definition: GridNotifiers.h:1314
uint32 GetHealth() const
Definition: Unit.h:1426
Definition: GridNotifiers.h:797
Definition: GridNotifiers.h:1357
std::list< Creature * > & i_objects
Definition: GridNotifiers.h:462
Definition: GridNotifiers.h:1209
~LocalizedPacketDo()
Definition: GridNotifiers.h:1405
WorldObject const * _searcher
Definition: GridNotifiers.h:378
AllFriendlyCreaturesInGrid(Unit const *obj)
Definition: GridNotifiers.h:1236
CellCoord & p
Definition: GridNotifiers.h:88
uint32 i_entry
Definition: GridNotifiers.h:708
uint32 i_timeDiff
Definition: GridNotifiers.h:164
void Visit(GameObjectMapType &m)
Definition: GridNotifiers.h:358
WorldObjectListSearcher(WorldObject const *searcher, std::list< WorldObject * > &objects, Check &check, uint32 mapTypeMask=GRID_MAP_TYPE_MASK_ALL)
Definition: GridNotifiers.h:225
AnyAoETargetUnitInObjectRangeCheck(WorldObject const *obj, Unit const *funit, float range)
Definition: GridNotifiers.h:929
void Visit(CreatureMapType &m)
Definition: GridNotifiersImpl.h:478
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:422
virtual void AttackStart(Unit *)
Definition: UnitAI.cpp:29
bool operator()(GameObject *go)
Definition: GridNotifiers.h:1252
GameobjectTypes i_type
Definition: GridNotifiers.h:732
bool isCreature
Definition: GridNotifiers.h:100
Definition: WorldPacket.h:26
Definition: GridNotifiers.h:218
bool isTargetableForAttack(bool checkFakeDeath=true) const
Definition: Unit.cpp:9987
bool fuzzyEq(double a, double b)
Definition: g3dmath.h:857
void Visit(CreatureMapType &m)
Definition: GridNotifiers.h:482
Player const * skipped_receiver
Definition: GridNotifiers.h:132
uint32 type
Definition: GameObject.h:37
Unit const * i_obj
Definition: GridNotifiers.h:774
Unit const * i_funit
Definition: GridNotifiers.h:810
Definition: GridNotifiers.h:1317
Definition: GridNotifiers.h:197
void operator()(WorldObject *) const
Definition: GridNotifiers.h:619
Definition: GridDefines.h:73
void Visit(GameObjectMapType &m)
Definition: GridNotifiersImpl.h:368
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:334
WorldObject * _baseObject
Definition: GridNotifiers.h:1371
bool IsCharmed() const
Definition: Unit.h:1742
float i_range
Definition: GridNotifiers.h:1182
void Visit(GridRefManager< NOT_INTERESTED > &)
Definition: GridNotifiers.h:235
bool operator()(Creature *u)
Definition: GridNotifiers.h:1168
float _range
Definition: GridNotifiers.h:881
void Visit(GridRefManager< SKIP > &)
Definition: GridNotifiers.h:146
float GetLastRange() const
Definition: GridNotifiers.h:682
WorldObject const * _searcher
Definition: GridNotifiers.h:497
float i_range
Definition: GridNotifiers.h:793
WorldObject const * _searcher
Definition: GridNotifiers.h:543
void Visit(AreaTriggerMapType &m)
Definition: GridNotifiers.h:292
bool CanStartAttack(Unit const *u, bool force) const
Definition: Creature.cpp:1525
Creature const * me
Definition: GridNotifiers.h:1063
Unit const * i_obj
Definition: GridNotifiers.h:755
Definition: GridNotifiers.h:692