diff options
author | GriffinR <griffin.g.richards@gmail.com> | 2020-12-12 23:28:01 -0500 |
---|---|---|
committer | GriffinR <griffin.g.richards@gmail.com> | 2020-12-12 23:30:51 -0500 |
commit | 81d95b9325ed2526ce638744408f453a8169abb4 (patch) | |
tree | e0f7100b6b35156f0868df537b2e3a149061dd52 /src/daycare.c | |
parent | ba3021db64bd9518f324c1ad89e63e90278f0eb4 (diff) |
Use BUGFIX for some inline fixes
Diffstat (limited to 'src/daycare.c')
-rw-r--r-- | src/daycare.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/daycare.c b/src/daycare.c index d849b39f3..96f62d5bf 100644 --- a/src/daycare.c +++ b/src/daycare.c @@ -551,13 +551,15 @@ static void InheritIVs(struct Pokemon *egg, struct DayCare *daycare) // removes position 0 (HP) then position 1 (DEF), then position 2. This is why HP and DEF // have a lower chance to be inherited in Emerald and why the IV picked for inheritance can // be repeated. Amusingly, FRLG and RS also got this wrong. They remove selectedIvs[i], which - // is not an index! This means that it can sometimes remove the wrong stat. To fix, delete - // the following two lines and uncomment the rest of the block. + // is not an index! This means that it can sometimes remove the wrong stat. + #ifndef BUGFIX selectedIvs[i] = availableIVs[Random() % (NUM_STATS - i)]; RemoveIVIndexFromList(availableIVs, i); - // u8 index = Random() % (NUM_STATS - i); - // selectedIvs[i] = availableIVs[index]; - // RemoveIVIndexFromList(availableIVs, index); + #else + u8 index = Random() % (NUM_STATS - i); + selectedIvs[i] = availableIVs[index]; + RemoveIVIndexFromList(availableIVs, index); + #endif } // Determine which parent each of the selected IVs should inherit from. |