summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDiegoisawesome <Diegoisawesome@users.noreply.github.com>2018-08-11 16:27:52 -0700
committerGitHub <noreply@github.com>2018-08-11 16:27:52 -0700
commit94eef0bfa5b67a3ef3061b151e6ff113b45adc2e (patch)
treef9fd35ac1311a2591e0d6c6a303ba7e6307ed95e /src
parent0c29447717c8d6b74e53a0f7ebeda707c68b0fcc (diff)
parent7b9a7765e00ea01f07ab7c4169804881749f6513 (diff)
Merge pull request #294 from DizzyEggg/learnsets
Make learnsets easier to edit
Diffstat (limited to 'src')
-rw-r--r--src/pokemon.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/pokemon.c b/src/pokemon.c
index cd7e45758..7c010cd39 100644
--- a/src/pokemon.c
+++ b/src/pokemon.c
@@ -2089,7 +2089,7 @@ void GiveBoxMonInitialMoveset(struct BoxPokemon *boxMon)
s32 level = GetLevelFromBoxMonExp(boxMon);
s32 i;
- for (i = 0; gLevelUpLearnsets[species][i] != (u16)-1; i++)
+ for (i = 0; gLevelUpLearnsets[species][i] != LEVEL_UP_END; i++)
{
u16 moveLevel;
u16 move;
@@ -2101,7 +2101,7 @@ void GiveBoxMonInitialMoveset(struct BoxPokemon *boxMon)
move = (gLevelUpLearnsets[species][i] & 0x1FF);
- if (GiveMoveToBoxMon(boxMon, move) == (u16)-1)
+ if (GiveMoveToBoxMon(boxMon, move) == 0xFFFF)
DeleteFirstMoveAndGiveMoveToBoxMon(boxMon, move);
}
}
@@ -2123,7 +2123,7 @@ u16 MonTryLearningNewMove(struct Pokemon *mon, bool8 firstMove)
while ((gLevelUpLearnsets[species][sLearningMoveTableID] & 0xFE00) != (level << 9))
{
sLearningMoveTableID++;
- if (gLevelUpLearnsets[species][sLearningMoveTableID] == 0xFFFF)
+ if (gLevelUpLearnsets[species][sLearningMoveTableID] == LEVEL_UP_END)
return 0;
}
}