diff options
author | aaaaaa123456789 <aaaaaa123456789@acidch.at> | 2020-09-13 04:22:50 -0300 |
---|---|---|
committer | aaaaaa123456789 <aaaaaa123456789@acidch.at> | 2020-09-13 06:30:55 -0300 |
commit | 7dc95a0103af08c95c9093b6efa6c77af77a2538 (patch) | |
tree | 663537916626ab264bbdef4ea3606415457c36a3 /src/battle_pyramid_bag.c | |
parent | 58a2b62bae1406d2c768698ed13efcd6a5ffbeec (diff) |
Undo PokeCodec's PRs
This commit undoes most of PokeCodec's PRs after the debate in chat. Some
harmless or completely superseded PRs have been left alone, as there is not
much benefit in attempting to undo them.
Reverts #1104, #1108, #1115, #1118, #1119, #1124, #1126, #1127, #1132, #1136,
#1137, #1139, #1140, #1144, #1148, #1149, #1150, #1153, #1155, #1177, #1179,
#1180, #1181, #1182 and #1183.
Diffstat (limited to 'src/battle_pyramid_bag.c')
-rw-r--r-- | src/battle_pyramid_bag.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/src/battle_pyramid_bag.c b/src/battle_pyramid_bag.c index 8fee57855..e038e71e1 100644 --- a/src/battle_pyramid_bag.c +++ b/src/battle_pyramid_bag.c @@ -839,7 +839,7 @@ static void Task_HandlePyramidBagInput(u8 taskId) s16 *data = gTasks[taskId].data; if (MenuHelpers_CallLinkSomething() != TRUE && !gPaletteFade.active) { - if (JOY_NEW(SELECT_BUTTON)) + if (gMain.newKeys & SELECT_BUTTON) { if (gPyramidBagCursorData.unk4 != 2) { @@ -965,7 +965,7 @@ static void HandleMenuActionInput(u8 taskId) if (MenuHelpers_CallLinkSomething() != TRUE) { s8 id = Menu_GetCursorPos(); - if (JOY_NEW(DPAD_UP)) + if (gMain.newKeys & DPAD_UP) { if (id > 0 && IsValidMenuAction(id - 2)) { @@ -973,7 +973,7 @@ static void HandleMenuActionInput(u8 taskId) ChangeListMenuCursorPosition(MENU_CURSOR_DELTA_NONE, MENU_CURSOR_DELTA_UP); } } - else if (JOY_NEW(DPAD_DOWN)) + else if (gMain.newKeys & DPAD_DOWN) { if (id < gPyramidBagResources->menuActionsCount - 2 && IsValidMenuAction(id + 2)) { @@ -981,7 +981,7 @@ static void HandleMenuActionInput(u8 taskId) ChangeListMenuCursorPosition(MENU_CURSOR_DELTA_NONE, MENU_CURSOR_DELTA_DOWN); } } - else if (JOY_NEW(DPAD_LEFT) || GetLRKeysPressed() == MENU_L_PRESSED) + else if (gMain.newKeys & DPAD_LEFT || GetLRKeysPressed() == MENU_L_PRESSED) { if (id & 1 && IsValidMenuAction(id - 1)) { @@ -989,7 +989,7 @@ static void HandleMenuActionInput(u8 taskId) ChangeListMenuCursorPosition(MENU_CURSOR_DELTA_LEFT, MENU_CURSOR_DELTA_NONE); } } - else if (JOY_NEW(DPAD_RIGHT) || GetLRKeysPressed() == MENU_R_PRESSED) + else if (gMain.newKeys & DPAD_RIGHT || GetLRKeysPressed() == MENU_R_PRESSED) { if (!(id & 1) && IsValidMenuAction(id + 1)) { @@ -997,13 +997,13 @@ static void HandleMenuActionInput(u8 taskId) ChangeListMenuCursorPosition(MENU_CURSOR_DELTA_RIGHT, MENU_CURSOR_DELTA_NONE); } } - else if (JOY_NEW(A_BUTTON)) + else if (gMain.newKeys & A_BUTTON) { PlaySE(SE_SELECT); if (sMenuActions[gPyramidBagResources->menuActionIds[id]].func.void_u8 != NULL) sMenuActions[gPyramidBagResources->menuActionIds[id]].func.void_u8(taskId); } - else if (JOY_NEW(B_BUTTON)) + else if (gMain.newKeys & B_BUTTON) { PlaySE(SE_SELECT); sMenuActions[ACTION_CANCEL].func.void_u8(taskId); @@ -1143,7 +1143,7 @@ static void sub_81C64B4(u8 taskId) { sub_81C645C(data[8]); } - else if (JOY_NEW(A_BUTTON)) + else if (gMain.newKeys & A_BUTTON) { PlaySE(SE_SELECT); ClearStdWindowAndFrameToTransparent(3, 0); @@ -1151,7 +1151,7 @@ static void sub_81C64B4(u8 taskId) ScheduleBgCopyTilemapToVram(1); sub_81C6350(taskId); } - else if (JOY_NEW(B_BUTTON)) + else if (gMain.newKeys & B_BUTTON) { PlaySE(SE_SELECT); ClearStdWindowAndFrameToTransparent(3, 0); @@ -1179,7 +1179,7 @@ static void sub_81C65CC(u8 taskId) u16 *scrollOffset = &gPyramidBagCursorData.scrollPosition; u16 *selectedRow = &gPyramidBagCursorData.cursorPosition; - if (JOY_NEW(A_BUTTON | B_BUTTON)) + if (gMain.newKeys & (A_BUTTON | B_BUTTON)) { PlaySE(SE_SELECT); RemovePyramidBagItem(gSpecialVar_ItemId, data[8]); @@ -1220,7 +1220,7 @@ static void sub_81C66AC(u8 taskId) static void sub_81C66EC(u8 taskId) { - if (JOY_NEW(A_BUTTON)) + if (gMain.newKeys & A_BUTTON) { PlaySE(SE_SELECT); Task_CloseBattlePyramidBagMessage(taskId); @@ -1277,7 +1277,7 @@ static void Task_ItemSwapHandleInput(u8 taskId) s16 *data = gTasks[taskId].data; if (MenuHelpers_CallLinkSomething() != TRUE) { - if (JOY_NEW(SELECT_BUTTON)) + if (gMain.newKeys & SELECT_BUTTON) { PlaySE(SE_SELECT); ListMenuGetScrollAndRow(data[0], &gPyramidBagCursorData.scrollPosition, &gPyramidBagCursorData.cursorPosition); @@ -1295,7 +1295,7 @@ static void Task_ItemSwapHandleInput(u8 taskId) break; case LIST_CANCEL: PlaySE(SE_SELECT); - if (JOY_NEW(A_BUTTON)) + if (gMain.newKeys & A_BUTTON) PerformItemSwap(taskId); else sub_81C6A14(taskId); |