Creates a StateManager object. Creates a StateManager object to be inherited. DISCLAIMER - This code is from my PGG SDL Assignment.
More...
#include <stateManager.h>
Creates a StateManager object. Creates a StateManager object to be inherited. DISCLAIMER - This code is from my PGG SDL Assignment.
StateManager::StateManager |
( |
| ) |
|
StateManager::~StateManager |
( |
| ) |
|
void StateManager::addState |
( |
State * |
state | ) |
|
Adds a new state Adds a new state to the current stack of states
- Parameters
-
void StateManager::changeState |
( |
State * |
state | ) |
|
void StateManager::draw |
( |
| ) |
|
Draws the current State The draw function that will allow the equivalent draw function to run in the current State
bool StateManager::input |
( |
| ) |
|
Handles the user input The input function that will allow the equivalent input function to run in the current State
- Returns
- bool if false then quit the application
void StateManager::removeLastState |
( |
| ) |
|
Removes the last State from the vector
void StateManager::update |
( |
float |
deltaTime | ) |
|
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 |
std::vector<State*> StateManager::currentStates |
|
private |
the current states that are in use
The documentation for this class was generated from the following files: