Pyrogenesis HEAD
Pyrogenesis, a RTS Engine
anonymous_namespace{CCmpRangeManager.cpp}::EntityDistanceOrdering Class Reference

Functor for sorting entities by distance from a source point. More...

Collaboration diagram for anonymous_namespace{CCmpRangeManager.cpp}::EntityDistanceOrdering:

Public Member Functions

 EntityDistanceOrdering (const EntityMap< EntityData > &entities, const CFixedVector2D &source)
 
 EntityDistanceOrdering (const EntityDistanceOrdering &entity)=default
 
bool operator() (entity_id_t a, entity_id_t b) const
 

Public Attributes

const EntityMap< EntityData > & m_EntityData
 
CFixedVector2D m_Source
 

Private Member Functions

EntityDistanceOrderingoperator= (const EntityDistanceOrdering &)
 

Detailed Description

Functor for sorting entities by distance from a source point.

It must only be passed entities that are in 'entities' and are currently in the world.

Constructor & Destructor Documentation

◆ EntityDistanceOrdering() [1/2]

anonymous_namespace{CCmpRangeManager.cpp}::EntityDistanceOrdering::EntityDistanceOrdering ( const EntityMap< EntityData > &  entities,
const CFixedVector2D source 
)
inline

◆ EntityDistanceOrdering() [2/2]

anonymous_namespace{CCmpRangeManager.cpp}::EntityDistanceOrdering::EntityDistanceOrdering ( const EntityDistanceOrdering entity)
default

Member Function Documentation

◆ operator()()

bool anonymous_namespace{CCmpRangeManager.cpp}::EntityDistanceOrdering::operator() ( entity_id_t  a,
entity_id_t  b 
) const
inline

◆ operator=()

EntityDistanceOrdering & anonymous_namespace{CCmpRangeManager.cpp}::EntityDistanceOrdering::operator= ( const EntityDistanceOrdering )
private

Member Data Documentation

◆ m_EntityData

const EntityMap<EntityData>& anonymous_namespace{CCmpRangeManager.cpp}::EntityDistanceOrdering::m_EntityData

◆ m_Source

CFixedVector2D anonymous_namespace{CCmpRangeManager.cpp}::EntityDistanceOrdering::m_Source

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