diff options
author | PikalaxALT <pikalaxalt@gmail.com> | 2019-04-05 17:39:38 -0400 |
---|---|---|
committer | huderlem <huderlem@gmail.com> | 2019-04-06 08:16:13 -0500 |
commit | 0ab30dbcd559fd5c53fc52166a46eff60d2a0e86 (patch) | |
tree | 7973b7eb74f0e3d18be839e08283760192ffca4f /src | |
parent | 5ad5b69050697a1acf2a9ab668475ae775014e00 (diff) |
sub_80F6250
Diffstat (limited to 'src')
-rw-r--r-- | src/pokenav.c | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/src/pokenav.c b/src/pokenav.c index 0992cef90..e074b83e8 100644 --- a/src/pokenav.c +++ b/src/pokenav.c @@ -5862,3 +5862,53 @@ void sub_80F6208(void) ; } } + +bool8 sub_80F6250(void) +{ + u16 i; + + if (gPokenavStructPtr->unk8FE8 != -1) + return FALSE; + + switch (gPokenavStructPtr->unk8FE6) + { + default: + for (i = 0; i < 10; i++) + { + if (GetBoxMonData(&gPokemonStorage.boxes[gPokenavStructPtr->unk8FE6 + 0][gPokenavStructPtr->unk8FE7], MON_DATA_RIBBON_COUNT) != 0) + { + gPokenavStructPtr->unk8FE8 = 1; + return FALSE; + } + if (GetBoxMonData(&gPokemonStorage.boxes[gPokenavStructPtr->unk8FE6 + 7][gPokenavStructPtr->unk8FE7], MON_DATA_RIBBON_COUNT) != 0) + { + gPokenavStructPtr->unk8FE8 = 1; + return FALSE; + } + if (++gPokenavStructPtr->unk8FE7 >= 30) + { + gPokenavStructPtr->unk8FE7 = 0; + if (++gPokenavStructPtr->unk8FE6 >= 7) + { + break; + } + } + } + break; + case 8: + return FALSE; + case 7: + gPokenavStructPtr->unk8FE8 = 0; + for (i = 0; i < 6; i++) + { + if (GetMonData(&gPlayerParty[i], MON_DATA_RIBBON_COUNT) != 0) + { + gPokenavStructPtr->unk8FE8 = 1; + break; + } + } + gPokenavStructPtr->unk8FE6++; + return FALSE; + } + return TRUE; +} |