From 252e2911383a5267673f00c08419e2afeac35a31 Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Thu, 13 Jul 2017 15:22:55 -0400 Subject: App now waits for confirmation to import, and reads pokedex seen&caught --- source/main.c | 55 ++++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 54 insertions(+), 1 deletion(-) (limited to 'source/main.c') diff --git a/source/main.c b/source/main.c index 128feb9..dd252b5 100644 --- a/source/main.c +++ b/source/main.c @@ -240,12 +240,29 @@ u32 getMsg() } send(0); - while (recv()!=0) {sleep(1);}; + while (recv()!=0) {sleep(1);} send(0); return val; } +void getMsgArr(u32* arr, int len) +{ + for (int i=0; i> 5] >> (i & 31) & 1) + { + //printf("Caught #%d\n", i); + numCaught++; + numSeen++; + } else if (pokedexSeen[i >> 5] >> (i & 31) & 1) + { + //printf("Saw #%d\n", i); + numSeen++; + } + } + + printf("Caught: %d\nSeen: %d\n", numCaught, numSeen); + + waitForButtons(PAD_BUTTON_START); } } -- cgit 1.4.1