2018-10-07 03:42:33 +00:00
|
|
|
#pragma once
|
2016-12-30 06:37:01 +00:00
|
|
|
|
2019-09-28 02:53:03 +00:00
|
|
|
#include <optional>
|
|
|
|
|
|
|
|
#include "Runtime/CToken.hpp"
|
|
|
|
#include "Runtime/RetroTypes.hpp"
|
|
|
|
#include "Runtime/Graphics/Shaders/CColoredQuadFilter.hpp"
|
2021-06-07 01:40:16 +00:00
|
|
|
#include "Runtime/GuiSys/CGuiFrame.hpp"
|
2016-12-30 06:37:01 +00:00
|
|
|
|
2021-04-10 08:42:06 +00:00
|
|
|
namespace metaforce {
|
2018-02-04 06:46:47 +00:00
|
|
|
struct CFinalInput;
|
2016-12-30 06:37:01 +00:00
|
|
|
class CGuiTableGroup;
|
|
|
|
class CGuiTextPane;
|
2019-01-23 07:52:19 +00:00
|
|
|
class CGuiWidget;
|
2016-12-30 06:37:01 +00:00
|
|
|
|
2018-12-08 05:30:43 +00:00
|
|
|
namespace MP1 {
|
2016-12-30 06:37:01 +00:00
|
|
|
|
2018-12-08 05:30:43 +00:00
|
|
|
enum class EQuitType { QuitGame, ContinueFromLastSave, SaveProgress, QuitNESMetroid, ContinuePlaying };
|
2016-12-30 06:37:01 +00:00
|
|
|
|
2018-12-08 05:30:43 +00:00
|
|
|
enum class EQuitAction { None, Yes, No };
|
|
|
|
|
|
|
|
class CQuitGameScreen {
|
|
|
|
EQuitType x0_type;
|
|
|
|
TLockedToken<CGuiFrame> x4_frame;
|
|
|
|
CGuiFrame* x10_loadedFrame = nullptr;
|
|
|
|
CGuiTableGroup* x14_tablegroup_quitgame = nullptr;
|
|
|
|
EQuitAction x18_action = EQuitAction::None;
|
2019-06-12 02:05:17 +00:00
|
|
|
std::optional<CColoredQuadFilter> m_blackScreen;
|
2018-12-08 05:30:43 +00:00
|
|
|
void SetColors();
|
2016-12-30 06:37:01 +00:00
|
|
|
|
|
|
|
public:
|
2018-12-08 05:30:43 +00:00
|
|
|
void FinishedLoading();
|
2019-01-23 07:52:19 +00:00
|
|
|
void OnWidgetMouseUp(CGuiWidget* widget, bool cancel);
|
2018-12-08 05:30:43 +00:00
|
|
|
void DoSelectionChange(CGuiTableGroup* caller, int oldSel);
|
|
|
|
void DoAdvance(CGuiTableGroup* caller);
|
|
|
|
EQuitAction Update(float dt);
|
|
|
|
void Draw();
|
|
|
|
void ProcessUserInput(const CFinalInput& input);
|
2020-03-31 03:52:22 +00:00
|
|
|
explicit CQuitGameScreen(EQuitType type);
|
2016-12-30 06:37:01 +00:00
|
|
|
};
|
|
|
|
|
2018-12-08 05:30:43 +00:00
|
|
|
} // namespace MP1
|
2021-04-10 08:42:06 +00:00
|
|
|
} // namespace metaforce
|