summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/global.h4
-rw-r--r--src/fame_checker.c18
2 files changed, 11 insertions, 11 deletions
diff --git a/include/global.h b/include/global.h
index 2b9b00d5c..84597dba0 100644
--- a/include/global.h
+++ b/include/global.h
@@ -68,8 +68,8 @@
// GameFreak never ceases to amaze.
// TODO: Propagate use of this macro
#define TEST_BUTTON(field, button) ({(field) & (button);})
-#define PRESSED(button) TEST_BUTTON(gMain.newKeys, button)
-#define PUSHED(button) TEST_BUTTON(gMain.heldKeys, button)
+#define JOY_NEW(button) TEST_BUTTON(gMain.newKeys, button)
+#define JOY_HELD(button) TEST_BUTTON(gMain.heldKeys, button)
extern u8 gStringVar1[];
extern u8 gStringVar2[];
diff --git a/src/fame_checker.c b/src/fame_checker.c
index 3b5576923..8150c58ef 100644
--- a/src/fame_checker.c
+++ b/src/fame_checker.c
@@ -610,9 +610,9 @@ static void sub_812C694(u8 taskId)
if (FindTaskIdByFunc(sub_812E110) == 0xFF)
{
RunTextPrinters();
- if ((PRESSED(SELECT_BUTTON)) && !sFameCheckerData->unk_07_1 && sFameCheckerData->savedCallback != sub_8107EB8)
+ if ((JOY_NEW(SELECT_BUTTON)) && !sFameCheckerData->unk_07_1 && sFameCheckerData->savedCallback != sub_8107EB8)
task->func = sub_812CF3C;
- else if (PRESSED(START_BUTTON))
+ else if (JOY_NEW(START_BUTTON))
{
r4 = sub_812E064();
if (sub_812C8F8(taskId) == TRUE)
@@ -636,7 +636,7 @@ static void sub_812C694(u8 taskId)
task->func = sub_812C9BC;
}
}
- else if (PRESSED(A_BUTTON))
+ else if (JOY_NEW(A_BUTTON))
{
r4 = ListMenuHandleInput(0);
if (r4 == sFameCheckerData->unk_07_2 - 1)
@@ -667,7 +667,7 @@ static void sub_812C694(u8 taskId)
task->func = sub_812CAD8;
}
}
- else if (PRESSED(B_BUTTON))
+ else if (JOY_NEW(B_BUTTON))
{
if (sub_812C8F8(taskId) != TRUE)
task->func = sub_812CF3C;
@@ -739,13 +739,13 @@ static void sub_812CAD8(u8 taskId)
s16 *data = gTasks[taskId].data;
RunTextPrinters();
- if (PRESSED(A_BUTTON) && !IsTextPrinterActive(2))
+ if (JOY_NEW(A_BUTTON) && !IsTextPrinterActive(2))
{
u8 spriteId = sFameCheckerData->spriteIds[data[1]];
if (gSprites[spriteId].data[1] != 0xFF)
sub_812CE04(taskId);
}
- if (PRESSED(B_BUTTON))
+ if (JOY_NEW(B_BUTTON))
{
u8 r4;
PlaySE(SE_SELECT);
@@ -761,7 +761,7 @@ static void sub_812CAD8(u8 taskId)
sub_812C990();
task->func = sub_812C694;
}
- else if (PRESSED(DPAD_UP) || PRESSED(DPAD_DOWN))
+ else if (JOY_NEW(DPAD_UP) || JOY_NEW(DPAD_DOWN))
{
if (task->data[1] >= 3)
{
@@ -774,7 +774,7 @@ static void sub_812CAD8(u8 taskId)
sub_812CC68(taskId, 0, +0x1b);
}
}
- else if (PRESSED(DPAD_LEFT))
+ else if (JOY_NEW(DPAD_LEFT))
{
if (task->data[1] == 0 || task->data[1] % 3 == 0)
{
@@ -787,7 +787,7 @@ static void sub_812CAD8(u8 taskId)
sub_812CC68(taskId, -0x2f, 0);
}
}
- else if (PRESSED(DPAD_RIGHT))
+ else if (JOY_NEW(DPAD_RIGHT))
{
if ((task->data[1] + 1) % 3 == 0)
{