Skip to content

Commit

Permalink
Fixed Frostbite icon appearing in AI Pary menu for mon without ailment
Browse files Browse the repository at this point in the history
  • Loading branch information
AsparagusEduardo authored and AgustinGDLV committed May 26, 2023
1 parent de2d864 commit 05895c5
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/battle_debug.c
Original file line number Diff line number Diff line change
Expand Up @@ -1015,11 +1015,13 @@ static void Task_ShowAiParty(u8 taskId)
gSprites[gSprites[data->spriteIds.aiPartyIcons[i]].sConditionSpriteId].oam.priority = 0;
if (aiMons[i].isFainted)
ailment = AILMENT_FNT;
else if (aiMons[i].status)
else
ailment = GetAilmentFromStatus(aiMons[i].status);

if (ailment != AILMENT_NONE)
StartSpriteAnim(&gSprites[gSprites[data->spriteIds.aiPartyIcons[i]].sConditionSpriteId], ailment - 1);
else
ailment = AILMENT_FNT + 1; // blank
StartSpriteAnim(&gSprites[gSprites[data->spriteIds.aiPartyIcons[i]].sConditionSpriteId], ailment - 1);
gSprites[gSprites[data->spriteIds.aiPartyIcons[i]].sConditionSpriteId].invisible = TRUE;
}
for (; i < PARTY_SIZE; i++)
data->spriteIds.aiPartyIcons[i] = 0xFF;
Expand Down

0 comments on commit 05895c5

Please sign in to comment.