diff --git a/src/ui/pokemon-info-container.ts b/src/ui/pokemon-info-container.ts index f8a39beac6c..c11552c72bb 100644 --- a/src/ui/pokemon-info-container.ts +++ b/src/ui/pokemon-info-container.ts @@ -128,9 +128,8 @@ export default class PokemonInfoContainer extends Phaser.GameObjects.Container { } else this.pokemonGenderText.setVisible(false); - const ability = pokemon.getAbility(true); - const abilityTextStyle = ability.id === pokemon.getSpeciesForm().abilityHidden ? TextStyle.MONEY : TextStyle.WINDOW; - this.pokemonAbilityText.setText(ability.name); + const abilityTextStyle = pokemon.abilityIndex === (pokemon.species.ability2 ? 2 : 1) ? TextStyle.MONEY : TextStyle.WINDOW; + this.pokemonAbilityText.setText(pokemon.getAbility(true).name); this.pokemonAbilityText.setColor(getTextColor(abilityTextStyle, false, this.scene.uiTheme)); this.pokemonAbilityText.setShadowColor(getTextColor(abilityTextStyle, true, this.scene.uiTheme)); diff --git a/src/ui/starter-select-ui-handler.ts b/src/ui/starter-select-ui-handler.ts index fc1d76e7e0c..369dcf44f7a 100644 --- a/src/ui/starter-select-ui-handler.ts +++ b/src/ui/starter-select-ui-handler.ts @@ -1464,7 +1464,7 @@ export default class StarterSelectUiHandler extends MessageUiHandler { const ability = this.lastSpecies.getAbility(abilityIndex); this.pokemonAbilityText.setText(allAbilities[ability].name); - const isHidden = ability === this.lastSpecies.abilityHidden; + const isHidden = abilityIndex === (this.lastSpecies.ability2 ? 2 : 1); this.pokemonAbilityText.setColor(this.getTextColor(!isHidden ? TextStyle.SUMMARY_ALT : TextStyle.SUMMARY_GOLD)); this.pokemonAbilityText.setShadowColor(this.getTextColor(!isHidden ? TextStyle.SUMMARY_ALT : TextStyle.SUMMARY_GOLD, true));