Skip to content

Instantly share code, notes, and snippets.

@videlais

videlais/bank1.c Secret

Created Jul 9, 2016
Embed
What would you like to do?
bank1.c example
#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
You can’t perform that action at this time.