mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-12-27 04:04:17 +01:00
Use button constants in Task_HandleChooseMonInput
This commit is contained in:
parent
f534e8e44a
commit
e06ba39751
@ -1260,13 +1260,13 @@ void Task_HandleChooseMonInput(u8 taskId)
|
||||
|
||||
switch (PartyMenuButtonHandler(slotPtr))
|
||||
{
|
||||
case 1: // Selected mon
|
||||
case A_BUTTON: // Selected mon
|
||||
HandleChooseMonSelection(taskId, slotPtr);
|
||||
break;
|
||||
case 2: // Selected Cancel
|
||||
case B_BUTTON: // Selected Cancel / pressed B
|
||||
HandleChooseMonCancel(taskId, slotPtr);
|
||||
break;
|
||||
case 8: // Start button
|
||||
case START_BUTTON:
|
||||
if (sPartyMenuInternal->chooseHalf)
|
||||
{
|
||||
PlaySE(SE_SELECT);
|
||||
@ -1483,7 +1483,7 @@ static u16 PartyMenuButtonHandler(s8 *slotPtr)
|
||||
}
|
||||
|
||||
if (JOY_NEW(START_BUTTON))
|
||||
return 8;
|
||||
return START_BUTTON;
|
||||
|
||||
if (movementDir)
|
||||
{
|
||||
@ -1492,8 +1492,8 @@ static u16 PartyMenuButtonHandler(s8 *slotPtr)
|
||||
}
|
||||
|
||||
// Pressed Cancel
|
||||
if ((JOY_NEW(A_BUTTON)) && *slotPtr == PARTY_SIZE + 1)
|
||||
return 2;
|
||||
if (JOY_NEW(A_BUTTON) && *slotPtr == PARTY_SIZE + 1)
|
||||
return B_BUTTON;
|
||||
|
||||
return JOY_NEW(A_BUTTON | B_BUTTON);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user