From 8908b7d47a6f4879a37c6d5794a347e1c3c422f4 Mon Sep 17 00:00:00 2001 From: PikalaxALT Date: Sun, 15 Mar 2020 13:24:40 -0400 Subject: finish pokemon_storage_system_6 --- src/pokemon_storage_system_6.c | 51 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) (limited to 'src') diff --git a/src/pokemon_storage_system_6.c b/src/pokemon_storage_system_6.c index 4c5bc4189..a92fe6891 100644 --- a/src/pokemon_storage_system_6.c +++ b/src/pokemon_storage_system_6.c @@ -4,6 +4,7 @@ #include "new_menu_helpers.h" #include "pokemon_storage_system_internal.h" #include "strings.h" +#include "constants/songs.h" void InitMenu(void) { @@ -94,3 +95,53 @@ void AddMenu(void) ScheduleBgCopyTilemapToVram(0); sPSSData->field_CAE = 0; } + +bool8 sub_8094F90(void) +{ + // Some debug flag? + return FALSE; +} + +s16 sub_8094F94(void) +{ + s32 textId = -2; + + do + { + if (JOY_NEW(A_BUTTON)) + { + textId = Menu_GetCursorPos(); + break; + } + else if (JOY_NEW(B_BUTTON)) + { + PlaySE(SE_SELECT); + textId = -1; + } + + if (JOY_NEW(DPAD_UP)) + { + PlaySE(SE_SELECT); + Menu_MoveCursor(-1); + } + else if (JOY_NEW(DPAD_DOWN)) + { + PlaySE(SE_SELECT); + Menu_MoveCursor(1); + } + } while (0); + + if (textId != -2) + sub_8095024(); + + if (textId >= 0) + textId = sPSSData->menuItems[textId].textId; + + return textId; +} + +void sub_8095024(void) +{ + ClearStdWindowAndFrameToTransparent(sPSSData->field_CB0, TRUE); + RemoveWindow(sPSSData->field_CB0); +} -- cgit v1.2.3