30 lines
594 B
C++
30 lines
594 B
C++
#pragma once
|
|
|
|
#include "gui/state.h"
|
|
#include <SFML/Graphics/RenderWindow.hpp>
|
|
|
|
class Group;
|
|
|
|
class MainMenu : public GUIState
|
|
{
|
|
public:
|
|
|
|
struct Callbacks
|
|
{
|
|
std::function<void(void)> onAppendGameState;
|
|
};
|
|
|
|
explicit MainMenu(sf::RenderWindow& game_window, Callbacks&& callbacks);
|
|
virtual void input(const sf::Event& event) override;
|
|
virtual void update() override;
|
|
virtual void draw() const override;
|
|
|
|
virtual void enter() override;
|
|
virtual void leave() override;
|
|
|
|
private:
|
|
std::shared_ptr<Group> _buttons;
|
|
sf::RenderWindow& _game_window;
|
|
};
|
|
|