Retro exit modal styling and shortcuts

This commit is contained in:
2025-11-22 19:56:07 +01:00
parent aed1cb62e7
commit c0bee9296a
7 changed files with 389 additions and 239 deletions

View File

@ -13,23 +13,24 @@ public:
private:
enum class Field : int {
PlayerName = 0,
Fullscreen = 1,
Back = 2
Fullscreen = 0,
Music = 1,
SoundFx = 2,
Back = 3
};
static constexpr int MAX_NAME_LENGTH = 12;
Field m_selectedField = Field::PlayerName;
Field m_selectedField = Field::Fullscreen;
double m_cursorTimer = 0.0;
bool m_cursorVisible = true;
void moveSelection(int delta);
void activateSelection();
void handleNameInput(const SDL_Event& e);
void addCharacter(char c);
void removeCharacter();
void toggleFullscreen();
void toggleMusic();
void toggleSoundFx();
void exitToMenu();
const std::string& playerName() const;
bool isFullscreen() const;
bool isMusicEnabled() const;
bool isSoundFxEnabled() const;
};