From c3ceaed444423fd2c1931aa77f37e19772f85c0b Mon Sep 17 00:00:00 2001 From: Hyper <34012267+hyperbx@users.noreply.github.com> Date: Fri, 6 Dec 2024 01:31:32 +0000 Subject: [PATCH] message_window: added button guide --- UnleashedRecomp/ui/message_window.cpp | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/UnleashedRecomp/ui/message_window.cpp b/UnleashedRecomp/ui/message_window.cpp index b29fa638..243ca611 100644 --- a/UnleashedRecomp/ui/message_window.cpp +++ b/UnleashedRecomp/ui/message_window.cpp @@ -2,6 +2,8 @@ #include "imgui_utils.h" #include #include +#include +#include #include #include #include @@ -237,6 +239,14 @@ void MessageWindow::Draw() Game_PlaySound("sys_actstg_pausecansel"); MessageWindow::Close(); } + + ButtonGuide::Open + ( + { + Button(Localise("Common_Select"), EButtonIcon::A), + Button(Localise("Common_Back"),EButtonIcon::B), + } + ); } else { @@ -253,6 +263,8 @@ void MessageWindow::Draw() if (ImGui::IsMouseHoveringRect(itemMin, itemMax, false)) g_selectedRowIndex = i; } + + ButtonGuide::Open({ Button(Localise("Common_Select"), EButtonIcon::LMB) }); } if (g_selectedRowIndex != -1 && isAccepted) @@ -309,6 +321,8 @@ bool MessageWindow::Open(std::string text, int* result, std::span b ResetSelection(); + ButtonGuide::Open({ Button(Localise("Common_Next"), g_isGameLoaded ? EButtonIcon::A : EButtonIcon::LMB) }); + Game_PlaySound("sys_actstg_pausewinopen"); g_isAwaitingResult = true; @@ -329,6 +343,8 @@ void MessageWindow::Close() g_isControlsVisible = false; g_foregroundCount = 0; g_isAwaitingResult = false; + + ButtonGuide::Close(); } Game_PlaySound("sys_actstg_pausewinclose");