Review suggestions.

This commit is contained in:
Eduardo Quezada 2022-12-27 00:04:46 -03:00
parent 701179eb1f
commit b0127428c6

View File

@ -107,6 +107,7 @@ enum {
#define PSS_DATA_WINDOW_MOVE_DESCRIPTION 2
#define MOVE_SELECTOR_SPRITES_COUNT 10
#define TYPE_ICON_SPRITE_COUNT (MAX_MON_MOVES + 1)
// for the spriteIds field in PokemonSummaryScreenData
enum
{
@ -114,7 +115,7 @@ enum
SPRITE_ARR_ID_BALL,
SPRITE_ARR_ID_STATUS,
SPRITE_ARR_ID_TYPE, // 2 for mon types, 5 for move types(4 moves and 1 to learn), used interchangeably, because mon types and move types aren't shown on the same screen
SPRITE_ARR_ID_MOVE_SELECTOR1 = SPRITE_ARR_ID_TYPE + 5, // 10 sprites that make up the selector
SPRITE_ARR_ID_MOVE_SELECTOR1 = SPRITE_ARR_ID_TYPE + TYPE_ICON_SPRITE_COUNT, // 10 sprites that make up the selector
SPRITE_ARR_ID_MOVE_SELECTOR2 = SPRITE_ARR_ID_MOVE_SELECTOR1 + MOVE_SELECTOR_SPRITES_COUNT,
SPRITE_ARR_ID_COUNT = SPRITE_ARR_ID_MOVE_SELECTOR2 + MOVE_SELECTOR_SPRITES_COUNT
};
@ -3759,7 +3760,7 @@ static void CreateMoveTypeIcons(void)
{
u8 i;
for (i = SPRITE_ARR_ID_TYPE; i < SPRITE_ARR_ID_MOVE_SELECTOR1; i++)
for (i = SPRITE_ARR_ID_TYPE; i < SPRITE_ARR_ID_TYPE + TYPE_ICON_SPRITE_COUNT; i++)
{
if (sMonSummaryScreen->spriteIds[i] == SPRITE_NONE)
sMonSummaryScreen->spriteIds[i] = CreateSprite(&sSpriteTemplate_MoveTypes, 0, 0, 2);