Merge pull request #1701 from LOuroboros/safariZone

Fixed Safari Zone
This commit is contained in:
Eduardo Quezada D'Ottone 2021-10-01 09:07:16 -03:00 committed by GitHub
commit 9980108f40
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3465,10 +3465,13 @@ static void TryDoEventsBeforeFirstTurn(void)
return; return;
// Set invalid mons as absent(for example when starting a double battle with only one pokemon). // Set invalid mons as absent(for example when starting a double battle with only one pokemon).
for (i = 0; i < gBattlersCount; i++) if (!(gBattleTypeFlags & BATTLE_TYPE_SAFARI))
{ {
if (gBattleMons[i].hp == 0 || gBattleMons[i].species == SPECIES_NONE) for (i = 0; i < gBattlersCount; i++)
gAbsentBattlerFlags |= gBitTable[i]; {
if (gBattleMons[i].hp == 0 || gBattleMons[i].species == SPECIES_NONE)
gAbsentBattlerFlags |= gBitTable[i];
}
} }
if (gBattleStruct->switchInAbilitiesCounter == 0) if (gBattleStruct->switchInAbilitiesCounter == 0)