TrinityCore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Trinity::PlayerDistWorker< Do > Struct Template Reference

#include <GridNotifiers.h>

Public Member Functions

 PlayerDistWorker (WorldObject const *searcher, float _dist, Do &_do)
 
void Visit (PlayerMapType &m)
 
template<class NOT_INTERESTED >
void Visit (GridRefManager< NOT_INTERESTED > &)
 

Public Attributes

WorldObject consti_searcher
 
float i_dist
 
Do & i_do
 

Constructor & Destructor Documentation

template<class Do >
Trinity::PlayerDistWorker< Do >::PlayerDistWorker ( WorldObject const searcher,
float  _dist,
Do &  _do 
)
inline
567  : i_searcher(searcher), i_dist(_dist), i_do(_do) { }
WorldObject const * i_searcher
Definition: GridNotifiers.h:562
Do & i_do
Definition: GridNotifiers.h:564
float i_dist
Definition: GridNotifiers.h:563

Member Function Documentation

template<class Do >
void Trinity::PlayerDistWorker< Do >::Visit ( PlayerMapType m)
inline
570  {
571  for (PlayerMapType::iterator itr=m.begin(); itr != m.end(); ++itr)
572  if (itr->GetSource()->IsInPhase(i_searcher) && itr->GetSource()->IsWithinDist(i_searcher, i_dist))
573  i_do(itr->GetSource());
574  }
WorldObject const * i_searcher
Definition: GridNotifiers.h:562
Do & i_do
Definition: GridNotifiers.h:564
Definition: LinkedList.h:141
iterator begin()
Definition: GridRefManager.h:36
float i_dist
Definition: GridNotifiers.h:563
iterator end()
Definition: GridRefManager.h:37

+ Here is the call graph for this function:

template<class Do >
template<class NOT_INTERESTED >
void Trinity::PlayerDistWorker< Do >::Visit ( GridRefManager< NOT_INTERESTED > &  )
inline
576 { }

Member Data Documentation

template<class Do >
float Trinity::PlayerDistWorker< Do >::i_dist
template<class Do >
Do& Trinity::PlayerDistWorker< Do >::i_do
template<class Do >
WorldObject const* Trinity::PlayerDistWorker< Do >::i_searcher

The documentation for this struct was generated from the following file: