diff options
author | GriffinR <griffin.g.richards@gmail.com> | 2022-01-01 10:20:01 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-01 10:20:01 -0500 |
commit | cb7b53adeeb96550428f55ba57438312c30803fc (patch) | |
tree | 2018660bf98c074452dad5b506d2e3a841bb3473 | |
parent | 4c023cb8c7fb6e5e8f13867b39c3fbb9f7e7b6b1 (diff) | |
parent | 92d6d97c654391a82fba605b2af29e2aa99bdc00 (diff) |
Merge pull request #479 from Birdulon/PartySize
Fix party size calculations for larger-than-six PARTY_SIZE
-rw-r--r-- | src/pokemon.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/pokemon.c b/src/pokemon.c index 0bbb9f81e..01b06a1af 100644 --- a/src/pokemon.c +++ b/src/pokemon.c @@ -3675,7 +3675,7 @@ u8 CalculatePlayerPartyCount(void) { gPlayerPartyCount = 0; - while (gPlayerPartyCount < 6 + while (gPlayerPartyCount < PARTY_SIZE && GetMonData(&gPlayerParty[gPlayerPartyCount], MON_DATA_SPECIES, NULL) != SPECIES_NONE) { gPlayerPartyCount++; @@ -3689,7 +3689,7 @@ u8 CalculateEnemyPartyCount(void) { gEnemyPartyCount = 0; - while (gEnemyPartyCount < 6 + while (gEnemyPartyCount < PARTY_SIZE && GetMonData(&gEnemyParty[gEnemyPartyCount], MON_DATA_SPECIES, NULL) != SPECIES_NONE) { gEnemyPartyCount++; |