#include <MenuState.h>
|
| | MenuState (StateManager &context) |
| | This State determines the main Pacman game menu.
|
| void | handleInput (const sf::Event::KeyEvent &keyPressed) override |
| | Will start the game when specific keys are a pressed. Also handles usernames.
|
| void | resized () override |
| | Will resize the contents of the Menu state.
|
| void | update (double dt) override |
| | Update the MenuState, is used for UI animations.
|
| void | render () override |
| | Renders the menu state.
|
| virtual | ~State ()=default |
◆ MenuState()
This State determines the main Pacman game menu.
- Parameters
-
◆ handleInput()
| void MenuState::handleInput |
( |
const sf::Event::KeyEvent & | keyPressed | ) |
|
|
overridevirtual |
Will start the game when specific keys are a pressed. Also handles usernames.
In MenuState you have to set a username. The keys a through z, A through Z, _ and - will result in their respective letters getting appended to your username.
- Warning
- Username changing has not been tested with AZERTY
- Parameters
-
- Warning
- Username changing has not been tested with AZERTY keyboard layouts.
Implements State.
◆ render()
| void MenuState::render |
( |
| ) |
|
|
overridevirtual |
Renders the menu state.
Implements State.
◆ resized()
| void MenuState::resized |
( |
| ) |
|
|
overridevirtual |
Will resize the contents of the Menu state.
Implements State.
◆ update()
| void MenuState::update |
( |
double | dt | ) |
|
|
overridevirtual |
Update the MenuState, is used for UI animations.
- Parameters
-
Implements State.
The documentation for this class was generated from the following files: