From 46fb92c4da8de0f7166a48c77a8a74fb3ee0351a Mon Sep 17 00:00:00 2001 From: LOuroboros Date: Wed, 1 Sep 2021 17:40:12 -0300 Subject: [PATCH] Optimized checks --- src/battle_script_commands.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/battle_script_commands.c b/src/battle_script_commands.c index a3edf689a..1a2d90ac2 100644 --- a/src/battle_script_commands.c +++ b/src/battle_script_commands.c @@ -3965,9 +3965,8 @@ static void Cmd_getexp(void) // Recalculate the stats of every party member before the end for (i = 0; i < PARTY_SIZE; i++) { - if (GetMonData(&gPlayerParty[i], MON_DATA_HP) != 0 - && GetMonData(&gPlayerParty[i], MON_DATA_SPECIES2) != SPECIES_NONE - && !GetMonData(&gPlayerParty[i], MON_DATA_IS_EGG)) + if (GetMonData(&gPlayerParty[i], MON_DATA_SPECIES2) != SPECIES_NONE + && GetMonData(&gPlayerParty[i], MON_DATA_SPECIES2) != SPECIES_EGG) { CalculateMonStats(&gPlayerParty[i]); }