diff options
author | GriffinR <griffin.richards@comcast.net> | 2020-01-05 10:50:32 -0500 |
---|---|---|
committer | GriffinR <griffin.g.richards@gmail.com> | 2020-01-07 22:30:37 -0500 |
commit | fb5bea98ce28044917451d83695991693fb0b64a (patch) | |
tree | 95d2f85fc852fa0b00ba23022f8bd7732ff30c59 /src/pokemon.c | |
parent | bb692a03eb6ac886524e917ed3548d769ac2f6d8 (diff) |
More battle_dome.c doc
Diffstat (limited to 'src/pokemon.c')
-rw-r--r-- | src/pokemon.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/pokemon.c b/src/pokemon.c index 82da96f7d..94002dc7b 100644 --- a/src/pokemon.c +++ b/src/pokemon.c @@ -1334,7 +1334,7 @@ const struct SpindaSpot gSpindaSpotGraphics[] = #include "data/pokemon/item_effects.h" -const s8 gNatureStatTable[][5] = +const s8 gNatureStatTable[][NUM_EV_STATS] = { // Atk Def Spd Sp.Atk Sp.Def { 0, 0, 0, 0, 0}, // Hardy @@ -5715,7 +5715,8 @@ u8 GetTrainerEncounterMusicId(u16 trainerOpponentId) u16 ModifyStatByNature(u8 nature, u16 n, u8 statIndex) { - if (statIndex < 1 || statIndex > 5) + // Dont modify HP, Accuracy, or Evasion by nature + if (statIndex <= STAT_HP || statIndex > NUM_EV_STATS) { // Should just be "return n", but it wouldn't match without this. u16 retVal = n; |