Emergency 20 Dokumentation  4.2.0
em5::SpawnGroupManager Class Reference

Spawn group manager. More...

#include <SpawnGroupManager.h>

Inheritance diagram for em5::SpawnGroupManager:
qsf::ElementManager< uint32, SpawnGroup > qsf::Manager

Public Member Functions

 SpawnGroupManager ()
 Default constructor. More...
virtual ~SpawnGroupManager ()
 Destructor. More...
void createStartupPopulations () const
bool isDebugShown () const
void setDebug (bool debug)
- Public Member Functions inherited from qsf::ElementManager< uint32, SpawnGroup >
 ElementManager ()
 Default constructor. More...
virtual ~ElementManager ()
 Destructor. More...
const ElementMapgetElements () const
 Return map of elements. More...
SpawnGroup * findElement (const uint32 &key) const
 Find a specific element by its key in either the element map. More...
void reserveElements (size_t numberOfElements)
 Reserve elements. More...
SpawnGroup * createElement ()
 Create a new element. More...
SpawnGroup * createElementById (const uint32 &key)
 Create a new element with an enforced given unique element identifier. More...
bool insertElement (const uint32 &key, SpawnGroup &element)
 Insert an element with an enforced given unique element identifier. More...
bool destroyElement (const uint32 &key)
 Destroy an element by its key. More...
ElementManager< uint32, SpawnGroup, detail::DirectAllocator< SpawnGroup >, ConsecutiveIdGenerator< uint32 > >::ElementMap::iterator destroyElement (typename ElementMap::iterator iterator)
 Destroy an element by iterator. More...
void destroyAllElements ()
 Destroy all elements. More...
SpawnGroup * grabElement (const uint32 &key)
 Remove an element from the element manager without destroying it. More...
uint32 generateId ()
 Generate a new, unused key. More...

Static Public Attributes

static const qsf::NamedIdentifier CIVIL_PERSONS_DEFAULT_GROUP
 "CivilPersonsDefaultGroup" spawn group name More...
static const qsf::NamedIdentifier CIVIL_VEHICLES_DEFAULT_GROUP
 "CivilVehiclesDefaultGroup" spawn group name More...

Additional Inherited Members

- Public Types inherited from qsf::ElementManager< uint32, SpawnGroup >
typedef boost::container::flat_map< uint32, SpawnGroup * > ElementMap
- Protected Member Functions inherited from qsf::ElementManager< uint32, SpawnGroup >
ElementMapgetElementsWritable ()
 Return map of elements. More...
virtual void onElementInsertion (const uint32 &key, SpawnGroup &element)
 Called whenever an element is inserted into the element map. More...
virtual void onElementRemoval (const uint32 &key, SpawnGroup &element)
 Called whenever an element is actually going to be destroyed. More...
- Protected Member Functions inherited from qsf::Manager
 Manager ()
 Default constructor. More...
virtual ~Manager ()
 Destructor. More...

Detailed Description

Spawn group manager.

Constructor & Destructor Documentation

em5::SpawnGroupManager::SpawnGroupManager ( )

Default constructor.

virtual em5::SpawnGroupManager::~SpawnGroupManager ( )


Member Function Documentation

void em5::SpawnGroupManager::createStartupPopulations ( ) const
bool em5::SpawnGroupManager::isDebugShown ( ) const
void em5::SpawnGroupManager::setDebug ( bool  debug)

Member Data Documentation

const qsf::NamedIdentifier em5::SpawnGroupManager::CIVIL_PERSONS_DEFAULT_GROUP

"CivilPersonsDefaultGroup" spawn group name

const qsf::NamedIdentifier em5::SpawnGroupManager::CIVIL_VEHICLES_DEFAULT_GROUP

"CivilVehiclesDefaultGroup" spawn group name

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