void SetOnSettings(std::function< void()> onSettings)
Set callback triggered when the Settings button is clicked.
void SetScreenSize(float width, float height)
Set screen size for layout calculations.
~MainMenu() override=default
std::function< void()> _onQuit
void SetProfileName(const std::string &name)
Update the text of the Profile button (e.g. "GUEST" -> "PlayerName").
void SetOnSelectServer(std::function< void()> onSelectServer)
Set callback triggered when the Select Server button is clicked.
void Show() override
Show the menu and play the open sound effect.
std::function< void()> _onPlay
std::shared_ptr< UI::IButton > _profileButton
void OnSelectServerClicked()
std::function< void()> _onProfile
std::function< void()> _onSettings
void SetOnPlay(std::function< void()> onPlay)
Set callback triggered when the Play button is clicked.
void SetOnQuit(std::function< void()> onQuit)
Set callback triggered when the Quit button is clicked.
void Initialize() override
Initialize menu (must be implemented by derived classes).
void SetOnProfile(std::function< void()> onProfile)
Set callback triggered when the Profile/Guest button is clicked.
std::shared_ptr< UI::IButton > _selectServerButton
std::function< void()> _onSelectServer