SDL SPOOKY PLATFORMER ENGINE
0.2.0
An implementation of a platformer using sdl, implemented using an entity component system and efficient collision management.
|
#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 |
Singleton manager for the state of the game
GameManager::~GameManager | ( | ) |
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.
|
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 | ( | ) |
bool GameManager::enemiesFrozen |
Return whether all enemies are frozen.
int GameManager::lastFrozen |