SDL SPOOKY PLATFORMER ENGINE  0.2.0
An implementation of a platformer using sdl, implemented using an entity component system and efficient collision management.
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
GameManager Class Reference

#include <GameManager.hpp>

Public Member Functions

 ~GameManager ()
 
void init ()
 Initialize the singleton GameManager. More...
 
void shutdown ()
 Close the game and cleanup references. More...
 
void Update ()
 
bool IsGameOver ()
 Return whether the game has ended. More...
 
void GameLost ()
 If the game is not already lost, it is ended when this function is called. More...
 
unsigned int GetMSElapsed ()
 Return the amount of time that this game has been running for. More...
 
void FreezeEnemies ()
 Freezes all enemies in the game. More...
 
void UnfreezeEnemies ()
 Unfreezes all enemies in the game. More...
 

Static Public Member Functions

static GameManager & getInstance ()
 Return the singleton to represent the state of the game. More...
 

Public Attributes

bool enemiesFrozen
 Return whether all enemies are frozen. More...
 
int lastFrozen
 

Detailed Description

Singleton manager for the state of the game

Constructor & Destructor Documentation

GameManager::~GameManager ( )

Member Function Documentation

void GameManager::FreezeEnemies ( )

Freezes all enemies in the game.

void GameManager::GameLost ( )

If the game is not already lost, it is ended when this function is called.

GameManager & GameManager::getInstance ( )
static

Return the singleton to represent the state of the game.

unsigned int GameManager::GetMSElapsed ( )

Return the amount of time that this game has been running for.

void GameManager::init ( )

Initialize the singleton GameManager.

bool GameManager::IsGameOver ( )

Return whether the game has ended.

void GameManager::shutdown ( )

Close the game and cleanup references.

void GameManager::UnfreezeEnemies ( )

Unfreezes all enemies in the game.

void GameManager::Update ( )

Member Data Documentation

bool GameManager::enemiesFrozen

Return whether all enemies are frozen.

int GameManager::lastFrozen

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