Emergency 20 Dokumentation  4.2.0
em5::HealthSystem Class Reference

Health system. More...

#include <HealthSystem.h>

Inheritance diagram for em5::HealthSystem:
qsf::System

Public Member Functions

 HealthSystem ()
 Default constructor. More...
 
virtual ~HealthSystem ()
 Destructor. More...
 
const InjurygetInjuryById (const qsf::StringHash &id) const
 
const DiagnosisgetDiagnosisById (const qsf::StringHash &id) const
 
const MedicalCaregetMedicalCareById (const qsf::StringHash &id) const
 
InjuryManagergetInjuryManager () const
 Get the injury manager instance, do not delete it. More...
 
DiagnosisManagergetDiagnosisManager () const
 Get the diagnosis manager instance, do not delete it. More...
 
MedicalCareManagergetMedicalCareManager () const
 Get the medical care manager instance, do not delete it. More...
 
bool getHealthSimulationActive () const
 
void setHealthSimulationActive (bool healthSimulationEnabled)
 
float getEnergyLossMultiplier () const
 
void setEnergyLossMultiplier (float multiplier)
 
virtual const char * getName () const override
 Get the name of the system. More...
 
virtual bool onStartup (bool serverMode) override
 Startup the system. More...
 
virtual void onShutdown () override
 Shutdown the system. More...
 
- Public Member Functions inherited from qsf::System
virtual ~System ()
 Destructor. More...
 

Additional Inherited Members

- Protected Member Functions inherited from qsf::System
 System ()
 Default constructor. More...
 

Detailed Description

Health system.

Constructor & Destructor Documentation

em5::HealthSystem::HealthSystem ( )

Default constructor.

virtual em5::HealthSystem::~HealthSystem ( )
virtual

Destructor.

Member Function Documentation

const Diagnosis* em5::HealthSystem::getDiagnosisById ( const qsf::StringHash id) const
DiagnosisManager & em5::HealthSystem::getDiagnosisManager ( ) const
inline

Get the diagnosis manager instance, do not delete it.

float em5::HealthSystem::getEnergyLossMultiplier ( ) const
bool em5::HealthSystem::getHealthSimulationActive ( ) const
inline
const Injury* em5::HealthSystem::getInjuryById ( const qsf::StringHash id) const
InjuryManager & em5::HealthSystem::getInjuryManager ( ) const
inline

Get the injury manager instance, do not delete it.

const MedicalCare* em5::HealthSystem::getMedicalCareById ( const qsf::StringHash id) const
MedicalCareManager & em5::HealthSystem::getMedicalCareManager ( ) const
inline

Get the medical care manager instance, do not delete it.

const char * em5::HealthSystem::getName ( ) const
inlineoverridevirtual

Get the name of the system.

Returns
Null terminated ASCII name of the system, never a null pointer, do not manipulate or destroy the returned name

Implements qsf::System.

virtual void em5::HealthSystem::onShutdown ( )
overridevirtual

Shutdown the system.

Note
  • This method is only called case "onStartup()" returned successfully

Implements qsf::System.

virtual bool em5::HealthSystem::onStartup ( bool  serverMode)
overridevirtual

Startup the system.

Parameters
[in]serverMode"true" if the system should start in server mode, else "false"
Returns
"true" if all went fine, else "false"
Note
  • Server mode means that e.g. there's no need for audio & visual stuff because there's no display or sound hardware in the first place

Implements qsf::System.

void em5::HealthSystem::setEnergyLossMultiplier ( float  multiplier)
void em5::HealthSystem::setHealthSimulationActive ( bool  healthSimulationEnabled)

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