From 21c8a67b10c9d1c3190b3a2acc1b53ad82cce2c1 Mon Sep 17 00:00:00 2001 From: Flashfyre Date: Mon, 27 Nov 2023 08:46:59 -0500 Subject: [PATCH] Change perfect IVs achievement condition --- src/battle-phases.ts | 5 ++--- src/system/achv.ts | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/battle-phases.ts b/src/battle-phases.ts index 5ad392427..660b14b51 100644 --- a/src/battle-phases.ts +++ b/src/battle-phases.ts @@ -2852,9 +2852,6 @@ export class AttemptCapturePhase extends PokemonPhase { if (pokemon.species.mythical) this.scene.validateAchv(achvs.CATCH_MYTHICAL); - if (pokemon.ivs.filter(iv => iv === 31).length === 6) - this.scene.validateAchv(achvs.PERFECT_IVS); - let dexEntry: DexEntry; let speciesId = pokemon.species.speciesId; do { @@ -2864,6 +2861,8 @@ export class AttemptCapturePhase extends PokemonPhase { if (dexIvs[i] < pokemon.ivs[i]) dexIvs[i] = pokemon.ivs[i]; } + if (dexIvs.filter(iv => iv === 31).length === 6) + this.scene.validateAchv(achvs.PERFECT_IVS); } while (pokemonPrevolutions.hasOwnProperty(speciesId) && (speciesId = pokemonPrevolutions[speciesId])); this.scene.ui.showText(`${pokemon.name} was caught!`, null, () => { diff --git a/src/system/achv.ts b/src/system/achv.ts index 470131288..4eb3c9c95 100644 --- a/src/system/achv.ts +++ b/src/system/achv.ts @@ -122,7 +122,7 @@ export const achvs = { SEE_SHINY: new Achv('Shiny', 'Find a shiny Pokémon in the wild', 'pb_gold', 75), SHINY_PARTY: new Achv('That\'s Dedication', 'Have a full party of shiny Pokémon', 'shiny_charm', 100).setSecret(true), HIDDEN_ABILITY: new Achv('Hidden Potential', 'Catch a Pokémon with a hidden ability', 'ability_charm', 75), - PERFECT_IVS: new Achv('Certificate of Authenticity', 'Catch a Pokémon with perfect IVs', 'blunder_policy', 100), + PERFECT_IVS: new Achv('Certificate of Authenticity', 'Get perfect IVs on a Pokémon', 'blunder_policy', 100), CLASSIC_VICTORY: new Achv('Undefeated', 'Beat the game in classic mode', 'relic_crown', 150) };