Major refactoring for game menu

This commit is contained in:
Vladislav Khorev committed 2026-02-22 19:50:13 +03:00
1 parent 5b57696acf
commit b59a10b7e6
8 files changed
+142 -103

No files matched your search

+8 -4
View File
@@ -7,21 +7,21 @@
namespace ZL {
extern const char* CONST_ZIP_FILE;
extern bool g_exitBgAnimating;
extern bool firePressed;
//extern bool g_exitBgAnimating;
class MenuManager
{
protected:
Renderer& renderer;
bool uiGameOverShown = false;
std::shared_ptr<UiNode> uiSavedRoot;
std::shared_ptr<UiNode> gameOverSavedRoot;
std::shared_ptr<UiNode> settingsSavedRoot;
std::shared_ptr<UiNode> multiplayerSavedRoot;
public:
bool uiGameOverShown = false;
bool g_exitBgAnimating = false;
UiManager uiManager;
MenuManager(Renderer& iRenderer);
@@ -32,6 +32,10 @@ namespace ZL {
std::function<void()> onRestartPressed;
std::function<void(float)> onVelocityChanged;
std::function<void()> onFirePressed;
std::function<void()> onSingleplayerPressed;
std::function<void()> onMultiplayerPressed;
};
};