This class manages the inputs of our game as a singleton.
More...
#include <InputManager.hpp>
|
std::map< Input, bool > | inputHeld |
| Array of inputs that are currently held down.
|
|
std::map< Input, bool > | inputPressed |
| Array of inputs that were just pressed.
|
|
bool | quitFlag |
| Whether or not the game should quit.
|
|
Vector2 | mousePos |
| Location of the last mouse event.
|
|
This class manages the inputs of our game as a singleton.
◆ GetActionHeld()
bool InputManager::GetActionHeld |
( |
Input |
action | ) |
|
|
static |
Gets whether or not the given input is held.
- Returns
- Whether or not the given input is held
- Parameters
-
action | The input to be checked |
◆ GetActionPressed()
bool InputManager::GetActionPressed |
( |
Input |
action | ) |
|
|
static |
Gets whether or not the given input was just pressed.
- Returns
- Whether or not the given input was just pressed
- Parameters
-
action | The input to be checked |
◆ GetMousePos()
Vector2 InputManager::GetMousePos |
( |
| ) |
|
|
static |
Gets the position of the most recent mouse event.
- Returns
- the position of the most recent mouse event.
◆ ShouldQuit()
bool InputManager::ShouldQuit |
( |
| ) |
const |
Gets whether or not the game should quit.
- Returns
- Whether or not the game should quit
The documentation for this class was generated from the following files: