Fix debug menu flags not redrawing correctly after PR 3796 (#3916)

* Fix debug menu flags not redrawing correctly after PR 3796

* Update src/debug.c

Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>

---------

Co-authored-by: ravepossum <ravepossum@example.com>
Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
This commit is contained in:
ravepossum 2024-01-03 17:27:10 -05:00 committed by GitHub
parent 973dae73be
commit e9e46d8272
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1437,8 +1437,16 @@ static void DebugTask_HandleMenuInput_FlagsVars(u8 taskId)
PlaySE(SE_SELECT);
if ((func = sDebugMenu_Actions_Flags[input]) != NULL)
{
Debug_RedrawListMenu(taskId);
func(taskId);
if (input == DEBUG_FLAGVAR_MENU_ITEM_FLAGS || input == DEBUG_FLAGVAR_MENU_ITEM_VARS)
{
Debug_RedrawListMenu(taskId);
func(taskId);
}
else
{
func(taskId);
Debug_RedrawListMenu(taskId);
}
// Remove TRUE/FALSE window for functions that haven't been assigned flags
if (gTasks[taskId].tInput == 0xFF)