summaryrefslogtreecommitdiff
path: root/src/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/main.c b/src/main.c
index a4c844144..1573a2c5b 100644
--- a/src/main.c
+++ b/src/main.c
@@ -132,7 +132,7 @@ void AgbMain()
InitMapMusic();
ClearDma3Requests();
ResetBgs();
- InitHeap(gHeap, 0x1C000);
+ InitHeap(gHeap, HEAP_SIZE);
SetDefaultFontsPointer();
gSoftResetDisabled = FALSE;
@@ -162,7 +162,7 @@ void AgbMain()
DoSoftReset();
}
- if (sub_80582E0() == 1)
+ if (Overworld_SendKeysToLinkIsRunning() == TRUE)
{
gLinkTransferringData = TRUE;
UpdateLinkAndCallCallbacks();
@@ -173,7 +173,7 @@ void AgbMain()
gLinkTransferringData = FALSE;
UpdateLinkAndCallCallbacks();
- if (sub_8058274() == 1)
+ if (Overworld_RecvKeysFromLinkIsRunning() == 1)
{
gMain.newKeys = 0;
ClearSpriteCopyRequests();
@@ -293,16 +293,16 @@ static void ReadKeys(void)
gMain.heldKeys = gMain.heldKeysRaw;
// Remap L to A if the L=A option is enabled.
- if (gSaveBlock2Ptr->optionsButtonMode == 2)
+ if (gSaveBlock2Ptr->optionsButtonMode == OPTIONS_BUTTON_MODE_L_EQUALS_A)
{
- if (gMain.newKeys & L_BUTTON)
+ if (JOY_NEW(L_BUTTON))
gMain.newKeys |= A_BUTTON;
- if (gMain.heldKeys & L_BUTTON)
+ if (JOY_HELD(L_BUTTON))
gMain.heldKeys |= A_BUTTON;
}
- if (gMain.newKeys & gMain.watchedKeysMask)
+ if (JOY_NEW(gMain.watchedKeysMask))
gMain.watchedKeysPressed = TRUE;
}
@@ -323,7 +323,7 @@ void InitIntrHandlers(void)
REG_IME = 1;
- EnableInterrupts(0x1);
+ EnableInterrupts(INTR_FLAG_VBLANK);
}
void SetVBlankCallback(IntrCallback callback)