From 075aa11a796c51701b1ed5bd6feb2f03e07c3b8a Mon Sep 17 00:00:00 2001 From: James R Date: Sat, 17 Feb 2024 20:31:40 -0800 Subject: [PATCH] Menus/Profiles: indent selected option --- src/k_menudraw.c | 8 +++++--- src/menus/options-profiles-edit-1.c | 6 ++++++ 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/src/k_menudraw.c b/src/k_menudraw.c index 3f234c9b5..f03a32bc7 100644 --- a/src/k_menudraw.c +++ b/src/k_menudraw.c @@ -4676,6 +4676,7 @@ void M_DrawEditProfile(void) UINT8 *colormap = NULL; INT32 tflag = (currentMenu->menuitems[i].status & IT_TRANSTEXT) ? V_TRANSLUCENT : 0; + INT32 cx = x; y = currentMenu->menuitems[i].mvar2; @@ -4686,13 +4687,14 @@ void M_DrawEditProfile(void) { colormap = R_GetTranslationColormap(TC_RAINBOW, SKINCOLOR_PLAGUE, GTC_CACHE); - V_DrawMenuString(x - 10 - (skullAnimCounter/5), y+1, highlightflags, "\x1C"); // left arrow + cx += Easing_OutSine(M_DueFrac(optionsmenu.offset.start, 2), 0, 5); + V_DrawMenuString(cx - 10 - (skullAnimCounter/5), y+1, highlightflags, "\x1C"); // left arrow } // Text - //V_DrawGamemodeString(x, y - 6, tflag, colormap, currentMenu->menuitems[i].text); + //V_DrawGamemodeString(cx, y - 6, tflag, colormap, currentMenu->menuitems[i].text); V_DrawStringScaled( - x * FRACUNIT, + cx * FRACUNIT, (y - 3) * FRACUNIT, FRACUNIT, FRACUNIT, diff --git a/src/menus/options-profiles-edit-1.c b/src/menus/options-profiles-edit-1.c index e56f1d750..64ccc43fe 100644 --- a/src/menus/options-profiles-edit-1.c +++ b/src/menus/options-profiles-edit-1.c @@ -1,6 +1,7 @@ /// \file menus/options-profiles-edit-1.c /// \brief Profile Editor +#include "../i_time.h" #include "../k_menu.h" #include "../s_sound.h" #include "../m_cond.h" @@ -157,6 +158,11 @@ boolean M_ProfileEditInputs(INT32 ch) return true; // No. } + if (menucmd[pid].dpad_ud != 0) + { + optionsmenu.offset.start = I_GetTime(); + } + return false; }