AzerothCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
Acore::PlayerListSearcher< Check > Struct Template Reference

#include "GridNotifiers.h"

Inheritance diagram for Acore::PlayerListSearcher< Check >:
Acore::ContainerInserter< Player * >

Public Member Functions

template<typename Container >
 PlayerListSearcher (WorldObject const *searcher, Container &container, Check &check)
 
void Visit (PlayerMapType &m)
 
template<class NOT_INTERESTED >
void Visit (GridRefMgr< NOT_INTERESTED > &)
 

Public Attributes

uint32 i_phaseMask
 
Check & i_check
 

Additional Inherited Members

- Protected Member Functions inherited from Acore::ContainerInserter< Player * >
 ContainerInserter (T &ref_)
 
void Insert (Player * type)
 

Detailed Description

template<class Check>
struct Acore::PlayerListSearcher< Check >

Constructor & Destructor Documentation

◆ PlayerListSearcher()

template<class Check >
template<typename Container >
Acore::PlayerListSearcher< Check >::PlayerListSearcher ( WorldObject const *  searcher,
Container container,
Check &  check 
)
inline
531 : ContainerInserter<Player*>(container),
532 i_phaseMask(searcher->GetPhaseMask()), i_check(check) { }
Check & i_check
Definition: GridNotifiers.h:527
uint32 i_phaseMask
Definition: GridNotifiers.h:526

Member Function Documentation

◆ Visit() [1/2]

template<class Check >
template<class NOT_INTERESTED >
void Acore::PlayerListSearcher< Check >::Visit ( GridRefMgr< NOT_INTERESTED > &  )
inline
536{}

◆ Visit() [2/2]

template<class Check >
void Acore::PlayerListSearcher< Check >::Visit ( PlayerMapType m)
479{
480 for (PlayerMapType::iterator itr = m.begin(); itr != m.end(); ++itr)
481 if (itr->GetSource()->InSamePhase(i_phaseMask))
482 if (i_check(itr->GetSource()))
483 Insert(itr->GetSource());
484}
Definition: LinkedList.h:139
iterator begin()
Definition: GridRefMgr.h:35
iterator end()
Definition: GridRefMgr.h:36
void Insert(Player * type)
Definition: GridNotifiers.h:191

References GridRefMgr< OBJECT >::begin(), GridRefMgr< OBJECT >::end(), and Acore::Insert().

Member Data Documentation

◆ i_check

template<class Check >
Check& Acore::PlayerListSearcher< Check >::i_check

◆ i_phaseMask

template<class Check >
uint32 Acore::PlayerListSearcher< Check >::i_phaseMask