-
-
Save videlais/834df1afc434d74ed3780a45b34927e0 to your computer and use it in GitHub Desktop.
bank1.c example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <gb/gb.h> | |
// These are our extern(ally) defined functions we use in bank1 | |
extern void checkInput(); | |
extern void updateSwitches(); | |
extern UINT8 collisionCheck(UINT8, UINT8, UINT8, UINT8, UINT8, UINT8, UINT8, UINT8); | |
void update() { | |
while(1) { | |
checkInput(); // Check for user input (and act on it) | |
updateSwitches(); // Make sure the SHOW_SPRITES and SHOW_BKG switches are on each loop | |
wait_vbl_done(); // Wait until VBLANK to avoid corrupting memory | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment