Creates a StateManager object. Creates a StateManager object to be inherited. DISCLAMER - This is a modified version of the state handling system that I used in my PGG SDL assignment. This version is different however it is similar so I thought that I should mention it.
More...
#include <stateManager.h>
Creates a StateManager object. Creates a StateManager object to be inherited. DISCLAMER - This is a modified version of the state handling system that I used in my PGG SDL assignment. This version is different however it is similar so I thought that I should mention it.
Definition at line 11 of file stateManager.h.
StateManager::StateManager |
( |
| ) |
|
StateManager::~StateManager |
( |
| ) |
|
void StateManager::addState |
( |
State * |
| ) |
|
Adds a new state Adds a new state to the current stack of states
- Parameters
-
void StateManager::changeState |
( |
State * |
| ) |
|
void StateManager::drawSprites |
( |
| ) |
|
Draws the current State Sprites without alpha The draw function that will allow the equivalent draw function to run in the current State
void StateManager::drawSpritesWithAlpha |
( |
| ) |
|
Draws the current State Sprites with alpha The draw function that will allow the equivalent draw function to run in the current State
std::string StateManager::getName |
( |
| ) |
|
getter # the name of the current State
- Returns
- std::string the name of the state
void StateManager::removeLastState |
( |
| ) |
|
Removes the last State from the vector
bool StateManager::runProgram |
( |
| ) |
|
Getter # runCheck
- Returns
- bool if the program should run.
void StateManager::update |
( |
float |
, |
|
|
float |
, |
|
|
float |
|
|
) |
| |
Updates the current State The update function that will allow the equivalent update function to run in the current State
- Parameters
-
float | the delta time for use within the update function |
float | the x touch location |
float | the y touch location |
std::vector<State*> StateManager::currentStates |
|
private |
the current states that are in use
Definition at line 15 of file stateManager.h.
The documentation for this class was generated from the following file: