From 7d0bde460460745ea92275581426f113f7caf50e Mon Sep 17 00:00:00 2001 From: NightKev <34855794+DayKev@users.noreply.github.com> Date: Sat, 16 Aug 2025 15:17:43 -0700 Subject: [PATCH 01/11] [Dev] Remove obsolete ESLint commands from `package.json` --- package.json | 2 -- 1 file changed, 2 deletions(-) diff --git a/package.json b/package.json index 3f523ed5c3e..d3ea890c005 100644 --- a/package.json +++ b/package.json @@ -15,8 +15,6 @@ "test:silent": "vitest run --silent='passed-only' --no-isolate", "test:create": "node scripts/create-test/create-test.js", "typecheck": "tsc --noEmit", - "eslint": "eslint --fix .", - "eslint-ci": "eslint .", "biome": "biome check --write --changed --no-errors-on-unmatched --diagnostic-level=error", "biome-ci": "biome ci --diagnostic-level=error --reporter=github --no-errors-on-unmatched", "docs": "typedoc", From 0b107bcbcd4bbd7a945b7262d7f2c2e01d9f51e2 Mon Sep 17 00:00:00 2001 From: damocleas Date: Sat, 16 Aug 2025 19:09:31 -0400 Subject: [PATCH 02/11] [Balance] Buff OHKO moves from 200 -> 250 Base Power against Bosses (#6278) OHKO moves 200 -> 250 Base Power --- src/data/moves/move.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/data/moves/move.ts b/src/data/moves/move.ts index 5c4061ec388..4b8c4f2129b 100644 --- a/src/data/moves/move.ts +++ b/src/data/moves/move.ts @@ -8512,7 +8512,7 @@ export function initMoves() { .punchingMove(), new AttackMove(MoveId.SCRATCH, PokemonType.NORMAL, MoveCategory.PHYSICAL, 40, 100, 35, -1, 0, 1), new AttackMove(MoveId.VISE_GRIP, PokemonType.NORMAL, MoveCategory.PHYSICAL, 55, 100, 30, -1, 0, 1), - new AttackMove(MoveId.GUILLOTINE, PokemonType.NORMAL, MoveCategory.PHYSICAL, 200, 30, 5, -1, 0, 1) + new AttackMove(MoveId.GUILLOTINE, PokemonType.NORMAL, MoveCategory.PHYSICAL, 250, 30, 5, -1, 0, 1) .attr(OneHitKOAttr) .attr(OneHitKOAccuracyAttr), new ChargingAttackMove(MoveId.RAZOR_WIND, PokemonType.NORMAL, MoveCategory.SPECIAL, 80, 100, 10, -1, 0, 1) @@ -8565,7 +8565,7 @@ export function initMoves() { new AttackMove(MoveId.HORN_ATTACK, PokemonType.NORMAL, MoveCategory.PHYSICAL, 65, 100, 25, -1, 0, 1), new AttackMove(MoveId.FURY_ATTACK, PokemonType.NORMAL, MoveCategory.PHYSICAL, 15, 85, 20, -1, 0, 1) .attr(MultiHitAttr), - new AttackMove(MoveId.HORN_DRILL, PokemonType.NORMAL, MoveCategory.PHYSICAL, 200, 30, 5, -1, 0, 1) + new AttackMove(MoveId.HORN_DRILL, PokemonType.NORMAL, MoveCategory.PHYSICAL, 250, 30, 5, -1, 0, 1) .attr(OneHitKOAttr) .attr(OneHitKOAccuracyAttr), new AttackMove(MoveId.TACKLE, PokemonType.NORMAL, MoveCategory.PHYSICAL, 40, 100, 35, -1, 0, 1), @@ -8746,7 +8746,7 @@ export function initMoves() { .attr(MovePowerMultiplierAttr, (user, target, move) => globalScene.arena.getTerrainType() === TerrainType.GRASSY && target.isGrounded() ? 0.5 : 1) .makesContact(false) .target(MoveTarget.ALL_NEAR_OTHERS), - new AttackMove(MoveId.FISSURE, PokemonType.GROUND, MoveCategory.PHYSICAL, 200, 30, 5, -1, 0, 1) + new AttackMove(MoveId.FISSURE, PokemonType.GROUND, MoveCategory.PHYSICAL, 250, 30, 5, -1, 0, 1) .attr(OneHitKOAttr) .attr(OneHitKOAccuracyAttr) .attr(HitsTagAttr, BattlerTagType.UNDERGROUND) @@ -9528,7 +9528,7 @@ export function initMoves() { new AttackMove(MoveId.SAND_TOMB, PokemonType.GROUND, MoveCategory.PHYSICAL, 35, 85, 15, -1, 0, 3) .attr(TrapAttr, BattlerTagType.SAND_TOMB) .makesContact(false), - new AttackMove(MoveId.SHEER_COLD, PokemonType.ICE, MoveCategory.SPECIAL, 200, 30, 5, -1, 0, 3) + new AttackMove(MoveId.SHEER_COLD, PokemonType.ICE, MoveCategory.SPECIAL, 250, 30, 5, -1, 0, 3) .attr(IceNoEffectTypeAttr) .attr(OneHitKOAttr) .attr(SheerColdAccuracyAttr), From c41a3dc79bd5b3902ca64e2af19f7e25e47daf65 Mon Sep 17 00:00:00 2001 From: damocleas Date: Sat, 16 Aug 2025 19:26:33 -0400 Subject: [PATCH 03/11] [Balance] Adjust Eternatus' Catchrate from 255 -> 45 (#6279) Eternatus Catchrate 255 -> 45 --- src/data/balance/pokemon-species.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/data/balance/pokemon-species.ts b/src/data/balance/pokemon-species.ts index 13269308958..c6c17986257 100644 --- a/src/data/balance/pokemon-species.ts +++ b/src/data/balance/pokemon-species.ts @@ -1505,9 +1505,9 @@ export function initSpecies() { new PokemonForm("Hero of Many Battles", "hero-of-many-battles", PokemonType.FIGHTING, null, 2.9, 210, AbilityId.DAUNTLESS_SHIELD, AbilityId.NONE, AbilityId.NONE, 660, 92, 120, 115, 80, 115, 138, 10, 0, 335, false, "", true), new PokemonForm("Crowned", "crowned", PokemonType.FIGHTING, PokemonType.STEEL, 2.9, 785, AbilityId.DAUNTLESS_SHIELD, AbilityId.NONE, AbilityId.NONE, 700, 92, 120, 140, 80, 140, 128, 10, 0, 360) ), - new PokemonSpecies(SpeciesId.ETERNATUS, 8, false, true, false, "Gigantic Pokémon", PokemonType.POISON, PokemonType.DRAGON, 20, 950, AbilityId.PRESSURE, AbilityId.NONE, AbilityId.NONE, 690, 140, 85, 95, 145, 95, 130, 255, 0, 345, GrowthRate.SLOW, null, false, true, - new PokemonForm("Normal", "", PokemonType.POISON, PokemonType.DRAGON, 20, 950, AbilityId.PRESSURE, AbilityId.NONE, AbilityId.NONE, 690, 140, 85, 95, 145, 95, 130, 255, 0, 345, false, null, true), - new PokemonForm("E-Max", "eternamax", PokemonType.POISON, PokemonType.DRAGON, 100, 999.9, AbilityId.PRESSURE, AbilityId.NONE, AbilityId.NONE, 1125, 255, 115, 250, 125, 250, 130, 255, 0, 345) + new PokemonSpecies(SpeciesId.ETERNATUS, 8, false, true, false, "Gigantic Pokémon", PokemonType.POISON, PokemonType.DRAGON, 20, 950, AbilityId.PRESSURE, AbilityId.NONE, AbilityId.NONE, 690, 140, 85, 95, 145, 95, 130, 45, 0, 345, GrowthRate.SLOW, null, false, true, + new PokemonForm("Normal", "", PokemonType.POISON, PokemonType.DRAGON, 20, 950, AbilityId.PRESSURE, AbilityId.NONE, AbilityId.NONE, 690, 140, 85, 95, 145, 95, 130, 45, 0, 345, false, null, true), + new PokemonForm("E-Max", "eternamax", PokemonType.POISON, PokemonType.DRAGON, 100, 999.9, AbilityId.PRESSURE, AbilityId.NONE, AbilityId.NONE, 1125, 255, 115, 250, 125, 250, 130, 45, 0, 345) ), new PokemonSpecies(SpeciesId.KUBFU, 8, true, false, false, "Wushu Pokémon", PokemonType.FIGHTING, null, 0.6, 12, AbilityId.INNER_FOCUS, AbilityId.NONE, AbilityId.NONE, 385, 60, 90, 60, 53, 50, 72, 3, 50, 77, GrowthRate.SLOW, 87.5, false), new PokemonSpecies(SpeciesId.URSHIFU, 8, true, false, false, "Wushu Pokémon", PokemonType.FIGHTING, PokemonType.DARK, 1.9, 105, AbilityId.UNSEEN_FIST, AbilityId.NONE, AbilityId.NONE, 550, 100, 130, 100, 63, 60, 97, 3, 50, 275, GrowthRate.SLOW, 87.5, false, true, From 5d13714ea6c1187c954cfe0bf56e45d53524b850 Mon Sep 17 00:00:00 2001 From: fabske0 <192151969+fabske0@users.noreply.github.com> Date: Sun, 17 Aug 2025 21:46:12 +0200 Subject: [PATCH 04/11] [i18n] Change i18n keys to be camel case MEs (#6237) * changed ME `intro_dialogue` to camel case * changed MEs part 1 * changed MEs part 2 * changed MEs part 3 * chnaged MEs part 4 * Update locales submodule --- public/locales | 2 +- .../encounters/a-trainers-test-encounter.ts | 2 +- .../encounters/absolute-avarice-encounter.ts | 4 +- .../an-offer-you-cant-refuse-encounter.ts | 4 +- .../encounters/berries-abound-encounter.ts | 2 +- .../encounters/bug-type-superfan-encounter.ts | 24 +++++------ .../encounters/clowning-around-encounter.ts | 18 ++++----- .../encounters/dancing-lessons-encounter.ts | 8 ++-- .../encounters/dark-deal-encounter.ts | 6 +-- .../encounters/delibirdy-encounter.ts | 8 ++-- .../department-store-sale-encounter.ts | 2 +- .../encounters/field-trip-encounter.ts | 12 +++--- .../encounters/fiery-fallout-encounter.ts | 6 +-- .../encounters/fight-or-flight-encounter.ts | 4 +- .../encounters/fun-and-games-encounter.ts | 18 ++++----- .../global-trade-system-encounter.ts | 16 ++++---- .../encounters/lost-at-sea-encounter.ts | 8 ++-- .../encounters/part-timer-encounter.ts | 24 +++++------ .../encounters/safari-zone-encounter.ts | 6 +-- .../shady-vitamin-dealer-encounter.ts | 10 ++--- .../slumbering-snorlax-encounter.ts | 4 +- .../teleporting-hijinks-encounter.ts | 4 +- .../the-expert-pokemon-breeder-encounter.ts | 40 +++++++++---------- .../the-pokemon-salesman-encounter.ts | 10 ++--- .../encounters/the-strong-stuff-encounter.ts | 4 +- .../the-winstrate-challenge-encounter.ts | 4 +- .../encounters/training-session-encounter.ts | 10 ++--- .../encounters/trash-to-treasure-encounter.ts | 2 +- .../encounters/uncommon-breed-encounter.ts | 6 +-- .../encounters/weird-dream-encounter.ts | 6 +-- ...an-offer-you-cant-refuse-encounter.test.ts | 4 +- .../berries-abound-encounter.test.ts | 4 +- .../bug-type-superfan-encounter.test.ts | 10 ++--- .../clowning-around-encounter.test.ts | 10 ++--- .../dancing-lessons-encounter.test.ts | 4 +- .../encounters/delibirdy-encounter.test.ts | 4 +- .../department-store-sale-encounter.test.ts | 2 +- .../encounters/field-trip-encounter.test.ts | 8 ++-- .../fiery-fallout-encounter.test.ts | 2 +- .../fight-or-flight-encounter.test.ts | 2 +- .../fun-and-games-encounter.test.ts | 2 +- .../global-trade-system-encounter.test.ts | 4 +- .../encounters/lost-at-sea-encounter.test.ts | 8 ++-- .../encounters/part-timer-encounter.test.ts | 4 +- .../teleporting-hijinks-encounter.test.ts | 2 +- .../the-expert-breeder-encounter.test.ts | 2 +- .../the-pokemon-salesman-encounter.test.ts | 4 +- .../the-winstrate-challenge-encounter.test.ts | 2 +- .../uncommon-breed-encounter.test.ts | 4 +- .../encounters/weird-dream-encounter.test.ts | 2 +- 50 files changed, 179 insertions(+), 179 deletions(-) diff --git a/public/locales b/public/locales index 1ea8f865e30..748146c687f 160000 --- a/public/locales +++ b/public/locales @@ -1 +1 @@ -Subproject commit 1ea8f865e30d1940caa0fceeabf37ae2e4689471 +Subproject commit 748146c687fd1bdddd015ec4592c4e2b1496af32 diff --git a/src/data/mystery-encounters/encounters/a-trainers-test-encounter.ts b/src/data/mystery-encounters/encounters/a-trainers-test-encounter.ts index ac3d4def654..66364bfc485 100644 --- a/src/data/mystery-encounters/encounters/a-trainers-test-encounter.ts +++ b/src/data/mystery-encounters/encounters/a-trainers-test-encounter.ts @@ -82,7 +82,7 @@ export const ATrainersTestEncounter: MysteryEncounter = MysteryEncounterBuilder. encounter.dialogue.intro = [ { speaker: `trainerNames:${trainerNameKey}`, - text: `${namespace}:${trainerNameKey}.intro_dialogue`, + text: `${namespace}:${trainerNameKey}.introDialogue`, }, ]; encounter.options[0].dialogue!.selected = [ diff --git a/src/data/mystery-encounters/encounters/absolute-avarice-encounter.ts b/src/data/mystery-encounters/encounters/absolute-avarice-encounter.ts index d6058eb9eaf..bf9c49e8c5b 100644 --- a/src/data/mystery-encounters/encounters/absolute-avarice-encounter.ts +++ b/src/data/mystery-encounters/encounters/absolute-avarice-encounter.ts @@ -237,7 +237,7 @@ export const AbsoluteAvariceEncounter: MysteryEncounter = MysteryEncounterBuilde modifierConfigs: bossModifierConfigs, tags: [BattlerTagType.MYSTERY_ENCOUNTER_POST_SUMMON], mysteryEncounterBattleEffects: (pokemon: Pokemon) => { - queueEncounterMessage(`${namespace}:option.1.boss_enraged`); + queueEncounterMessage(`${namespace}:option.1.bossEnraged`); globalScene.phaseManager.unshiftNew( "StatStageChangePhase", pokemon.getBattlerIndex(), @@ -300,7 +300,7 @@ export const AbsoluteAvariceEncounter: MysteryEncounter = MysteryEncounterBuilde globalScene.addModifier(seedModifier, false, false, false, true); } }); - queueEncounterMessage(`${namespace}:option.1.food_stash`); + queueEncounterMessage(`${namespace}:option.1.foodStash`); }; setEncounterRewards({ fillRemaining: true }, undefined, givePartyPokemonReviverSeeds); diff --git a/src/data/mystery-encounters/encounters/an-offer-you-cant-refuse-encounter.ts b/src/data/mystery-encounters/encounters/an-offer-you-cant-refuse-encounter.ts index 619acabe200..7d4fb0ef98f 100644 --- a/src/data/mystery-encounters/encounters/an-offer-you-cant-refuse-encounter.ts +++ b/src/data/mystery-encounters/encounters/an-offer-you-cant-refuse-encounter.ts @@ -71,7 +71,7 @@ export const AnOfferYouCantRefuseEncounter: MysteryEncounter = MysteryEncounterB text: `${namespace}:intro`, }, { - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, speaker: `${namespace}:speaker`, }, ]) @@ -152,7 +152,7 @@ export const AnOfferYouCantRefuseEncounter: MysteryEncounter = MysteryEncounterB .withDialogue({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - disabledButtonTooltip: `${namespace}:option.2.tooltip_disabled`, + disabledButtonTooltip: `${namespace}:option.2.tooltipDisabled`, selected: [ { speaker: `${namespace}:speaker`, diff --git a/src/data/mystery-encounters/encounters/berries-abound-encounter.ts b/src/data/mystery-encounters/encounters/berries-abound-encounter.ts index a827c3fcc0a..196ca873f4e 100644 --- a/src/data/mystery-encounters/encounters/berries-abound-encounter.ts +++ b/src/data/mystery-encounters/encounters/berries-abound-encounter.ts @@ -254,7 +254,7 @@ export const BerriesAboundEncounter: MysteryEncounter = MysteryEncounterBuilder. undefined, doBerryRewards, ); - await showEncounterText(`${namespace}:option.2.selected_bad`); + await showEncounterText(`${namespace}:option.2.selectedBad`); await initBattleWithEnemyConfig(config); return; } diff --git a/src/data/mystery-encounters/encounters/bug-type-superfan-encounter.ts b/src/data/mystery-encounters/encounters/bug-type-superfan-encounter.ts index c5553e9bb95..2f6b988f32e 100644 --- a/src/data/mystery-encounters/encounters/bug-type-superfan-encounter.ts +++ b/src/data/mystery-encounters/encounters/bug-type-superfan-encounter.ts @@ -198,7 +198,7 @@ export const BugTypeSuperfanEncounter: MysteryEncounter = MysteryEncounterBuilde }, { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]) .withOnInit(() => { @@ -312,7 +312,7 @@ export const BugTypeSuperfanEncounter: MysteryEncounter = MysteryEncounterBuilde .withDialogue({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - disabledButtonTooltip: `${namespace}:option.2.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.2.disabledTooltip`, }) .withPreOptionPhase(async () => { // Player shows off their bug types @@ -333,7 +333,7 @@ export const BugTypeSuperfanEncounter: MysteryEncounter = MysteryEncounterBuilde encounter.selectedOption!.dialogue!.selected = [ { speaker: `${namespace}:speaker`, - text: `${namespace}:option.2.selected_0_to_1`, + text: `${namespace}:option.2.selected0To1`, }, ]; } else if (numBugTypes < 4) { @@ -344,7 +344,7 @@ export const BugTypeSuperfanEncounter: MysteryEncounter = MysteryEncounterBuilde encounter.selectedOption!.dialogue!.selected = [ { speaker: `${namespace}:speaker`, - text: `${namespace}:option.2.selected_2_to_3`, + text: `${namespace}:option.2.selected2To3`, }, ]; } else if (numBugTypes < 6) { @@ -355,7 +355,7 @@ export const BugTypeSuperfanEncounter: MysteryEncounter = MysteryEncounterBuilde encounter.selectedOption!.dialogue!.selected = [ { speaker: `${namespace}:speaker`, - text: `${namespace}:option.2.selected_4_to_5`, + text: `${namespace}:option.2.selected4To5`, }, ]; } else { @@ -398,7 +398,7 @@ export const BugTypeSuperfanEncounter: MysteryEncounter = MysteryEncounterBuilde encounter.selectedOption!.dialogue!.selected = [ { speaker: `${namespace}:speaker`, - text: `${namespace}:option.2.selected_6`, + text: `${namespace}:option.2.selected6`, }, ]; } @@ -421,17 +421,17 @@ export const BugTypeSuperfanEncounter: MysteryEncounter = MysteryEncounterBuilde .withDialogue({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - disabledButtonTooltip: `${namespace}:option.3.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.3.disabledTooltip`, selected: [ { text: `${namespace}:option.3.selected`, }, { speaker: `${namespace}:speaker`, - text: `${namespace}:option.3.selected_dialogue`, + text: `${namespace}:option.3.selectedDialogue`, }, ], - secondOptionPrompt: `${namespace}:option.3.select_prompt`, + secondOptionPrompt: `${namespace}:option.3.selectPrompt`, }) .withPreOptionPhase(async (): Promise => { const encounter = globalScene.currentBattle.mysteryEncounter!; @@ -476,7 +476,7 @@ export const BugTypeSuperfanEncounter: MysteryEncounter = MysteryEncounterBuilde ); }); if (!hasValidItem) { - return getEncounterText(`${namespace}:option.3.invalid_selection`) ?? null; + return getEncounterText(`${namespace}:option.3.invalidSelection`) ?? null; } return null; @@ -713,7 +713,7 @@ function doBugTypeMoveTutor(): Promise { // biome-ignore lint/suspicious/noAsyncPromiseExecutor: TODO explain return new Promise(async resolve => { const moveOptions = globalScene.currentBattle.mysteryEncounter!.misc.moveTutorOptions; - await showEncounterDialogue(`${namespace}:battle_won`, `${namespace}:speaker`); + await showEncounterDialogue(`${namespace}:battleWon`, `${namespace}:speaker`); const moveInfoOverlay = new MoveInfoOverlay({ delayVisibility: false, @@ -748,7 +748,7 @@ function doBugTypeMoveTutor(): Promise { const result = await selectOptionThenPokemon( optionSelectItems, - `${namespace}:teach_move_prompt`, + `${namespace}:teachMovePrompt`, undefined, onHoverOverCancel, ); diff --git a/src/data/mystery-encounters/encounters/clowning-around-encounter.ts b/src/data/mystery-encounters/encounters/clowning-around-encounter.ts index 092cc4931af..09e59c7e391 100644 --- a/src/data/mystery-encounters/encounters/clowning-around-encounter.ts +++ b/src/data/mystery-encounters/encounters/clowning-around-encounter.ts @@ -119,7 +119,7 @@ export const ClowningAroundEncounter: MysteryEncounter = MysteryEncounterBuilder text: `${namespace}:intro`, }, { - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, speaker: `${namespace}:speaker`, }, ]) @@ -233,7 +233,7 @@ export const ClowningAroundEncounter: MysteryEncounter = MysteryEncounterBuilder // After the battle, offer the player the opportunity to permanently swap ability const abilityWasSwapped = await handleSwapAbility(); if (abilityWasSwapped) { - await showEncounterText(`${namespace}:option.1.ability_gained`); + await showEncounterText(`${namespace}:option.1.abilityGained`); } // Play animations once ability swap is complete @@ -267,10 +267,10 @@ export const ClowningAroundEncounter: MysteryEncounter = MysteryEncounterBuilder speaker: `${namespace}:speaker`, }, { - text: `${namespace}:option.2.selected_2`, + text: `${namespace}:option.2.selected2`, }, { - text: `${namespace}:option.2.selected_3`, + text: `${namespace}:option.2.selected3`, speaker: `${namespace}:speaker`, }, ], @@ -359,10 +359,10 @@ export const ClowningAroundEncounter: MysteryEncounter = MysteryEncounterBuilder speaker: `${namespace}:speaker`, }, { - text: `${namespace}:option.3.selected_2`, + text: `${namespace}:option.3.selected2`, }, { - text: `${namespace}:option.3.selected_3`, + text: `${namespace}:option.3.selected3`, speaker: `${namespace}:speaker`, }, ], @@ -432,8 +432,8 @@ export const ClowningAroundEncounter: MysteryEncounter = MysteryEncounterBuilder async function handleSwapAbility() { // biome-ignore lint/suspicious/noAsyncPromiseExecutor: TODO: Consider refactoring to avoid async promise executor return new Promise(async resolve => { - await showEncounterDialogue(`${namespace}:option.1.apply_ability_dialogue`, `${namespace}:speaker`); - await showEncounterText(`${namespace}:option.1.apply_ability_message`); + await showEncounterDialogue(`${namespace}:option.1.applyAbilityDialogue`, `${namespace}:speaker`); + await showEncounterText(`${namespace}:option.1.applyAbilityMessage`); globalScene.ui.setMode(UiMode.MESSAGE).then(() => { displayYesNoOptions(resolve); @@ -442,7 +442,7 @@ async function handleSwapAbility() { } function displayYesNoOptions(resolve) { - showEncounterText(`${namespace}:option.1.ability_prompt`, null, 500, false); + showEncounterText(`${namespace}:option.1.abilityPrompt`, null, 500, false); const fullOptions = [ { label: i18next.t("menu:yes"), diff --git a/src/data/mystery-encounters/encounters/dancing-lessons-encounter.ts b/src/data/mystery-encounters/encounters/dancing-lessons-encounter.ts index 8dae0eaee3a..e2c330a1106 100644 --- a/src/data/mystery-encounters/encounters/dancing-lessons-encounter.ts +++ b/src/data/mystery-encounters/encounters/dancing-lessons-encounter.ts @@ -174,7 +174,7 @@ export const DancingLessonsEncounter: MysteryEncounter = MysteryEncounterBuilder // Gets +1 to all stats except SPD on battle start tags: [BattlerTagType.MYSTERY_ENCOUNTER_POST_SUMMON], mysteryEncounterBattleEffects: (pokemon: Pokemon) => { - queueEncounterMessage(`${namespace}:option.1.boss_enraged`); + queueEncounterMessage(`${namespace}:option.1.bossEnraged`); globalScene.phaseManager.unshiftNew( "StatStageChangePhase", pokemon.getBattlerIndex(), @@ -273,8 +273,8 @@ export const DancingLessonsEncounter: MysteryEncounter = MysteryEncounterBuilder .withDialogue({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - disabledButtonTooltip: `${namespace}:option.3.disabled_tooltip`, - secondOptionPrompt: `${namespace}:option.3.select_prompt`, + disabledButtonTooltip: `${namespace}:option.3.disabledTooltip`, + secondOptionPrompt: `${namespace}:option.3.selectPrompt`, selected: [ { text: `${namespace}:option.3.selected`, @@ -316,7 +316,7 @@ export const DancingLessonsEncounter: MysteryEncounter = MysteryEncounterBuilder } const meetsReqs = encounter.options[2].pokemonMeetsPrimaryRequirements(pokemon); if (!meetsReqs) { - return getEncounterText(`${namespace}:invalid_selection`) ?? null; + return getEncounterText(`${namespace}:invalidSelection`) ?? null; } return null; diff --git a/src/data/mystery-encounters/encounters/dark-deal-encounter.ts b/src/data/mystery-encounters/encounters/dark-deal-encounter.ts index 820c7823320..65d22bfc6de 100644 --- a/src/data/mystery-encounters/encounters/dark-deal-encounter.ts +++ b/src/data/mystery-encounters/encounters/dark-deal-encounter.ts @@ -119,7 +119,7 @@ export const DarkDealEncounter: MysteryEncounter = MysteryEncounterBuilder.withE }, { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]) .withSceneWaveRangeRequirement(30, CLASSIC_MODE_MYSTERY_ENCOUNTER_WAVES[1]) @@ -137,10 +137,10 @@ export const DarkDealEncounter: MysteryEncounter = MysteryEncounterBuilder.withE selected: [ { speaker: `${namespace}:speaker`, - text: `${namespace}:option.1.selected_dialogue`, + text: `${namespace}:option.1.selectedDialogue`, }, { - text: `${namespace}:option.1.selected_message`, + text: `${namespace}:option.1.selectedMessage`, }, ], }) diff --git a/src/data/mystery-encounters/encounters/delibirdy-encounter.ts b/src/data/mystery-encounters/encounters/delibirdy-encounter.ts index 85102a01ce1..8cd4c8bee66 100644 --- a/src/data/mystery-encounters/encounters/delibirdy-encounter.ts +++ b/src/data/mystery-encounters/encounters/delibirdy-encounter.ts @@ -193,7 +193,7 @@ export const DelibirdyEncounter: MysteryEncounter = MysteryEncounterBuilder.with .withDialogue({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - secondOptionPrompt: `${namespace}:option.2.select_prompt`, + secondOptionPrompt: `${namespace}:option.2.selectPrompt`, selected: [ { text: `${namespace}:option.2.selected`, @@ -229,7 +229,7 @@ export const DelibirdyEncounter: MysteryEncounter = MysteryEncounterBuilder.with // If pokemon has valid item, it can be selected const meetsReqs = encounter.options[1].pokemonMeetsPrimaryRequirements(pokemon); if (!meetsReqs) { - return getEncounterText(`${namespace}:invalid_selection`) ?? null; + return getEncounterText(`${namespace}:invalidSelection`) ?? null; } return null; @@ -303,7 +303,7 @@ export const DelibirdyEncounter: MysteryEncounter = MysteryEncounterBuilder.with .withDialogue({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - secondOptionPrompt: `${namespace}:option.3.select_prompt`, + secondOptionPrompt: `${namespace}:option.3.selectPrompt`, selected: [ { text: `${namespace}:option.3.selected`, @@ -341,7 +341,7 @@ export const DelibirdyEncounter: MysteryEncounter = MysteryEncounterBuilder.with // If pokemon has valid item, it can be selected const meetsReqs = encounter.options[2].pokemonMeetsPrimaryRequirements(pokemon); if (!meetsReqs) { - return getEncounterText(`${namespace}:invalid_selection`) ?? null; + return getEncounterText(`${namespace}:invalidSelection`) ?? null; } return null; diff --git a/src/data/mystery-encounters/encounters/department-store-sale-encounter.ts b/src/data/mystery-encounters/encounters/department-store-sale-encounter.ts index a45c5301a3e..754e8c883e8 100644 --- a/src/data/mystery-encounters/encounters/department-store-sale-encounter.ts +++ b/src/data/mystery-encounters/encounters/department-store-sale-encounter.ts @@ -43,7 +43,7 @@ export const DepartmentStoreSaleEncounter: MysteryEncounter = MysteryEncounterBu text: `${namespace}:intro`, }, { - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, speaker: `${namespace}:speaker`, }, ]) diff --git a/src/data/mystery-encounters/encounters/field-trip-encounter.ts b/src/data/mystery-encounters/encounters/field-trip-encounter.ts index 0413c3d0e1d..67a7cad3466 100644 --- a/src/data/mystery-encounters/encounters/field-trip-encounter.ts +++ b/src/data/mystery-encounters/encounters/field-trip-encounter.ts @@ -56,7 +56,7 @@ export const FieldTripEncounter: MysteryEncounter = MysteryEncounterBuilder.with text: `${namespace}:intro`, }, { - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, speaker: `${namespace}:speaker`, }, ]) @@ -70,7 +70,7 @@ export const FieldTripEncounter: MysteryEncounter = MysteryEncounterBuilder.with .withDialogue({ buttonLabel: `${namespace}:option.1.label`, buttonTooltip: `${namespace}:option.1.tooltip`, - secondOptionPrompt: `${namespace}:second_option_prompt`, + secondOptionPrompt: `${namespace}:secondOptionPrompt`, }) .withPreOptionPhase(async (): Promise => { const encounter = globalScene.currentBattle.mysteryEncounter!; @@ -118,7 +118,7 @@ export const FieldTripEncounter: MysteryEncounter = MysteryEncounterBuilder.with .withDialogue({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - secondOptionPrompt: `${namespace}:second_option_prompt`, + secondOptionPrompt: `${namespace}:secondOptionPrompt`, }) .withPreOptionPhase(async (): Promise => { const encounter = globalScene.currentBattle.mysteryEncounter!; @@ -166,7 +166,7 @@ export const FieldTripEncounter: MysteryEncounter = MysteryEncounterBuilder.with .withDialogue({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - secondOptionPrompt: `${namespace}:second_option_prompt`, + secondOptionPrompt: `${namespace}:secondOptionPrompt`, }) .withPreOptionPhase(async (): Promise => { const encounter = globalScene.currentBattle.mysteryEncounter!; @@ -226,7 +226,7 @@ function pokemonAndMoveChosen(pokemon: PlayerPokemon, move: PokemonMove, correct speaker: `${namespace}:speaker`, }, { - text: `${namespace}:incorrect_exp`, + text: `${namespace}:incorrectExp`, }, ]; setEncounterExp( @@ -243,7 +243,7 @@ function pokemonAndMoveChosen(pokemon: PlayerPokemon, move: PokemonMove, correct speaker: `${namespace}:speaker`, }, { - text: `${namespace}:correct_exp`, + text: `${namespace}:correctExp`, }, ]; setEncounterExp([pokemon.id], 100); diff --git a/src/data/mystery-encounters/encounters/fiery-fallout-encounter.ts b/src/data/mystery-encounters/encounters/fiery-fallout-encounter.ts index 7d2583a00cb..cc8e147f023 100644 --- a/src/data/mystery-encounters/encounters/fiery-fallout-encounter.ts +++ b/src/data/mystery-encounters/encounters/fiery-fallout-encounter.ts @@ -247,7 +247,7 @@ export const FieryFalloutEncounter: MysteryEncounter = MysteryEncounterBuilder.w // Burn applied encounter.setDialogueToken("burnedPokemon", chosenPokemon.getNameToRender()); encounter.setDialogueToken("abilityName", allAbilities[AbilityId.HEATPROOF].name); - queueEncounterMessage(`${namespace}:option.2.target_burned`); + queueEncounterMessage(`${namespace}:option.2.targetBurned`); // Also permanently change the burned Pokemon's ability to Heatproof applyAbilityOverrideToPokemon(chosenPokemon, AbilityId.HEATPROOF); @@ -269,7 +269,7 @@ export const FieryFalloutEncounter: MysteryEncounter = MysteryEncounterBuilder.w .withDialogue({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - disabledButtonTooltip: `${namespace}:option.3.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.3.disabledTooltip`, selected: [ { text: `${namespace}:option.3.selected`, @@ -313,6 +313,6 @@ function giveLeadPokemonAttackTypeBoostItem() { const encounter = globalScene.currentBattle.mysteryEncounter!; encounter.setDialogueToken("itemName", boosterModifierType.name); encounter.setDialogueToken("leadPokemon", leadPokemon.getNameToRender()); - queueEncounterMessage(`${namespace}:found_item`); + queueEncounterMessage(`${namespace}:foundItem`); } } diff --git a/src/data/mystery-encounters/encounters/fight-or-flight-encounter.ts b/src/data/mystery-encounters/encounters/fight-or-flight-encounter.ts index 6ee2ebcdf67..f7dc89b44fd 100644 --- a/src/data/mystery-encounters/encounters/fight-or-flight-encounter.ts +++ b/src/data/mystery-encounters/encounters/fight-or-flight-encounter.ts @@ -69,7 +69,7 @@ export const FightOrFlightEncounter: MysteryEncounter = MysteryEncounterBuilder. isBoss: true, tags: [BattlerTagType.MYSTERY_ENCOUNTER_POST_SUMMON], mysteryEncounterBattleEffects: (pokemon: Pokemon) => { - queueEncounterMessage(`${namespace}:option.1.stat_boost`); + queueEncounterMessage(`${namespace}:option.1.statBoost`); // Randomly boost 1 stat 2 stages // Cannot boost Spd, Acc, or Evasion globalScene.phaseManager.unshiftNew( @@ -165,7 +165,7 @@ export const FightOrFlightEncounter: MysteryEncounter = MysteryEncounterBuilder. .withDialogue({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - disabledButtonTooltip: `${namespace}:option.2.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.2.disabledTooltip`, selected: [ { text: `${namespace}:option.2.selected`, diff --git a/src/data/mystery-encounters/encounters/fun-and-games-encounter.ts b/src/data/mystery-encounters/encounters/fun-and-games-encounter.ts index bf376c04843..71279b52cfc 100644 --- a/src/data/mystery-encounters/encounters/fun-and-games-encounter.ts +++ b/src/data/mystery-encounters/encounters/fun-and-games-encounter.ts @@ -78,7 +78,7 @@ export const FunAndGamesEncounter: MysteryEncounter = MysteryEncounterBuilder.wi .withIntroDialogue([ { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]) .setLocalizationKey(`${namespace}`) @@ -118,7 +118,7 @@ export const FunAndGamesEncounter: MysteryEncounter = MysteryEncounterBuilder.wi // Only Pokemon that are not KOed/legal can be selected const selectableFilter = (pokemon: Pokemon) => { - return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalid_selection`); + return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalidSelection`); }; return selectPokemonForOption(onPokemonSelected, undefined, selectableFilter); @@ -284,25 +284,25 @@ function handleNextTurn() { guaranteedModifierTypeFuncs: [modifierTypes.MULTI_LENS], fillRemaining: false, }); - resultMessageKey = `${namespace}:best_result`; + resultMessageKey = `${namespace}:bestResult`; } else if (healthRatio < 0.15) { // 2nd prize setEncounterRewards({ guaranteedModifierTypeFuncs: [modifierTypes.SCOPE_LENS], fillRemaining: false, }); - resultMessageKey = `${namespace}:great_result`; + resultMessageKey = `${namespace}:greatResult`; } else if (healthRatio < 0.33) { // 3rd prize setEncounterRewards({ guaranteedModifierTypeFuncs: [modifierTypes.WIDE_LENS], fillRemaining: false, }); - resultMessageKey = `${namespace}:good_result`; + resultMessageKey = `${namespace}:goodResult`; } else { // No prize isHealPhase = true; - resultMessageKey = `${namespace}:bad_result`; + resultMessageKey = `${namespace}:badResult`; } // End the battle @@ -312,7 +312,7 @@ function handleNextTurn() { globalScene.currentBattle.mysteryEncounter!.doContinueEncounter = undefined; leaveEncounterWithoutBattle(isHealPhase); // Must end the TurnInit phase prematurely so battle phases aren't added to queue - queueEncounterMessage(`${namespace}:end_game`); + queueEncounterMessage(`${namespace}:endGame`); queueEncounterMessage(resultMessageKey); // Skip remainder of TurnInitPhase @@ -320,9 +320,9 @@ function handleNextTurn() { } if (encounter.misc.turnsRemaining < 3) { // Display charging messages on turns that aren't the initial turn - queueEncounterMessage(`${namespace}:charging_continue`); + queueEncounterMessage(`${namespace}:chargingContinue`); } - queueEncounterMessage(`${namespace}:turn_remaining_${encounter.misc.turnsRemaining}`); + queueEncounterMessage(`${namespace}:turnRemaining${encounter.misc.turnsRemaining}`); encounter.misc.turnsRemaining--; // Don't skip remainder of TurnInitPhase diff --git a/src/data/mystery-encounters/encounters/global-trade-system-encounter.ts b/src/data/mystery-encounters/encounters/global-trade-system-encounter.ts index ed49fccf190..11e5c036409 100644 --- a/src/data/mystery-encounters/encounters/global-trade-system-encounter.ts +++ b/src/data/mystery-encounters/encounters/global-trade-system-encounter.ts @@ -158,7 +158,7 @@ export const GlobalTradeSystemEncounter: MysteryEncounter = MysteryEncounterBuil .withDialogue({ buttonLabel: `${namespace}:option.1.label`, buttonTooltip: `${namespace}:option.1.tooltip`, - secondOptionPrompt: `${namespace}:option.1.trade_options_prompt`, + secondOptionPrompt: `${namespace}:option.1.tradeOptionsPrompt`, }) .withPreOptionPhase(async (): Promise => { const encounter = globalScene.currentBattle.mysteryEncounter!; @@ -248,7 +248,7 @@ export const GlobalTradeSystemEncounter: MysteryEncounter = MysteryEncounterBuil // Show the trade animation await showTradeBackground(); await doPokemonTradeSequence(tradedPokemon, newPlayerPokemon); - await showEncounterText(`${namespace}:trade_received`, null, 0, true, 4000); + await showEncounterText(`${namespace}:tradeReceived`, null, 0, true, 4000); globalScene.playBgm(encounter.misc.bgmKey); await addPokemonDataToDexAndValidateAchievements(newPlayerPokemon); await hideTradeBackground(); @@ -369,7 +369,7 @@ export const GlobalTradeSystemEncounter: MysteryEncounter = MysteryEncounterBuil // Show the trade animation await showTradeBackground(); await doPokemonTradeSequence(tradedPokemon, newPlayerPokemon); - await showEncounterText(`${namespace}:trade_received`, null, 0, true, 4000); + await showEncounterText(`${namespace}:tradeReceived`, null, 0, true, 4000); globalScene.playBgm(encounter.misc.bgmKey); await addPokemonDataToDexAndValidateAchievements(newPlayerPokemon); await hideTradeBackground(); @@ -384,7 +384,7 @@ export const GlobalTradeSystemEncounter: MysteryEncounter = MysteryEncounterBuil .withDialogue({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - secondOptionPrompt: `${namespace}:option.3.trade_options_prompt`, + secondOptionPrompt: `${namespace}:option.3.tradeOptionsPrompt`, }) .withPreOptionPhase(async (): Promise => { const encounter = globalScene.currentBattle.mysteryEncounter!; @@ -416,7 +416,7 @@ export const GlobalTradeSystemEncounter: MysteryEncounter = MysteryEncounterBuil return it.isTransferable; }).length > 0; if (!meetsReqs) { - return getEncounterText(`${namespace}:option.3.invalid_selection`) ?? null; + return getEncounterText(`${namespace}:option.3.invalidSelection`) ?? null; } return null; @@ -468,7 +468,7 @@ export const GlobalTradeSystemEncounter: MysteryEncounter = MysteryEncounterBuil // Generate a trainer name const traderName = generateRandomTraderName(); encounter.setDialogueToken("tradeTrainerName", traderName.trim()); - await showEncounterText(`${namespace}:item_trade_selected`); + await showEncounterText(`${namespace}:itemTradeSelected`); leaveEncounterWithoutBattle(); }) .build(), @@ -740,10 +740,10 @@ function doPokemonTradeSequence(tradedPokemon: PlayerPokemon, receivedPokemon: P duration: 500, onComplete: async () => { globalScene.fadeOutBgm(1000, false); - await showEncounterText(`${namespace}:pokemon_trade_selected`); + await showEncounterText(`${namespace}:pokemonTradeSelected`); tradedPokemon.cry(); globalScene.playBgm("evolution"); - await showEncounterText(`${namespace}:pokemon_trade_goodbye`); + await showEncounterText(`${namespace}:pokemonTradeGoodbye`); tradedPokeball.setAlpha(0); tradedPokeball.setVisible(true); diff --git a/src/data/mystery-encounters/encounters/lost-at-sea-encounter.ts b/src/data/mystery-encounters/encounters/lost-at-sea-encounter.ts index 10f45c21b68..f1c79208911 100644 --- a/src/data/mystery-encounters/encounters/lost-at-sea-encounter.ts +++ b/src/data/mystery-encounters/encounters/lost-at-sea-encounter.ts @@ -63,9 +63,9 @@ export const LostAtSeaEncounter: MysteryEncounter = MysteryEncounterBuilder.with .withPokemonCanLearnMoveRequirement(OPTION_1_REQUIRED_MOVE) .withDialogue({ buttonLabel: `${namespace}:option.1.label`, - disabledButtonLabel: `${namespace}:option.1.label_disabled`, + disabledButtonLabel: `${namespace}:option.1.labelDisabled`, buttonTooltip: `${namespace}:option.1.tooltip`, - disabledButtonTooltip: `${namespace}:option.1.tooltip_disabled`, + disabledButtonTooltip: `${namespace}:option.1.tooltipDisabled`, selected: [ { text: `${namespace}:option.1.selected`, @@ -81,9 +81,9 @@ export const LostAtSeaEncounter: MysteryEncounter = MysteryEncounterBuilder.with .withPokemonCanLearnMoveRequirement(OPTION_2_REQUIRED_MOVE) .withDialogue({ buttonLabel: `${namespace}:option.2.label`, - disabledButtonLabel: `${namespace}:option.2.label_disabled`, + disabledButtonLabel: `${namespace}:option.2.labelDisabled`, buttonTooltip: `${namespace}:option.2.tooltip`, - disabledButtonTooltip: `${namespace}:option.2.tooltip_disabled`, + disabledButtonTooltip: `${namespace}:option.2.tooltipDisabled`, selected: [ { text: `${namespace}:option.2.selected`, diff --git a/src/data/mystery-encounters/encounters/part-timer-encounter.ts b/src/data/mystery-encounters/encounters/part-timer-encounter.ts index a865de3b19d..d6dfc635608 100644 --- a/src/data/mystery-encounters/encounters/part-timer-encounter.ts +++ b/src/data/mystery-encounters/encounters/part-timer-encounter.ts @@ -58,7 +58,7 @@ export const PartTimerEncounter: MysteryEncounter = MysteryEncounterBuilder.with }, { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]) .withOnInit(() => { @@ -128,7 +128,7 @@ export const PartTimerEncounter: MysteryEncounter = MysteryEncounterBuilder.with // Only Pokemon non-KOd pokemon can be selected const selectableFilter = (pokemon: Pokemon) => { - return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalid_selection`); + return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalidSelection`); }; return selectPokemonForOption(onPokemonSelected, undefined, selectableFilter); @@ -142,9 +142,9 @@ export const PartTimerEncounter: MysteryEncounter = MysteryEncounterBuilder.with // Give money and do dialogue if (moneyMultiplier > 2.5) { - await showEncounterDialogue(`${namespace}:job_complete_good`, `${namespace}:speaker`); + await showEncounterDialogue(`${namespace}:jobCompleteGood`, `${namespace}:speaker`); } else { - await showEncounterDialogue(`${namespace}:job_complete_bad`, `${namespace}:speaker`); + await showEncounterDialogue(`${namespace}:jobCompleteBad`, `${namespace}:speaker`); } const moneyChange = globalScene.getWaveMoneyAmount(moneyMultiplier); updatePlayerMoney(moneyChange, true, false); @@ -153,7 +153,7 @@ export const PartTimerEncounter: MysteryEncounter = MysteryEncounterBuilder.with amount: moneyChange, }), ); - await showEncounterText(`${namespace}:pokemon_tired`); + await showEncounterText(`${namespace}:pokemonTired`); setEncounterRewards({ fillRemaining: true }); leaveEncounterWithoutBattle(); @@ -210,7 +210,7 @@ export const PartTimerEncounter: MysteryEncounter = MysteryEncounterBuilder.with // Only Pokemon non-KOd pokemon can be selected const selectableFilter = (pokemon: Pokemon) => { - return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalid_selection`); + return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalidSelection`); }; return selectPokemonForOption(onPokemonSelected, undefined, selectableFilter); @@ -224,9 +224,9 @@ export const PartTimerEncounter: MysteryEncounter = MysteryEncounterBuilder.with // Give money and do dialogue if (moneyMultiplier > 2.5) { - await showEncounterDialogue(`${namespace}:job_complete_good`, `${namespace}:speaker`); + await showEncounterDialogue(`${namespace}:jobCompleteGood`, `${namespace}:speaker`); } else { - await showEncounterDialogue(`${namespace}:job_complete_bad`, `${namespace}:speaker`); + await showEncounterDialogue(`${namespace}:jobCompleteBad`, `${namespace}:speaker`); } const moneyChange = globalScene.getWaveMoneyAmount(moneyMultiplier); updatePlayerMoney(moneyChange, true, false); @@ -235,7 +235,7 @@ export const PartTimerEncounter: MysteryEncounter = MysteryEncounterBuilder.with amount: moneyChange, }), ); - await showEncounterText(`${namespace}:pokemon_tired`); + await showEncounterText(`${namespace}:pokemonTired`); setEncounterRewards({ fillRemaining: true }); leaveEncounterWithoutBattle(); @@ -248,7 +248,7 @@ export const PartTimerEncounter: MysteryEncounter = MysteryEncounterBuilder.with .withDialogue({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - disabledButtonTooltip: `${namespace}:option.3.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.3.disabledTooltip`, selected: [ { text: `${namespace}:option.3.selected`, @@ -282,7 +282,7 @@ export const PartTimerEncounter: MysteryEncounter = MysteryEncounterBuilder.with await transitionMysteryEncounterIntroVisuals(false, false); // Give money and do dialogue - await showEncounterDialogue(`${namespace}:job_complete_good`, `${namespace}:speaker`); + await showEncounterDialogue(`${namespace}:jobCompleteGood`, `${namespace}:speaker`); const moneyChange = globalScene.getWaveMoneyAmount(2.5); updatePlayerMoney(moneyChange, true, false); await showEncounterText( @@ -290,7 +290,7 @@ export const PartTimerEncounter: MysteryEncounter = MysteryEncounterBuilder.with amount: moneyChange, }), ); - await showEncounterText(`${namespace}:pokemon_tired`); + await showEncounterText(`${namespace}:pokemonTired`); setEncounterRewards({ fillRemaining: true }); leaveEncounterWithoutBattle(); diff --git a/src/data/mystery-encounters/encounters/safari-zone-encounter.ts b/src/data/mystery-encounters/encounters/safari-zone-encounter.ts index c3400b41327..764951877f0 100644 --- a/src/data/mystery-encounters/encounters/safari-zone-encounter.ts +++ b/src/data/mystery-encounters/encounters/safari-zone-encounter.ts @@ -205,7 +205,7 @@ const safariZoneGameOptions: MysteryEncounterOption[] = [ // 80% chance to increase flee stage +1 const fleeChangeResult = tryChangeFleeStage(1, 8); if (!fleeChangeResult) { - await showEncounterText(getEncounterText(`${namespace}:safari.busy_eating`) ?? "", null, 1000, false); + await showEncounterText(getEncounterText(`${namespace}:safari.busyEating`) ?? "", null, 1000, false); } else { await showEncounterText(getEncounterText(`${namespace}:safari.eating`) ?? "", null, 1000, false); } @@ -233,7 +233,7 @@ const safariZoneGameOptions: MysteryEncounterOption[] = [ // 80% chance to decrease catch stage -1 const catchChangeResult = tryChangeCatchStage(-1, 8); if (!catchChangeResult) { - await showEncounterText(getEncounterText(`${namespace}:safari.beside_itself_angry`) ?? "", null, 1000, false); + await showEncounterText(getEncounterText(`${namespace}:safari.besideItselfAngry`) ?? "", null, 1000, false); } else { await showEncounterText(getEncounterText(`${namespace}:safari.angry`) ?? "", null, 1000, false); } @@ -274,7 +274,7 @@ async function summonSafariPokemon() { const encounter = globalScene.currentBattle.mysteryEncounter!; // Message pokemon remaining encounter.setDialogueToken("remainingCount", encounter.misc.safariPokemonRemaining); - globalScene.phaseManager.queueMessage(getEncounterText(`${namespace}:safari.remaining_count`) ?? "", null, true); + globalScene.phaseManager.queueMessage(getEncounterText(`${namespace}:safari.remainingCount`) ?? "", null, true); // Generate pokemon using safariPokemonRemaining so they are always the same pokemon no matter how many turns are taken // Safari pokemon roll twice on shiny and HA chances, but are otherwise normal diff --git a/src/data/mystery-encounters/encounters/shady-vitamin-dealer-encounter.ts b/src/data/mystery-encounters/encounters/shady-vitamin-dealer-encounter.ts index 47317c12b50..bf232c616d5 100644 --- a/src/data/mystery-encounters/encounters/shady-vitamin-dealer-encounter.ts +++ b/src/data/mystery-encounters/encounters/shady-vitamin-dealer-encounter.ts @@ -70,7 +70,7 @@ export const ShadyVitaminDealerEncounter: MysteryEncounter = MysteryEncounterBui text: `${namespace}:intro`, }, { - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, speaker: `${namespace}:speaker`, }, ]) @@ -119,7 +119,7 @@ export const ShadyVitaminDealerEncounter: MysteryEncounter = MysteryEncounterBui ); } if (!encounter.pokemonMeetsPrimaryRequirements(pokemon)) { - return getEncounterText(`${namespace}:invalid_selection`) ?? null; + return getEncounterText(`${namespace}:invalidSelection`) ?? null; } return null; @@ -155,7 +155,7 @@ export const ShadyVitaminDealerEncounter: MysteryEncounter = MysteryEncounterBui chosenPokemon.setCustomNature(newNature); encounter.setDialogueToken("newNature", getNatureName(newNature)); - queueEncounterMessage(`${namespace}:cheap_side_effects`); + queueEncounterMessage(`${namespace}:cheapSideEffects`); setEncounterExp([chosenPokemon.id], 100); await chosenPokemon.updateInfo(); }) @@ -193,7 +193,7 @@ export const ShadyVitaminDealerEncounter: MysteryEncounter = MysteryEncounterBui // Only Pokemon that can gain benefits are unfainted const selectableFilter = (pokemon: Pokemon) => { - return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalid_selection`); + return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalidSelection`); }; return selectPokemonForOption(onPokemonSelected, undefined, selectableFilter); @@ -215,7 +215,7 @@ export const ShadyVitaminDealerEncounter: MysteryEncounter = MysteryEncounterBui const encounter = globalScene.currentBattle.mysteryEncounter!; const chosenPokemon = encounter.misc.chosenPokemon; - queueEncounterMessage(`${namespace}:no_bad_effects`); + queueEncounterMessage(`${namespace}:noBadEffects`); setEncounterExp([chosenPokemon.id], 100); await chosenPokemon.updateInfo(); diff --git a/src/data/mystery-encounters/encounters/slumbering-snorlax-encounter.ts b/src/data/mystery-encounters/encounters/slumbering-snorlax-encounter.ts index cddfef1ef76..8c367882445 100644 --- a/src/data/mystery-encounters/encounters/slumbering-snorlax-encounter.ts +++ b/src/data/mystery-encounters/encounters/slumbering-snorlax-encounter.ts @@ -157,7 +157,7 @@ export const SlumberingSnorlaxEncounter: MysteryEncounter = MysteryEncounterBuil // Fall asleep waiting for Snorlax // Full heal party globalScene.phaseManager.unshiftNew("PartyHealPhase", true); - queueEncounterMessage(`${namespace}:option.2.rest_result`); + queueEncounterMessage(`${namespace}:option.2.restResult`); leaveEncounterWithoutBattle(); }, ) @@ -167,7 +167,7 @@ export const SlumberingSnorlaxEncounter: MysteryEncounter = MysteryEncounterBuil .withDialogue({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - disabledButtonTooltip: `${namespace}:option.3.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.3.disabledTooltip`, selected: [ { text: `${namespace}:option.3.selected`, diff --git a/src/data/mystery-encounters/encounters/teleporting-hijinks-encounter.ts b/src/data/mystery-encounters/encounters/teleporting-hijinks-encounter.ts index d77326837cd..58ab3f2ec2d 100644 --- a/src/data/mystery-encounters/encounters/teleporting-hijinks-encounter.ts +++ b/src/data/mystery-encounters/encounters/teleporting-hijinks-encounter.ts @@ -122,7 +122,7 @@ export const TeleportingHijinksEncounter: MysteryEncounter = MysteryEncounterBui .withDialogue({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - disabledButtonTooltip: `${namespace}:option.2.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.2.disabledTooltip`, selected: [ { text: `${namespace}:option.2.selected`, @@ -227,7 +227,7 @@ async function doBiomeTransitionDialogueAndBattleInit() { isBoss: true, tags: [BattlerTagType.MYSTERY_ENCOUNTER_POST_SUMMON], mysteryEncounterBattleEffects: (pokemon: Pokemon) => { - queueEncounterMessage(`${namespace}:boss_enraged`); + queueEncounterMessage(`${namespace}:bossEnraged`); globalScene.phaseManager.unshiftNew( "StatStageChangePhase", pokemon.getBattlerIndex(), diff --git a/src/data/mystery-encounters/encounters/the-expert-pokemon-breeder-encounter.ts b/src/data/mystery-encounters/encounters/the-expert-pokemon-breeder-encounter.ts index 7c528e2305b..6d0ff11f07a 100644 --- a/src/data/mystery-encounters/encounters/the-expert-pokemon-breeder-encounter.ts +++ b/src/data/mystery-encounters/encounters/the-expert-pokemon-breeder-encounter.ts @@ -139,7 +139,7 @@ export const TheExpertPokemonBreederEncounter: MysteryEncounter = MysteryEncount }, { speaker: trainerNameKey, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]) .withOnInit(() => { @@ -189,13 +189,13 @@ export const TheExpertPokemonBreederEncounter: MysteryEncounter = MysteryEncount // Dialogue and egg calcs for Pokemon 1 const [pokemon1CommonEggs, pokemon1RareEggs] = calculateEggRewardsForPokemon(pokemon1); - let pokemon1Tooltip = getEncounterText(`${namespace}:option.1.tooltip_base`)!; + let pokemon1Tooltip = getEncounterText(`${namespace}:option.1.tooltipBase`)!; if (pokemon1RareEggs > 0) { const eggsText = i18next.t(`${namespace}:numEggs`, { count: pokemon1RareEggs, rarity: i18next.t("egg:greatTier"), }); - pokemon1Tooltip += i18next.t(`${namespace}:eggs_tooltip`, { + pokemon1Tooltip += i18next.t(`${namespace}:eggsTooltip`, { eggs: eggsText, }); encounter.setDialogueToken("pokemon1RareEggs", eggsText); @@ -205,7 +205,7 @@ export const TheExpertPokemonBreederEncounter: MysteryEncounter = MysteryEncount count: pokemon1CommonEggs, rarity: i18next.t("egg:defaultTier"), }); - pokemon1Tooltip += i18next.t(`${namespace}:eggs_tooltip`, { + pokemon1Tooltip += i18next.t(`${namespace}:eggsTooltip`, { eggs: eggsText, }); encounter.setDialogueToken("pokemon1CommonEggs", eggsText); @@ -214,13 +214,13 @@ export const TheExpertPokemonBreederEncounter: MysteryEncounter = MysteryEncount // Dialogue and egg calcs for Pokemon 2 const [pokemon2CommonEggs, pokemon2RareEggs] = calculateEggRewardsForPokemon(pokemon2); - let pokemon2Tooltip = getEncounterText(`${namespace}:option.2.tooltip_base`)!; + let pokemon2Tooltip = getEncounterText(`${namespace}:option.2.tooltipBase`)!; if (pokemon2RareEggs > 0) { const eggsText = i18next.t(`${namespace}:numEggs`, { count: pokemon2RareEggs, rarity: i18next.t("egg:greatTier"), }); - pokemon2Tooltip += i18next.t(`${namespace}:eggs_tooltip`, { + pokemon2Tooltip += i18next.t(`${namespace}:eggsTooltip`, { eggs: eggsText, }); encounter.setDialogueToken("pokemon2RareEggs", eggsText); @@ -230,7 +230,7 @@ export const TheExpertPokemonBreederEncounter: MysteryEncounter = MysteryEncount count: pokemon2CommonEggs, rarity: i18next.t("egg:defaultTier"), }); - pokemon2Tooltip += i18next.t(`${namespace}:eggs_tooltip`, { + pokemon2Tooltip += i18next.t(`${namespace}:eggsTooltip`, { eggs: eggsText, }); encounter.setDialogueToken("pokemon2CommonEggs", eggsText); @@ -239,13 +239,13 @@ export const TheExpertPokemonBreederEncounter: MysteryEncounter = MysteryEncount // Dialogue and egg calcs for Pokemon 3 const [pokemon3CommonEggs, pokemon3RareEggs] = calculateEggRewardsForPokemon(pokemon3); - let pokemon3Tooltip = getEncounterText(`${namespace}:option.3.tooltip_base`)!; + let pokemon3Tooltip = getEncounterText(`${namespace}:option.3.tooltipBase`)!; if (pokemon3RareEggs > 0) { const eggsText = i18next.t(`${namespace}:numEggs`, { count: pokemon3RareEggs, rarity: i18next.t("egg:greatTier"), }); - pokemon3Tooltip += i18next.t(`${namespace}:eggs_tooltip`, { + pokemon3Tooltip += i18next.t(`${namespace}:eggsTooltip`, { eggs: eggsText, }); encounter.setDialogueToken("pokemon3RareEggs", eggsText); @@ -255,7 +255,7 @@ export const TheExpertPokemonBreederEncounter: MysteryEncounter = MysteryEncount count: pokemon3CommonEggs, rarity: i18next.t("egg:defaultTier"), }); - pokemon3Tooltip += i18next.t(`${namespace}:eggs_tooltip`, { + pokemon3Tooltip += i18next.t(`${namespace}:eggsTooltip`, { eggs: eggsText, }); encounter.setDialogueToken("pokemon3CommonEggs", eggsText); @@ -321,14 +321,14 @@ export const TheExpertPokemonBreederEncounter: MysteryEncounter = MysteryEncount ]; if (encounter.dialogueTokens.hasOwnProperty("pokemon1CommonEggs")) { encounter.dialogue.outro.push({ - text: i18next.t(`${namespace}:gained_eggs`, { + text: i18next.t(`${namespace}:gainedEggs`, { numEggs: encounter.dialogueTokens["pokemon1CommonEggs"], }), }); } if (encounter.dialogueTokens.hasOwnProperty("pokemon1RareEggs")) { encounter.dialogue.outro.push({ - text: i18next.t(`${namespace}:gained_eggs`, { + text: i18next.t(`${namespace}:gainedEggs`, { numEggs: encounter.dialogueTokens["pokemon1RareEggs"], }), }); @@ -380,14 +380,14 @@ export const TheExpertPokemonBreederEncounter: MysteryEncounter = MysteryEncount ]; if (encounter.dialogueTokens.hasOwnProperty("pokemon2CommonEggs")) { encounter.dialogue.outro.push({ - text: i18next.t(`${namespace}:gained_eggs`, { + text: i18next.t(`${namespace}:gainedEggs`, { numEggs: encounter.dialogueTokens["pokemon2CommonEggs"], }), }); } if (encounter.dialogueTokens.hasOwnProperty("pokemon2RareEggs")) { encounter.dialogue.outro.push({ - text: i18next.t(`${namespace}:gained_eggs`, { + text: i18next.t(`${namespace}:gainedEggs`, { numEggs: encounter.dialogueTokens["pokemon2RareEggs"], }), }); @@ -439,14 +439,14 @@ export const TheExpertPokemonBreederEncounter: MysteryEncounter = MysteryEncount ]; if (encounter.dialogueTokens.hasOwnProperty("pokemon3CommonEggs")) { encounter.dialogue.outro.push({ - text: i18next.t(`${namespace}:gained_eggs`, { + text: i18next.t(`${namespace}:gainedEggs`, { numEggs: encounter.dialogueTokens["pokemon3CommonEggs"], }), }); } if (encounter.dialogueTokens.hasOwnProperty("pokemon3RareEggs")) { encounter.dialogue.outro.push({ - text: i18next.t(`${namespace}:gained_eggs`, { + text: i18next.t(`${namespace}:gainedEggs`, { numEggs: encounter.dialogueTokens["pokemon3RareEggs"], }), }); @@ -482,7 +482,7 @@ function getPartyConfig(): EnemyPartyConfig { trainerType: TrainerType.EXPERT_POKEMON_BREEDER, pokemonConfigs: [ { - nickname: i18next.t(`${namespace}:cleffa_1_nickname`, { + nickname: i18next.t(`${namespace}:cleffa1Nickname`, { speciesName: getPokemonSpecies(cleffaSpecies).getName(), }), species: getPokemonSpecies(cleffaSpecies), @@ -501,7 +501,7 @@ function getPartyConfig(): EnemyPartyConfig { // All 3 members always Cleffa line, but different configs baseConfig.pokemonConfigs!.push( { - nickname: i18next.t(`${namespace}:cleffa_2_nickname`, { + nickname: i18next.t(`${namespace}:cleffa2Nickname`, { speciesName: getPokemonSpecies(cleffaSpecies).getName(), }), species: getPokemonSpecies(cleffaSpecies), @@ -514,7 +514,7 @@ function getPartyConfig(): EnemyPartyConfig { ivs: [31, 31, 31, 31, 31, 31], }, { - nickname: i18next.t(`${namespace}:cleffa_3_nickname`, { + nickname: i18next.t(`${namespace}:cleffa3Nickname`, { speciesName: getPokemonSpecies(cleffaSpecies).getName(), }), species: getPokemonSpecies(cleffaSpecies), @@ -647,7 +647,7 @@ function onGameOver() { encounter.dialogue.outro = [ { speaker: trainerNameKey, - text: `${namespace}:outro_failed`, + text: `${namespace}:outroFailed`, }, ]; diff --git a/src/data/mystery-encounters/encounters/the-pokemon-salesman-encounter.ts b/src/data/mystery-encounters/encounters/the-pokemon-salesman-encounter.ts index 91662993a51..99f6e671052 100644 --- a/src/data/mystery-encounters/encounters/the-pokemon-salesman-encounter.ts +++ b/src/data/mystery-encounters/encounters/the-pokemon-salesman-encounter.ts @@ -66,7 +66,7 @@ export const ThePokemonSalesmanEncounter: MysteryEncounter = MysteryEncounterBui text: `${namespace}:intro`, }, { - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, speaker: `${namespace}:speaker`, }, ]) @@ -178,8 +178,8 @@ export const ThePokemonSalesmanEncounter: MysteryEncounter = MysteryEncounterBui // Always max price for shiny (flip HA back to normal), and add special messaging priceMultiplier = MAX_POKEMON_PRICE_MULTIPLIER; pokemon.abilityIndex = 0; - encounter.dialogue.encounterOptionsDialogue!.description = `${namespace}:description_shiny`; - encounter.options[0].dialogue!.buttonTooltip = `${namespace}:option.1.tooltip_shiny`; + encounter.dialogue.encounterOptionsDialogue!.description = `${namespace}:descriptionShiny`; + encounter.options[0].dialogue!.buttonTooltip = `${namespace}:option.1.tooltipShiny`; } const price = globalScene.getWaveMoneyAmount(priceMultiplier); encounter.setDialogueToken("purchasePokemon", pokemon.getNameToRender()); @@ -202,7 +202,7 @@ export const ThePokemonSalesmanEncounter: MysteryEncounter = MysteryEncounterBui buttonTooltip: `${namespace}:option.1.tooltip`, selected: [ { - text: `${namespace}:option.1.selected_message`, + text: `${namespace}:option.1.selectedMessage`, }, ], }) @@ -215,7 +215,7 @@ export const ThePokemonSalesmanEncounter: MysteryEncounter = MysteryEncounterBui updatePlayerMoney(-price, true, false); // Show dialogue - await showEncounterDialogue(`${namespace}:option.1.selected_dialogue`, `${namespace}:speaker`); + await showEncounterDialogue(`${namespace}:option.1.selectedDialogue`, `${namespace}:speaker`); await transitionMysteryEncounterIntroVisuals(); // "Catch" purchased pokemon diff --git a/src/data/mystery-encounters/encounters/the-strong-stuff-encounter.ts b/src/data/mystery-encounters/encounters/the-strong-stuff-encounter.ts index 568dc5de8b1..89bfc659944 100644 --- a/src/data/mystery-encounters/encounters/the-strong-stuff-encounter.ts +++ b/src/data/mystery-encounters/encounters/the-strong-stuff-encounter.ts @@ -115,7 +115,7 @@ export const TheStrongStuffEncounter: MysteryEncounter = MysteryEncounterBuilder ], tags: [BattlerTagType.MYSTERY_ENCOUNTER_POST_SUMMON], mysteryEncounterBattleEffects: (pokemon: Pokemon) => { - queueEncounterMessage(`${namespace}:option.2.stat_boost`); + queueEncounterMessage(`${namespace}:option.2.statBoost`); globalScene.phaseManager.unshiftNew( "StatStageChangePhase", pokemon.getBattlerIndex(), @@ -181,7 +181,7 @@ export const TheStrongStuffEncounter: MysteryEncounter = MysteryEncounterBuilder encounter.setDialogueToken("reductionValue", HIGH_BST_REDUCTION_VALUE.toString()); encounter.setDialogueToken("increaseValue", BST_INCREASE_VALUE.toString()); - await showEncounterText(`${namespace}:option.1.selected_2`, null, undefined, true); + await showEncounterText(`${namespace}:option.1.selected2`, null, undefined, true); encounter.dialogue.outro = [ { diff --git a/src/data/mystery-encounters/encounters/the-winstrate-challenge-encounter.ts b/src/data/mystery-encounters/encounters/the-winstrate-challenge-encounter.ts index e17bf0575d7..71fe961f053 100644 --- a/src/data/mystery-encounters/encounters/the-winstrate-challenge-encounter.ts +++ b/src/data/mystery-encounters/encounters/the-winstrate-challenge-encounter.ts @@ -87,7 +87,7 @@ export const TheWinstrateChallengeEncounter: MysteryEncounter = MysteryEncounter }, { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]) .withAutoHideIntroVisuals(false) @@ -163,7 +163,7 @@ async function spawnNextTrainerOrEndEncounter() { globalScene.playSound("item_fanfare"); await showEncounterText(i18next.t("battle:rewardGain", { modifierName: newModifier?.type.name })); - await showEncounterDialogue(`${namespace}:victory_2`, `${namespace}:speaker`); + await showEncounterDialogue(`${namespace}:victory2`, `${namespace}:speaker`); globalScene.ui.clearText(); // Clears "Winstrate" title from screen as rewards get animated in const machoBrace = generateModifierTypeOption(modifierTypes.MYSTERY_ENCOUNTER_MACHO_BRACE)!; machoBrace.type.tier = ModifierTier.MASTER; diff --git a/src/data/mystery-encounters/encounters/training-session-encounter.ts b/src/data/mystery-encounters/encounters/training-session-encounter.ts index e56c42a3ee5..b8173aa5fed 100644 --- a/src/data/mystery-encounters/encounters/training-session-encounter.ts +++ b/src/data/mystery-encounters/encounters/training-session-encounter.ts @@ -90,7 +90,7 @@ export const TrainingSessionEncounter: MysteryEncounter = MysteryEncounterBuilde // Only Pokemon that are not KOed/legal can be trained const selectableFilter = (pokemon: Pokemon) => { - return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalid_selection`); + return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalidSelection`); }; return selectPokemonForOption(onPokemonSelected, undefined, selectableFilter); @@ -174,7 +174,7 @@ export const TrainingSessionEncounter: MysteryEncounter = MysteryEncounterBuilde .withDialogue({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - secondOptionPrompt: `${namespace}:option.2.select_prompt`, + secondOptionPrompt: `${namespace}:option.2.selectPrompt`, selected: [ { text: `${namespace}:option.selected`, @@ -205,7 +205,7 @@ export const TrainingSessionEncounter: MysteryEncounter = MysteryEncounterBuilde // Only Pokemon that are not KOed/legal can be trained const selectableFilter = (pokemon: Pokemon) => { - return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalid_selection`); + return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalidSelection`); }; return selectPokemonForOption(onPokemonSelected, undefined, selectableFilter); @@ -248,7 +248,7 @@ export const TrainingSessionEncounter: MysteryEncounter = MysteryEncounterBuilde .withDialogue({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - secondOptionPrompt: `${namespace}:option.3.select_prompt`, + secondOptionPrompt: `${namespace}:option.3.selectPrompt`, selected: [ { text: `${namespace}:option.selected`, @@ -295,7 +295,7 @@ export const TrainingSessionEncounter: MysteryEncounter = MysteryEncounterBuilde // Only Pokemon that are not KOed/legal can be trained const selectableFilter = (pokemon: Pokemon) => { - return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalid_selection`); + return isPokemonValidForEncounterOptionSelection(pokemon, `${namespace}:invalidSelection`); }; return selectPokemonForOption(onPokemonSelected, undefined, selectableFilter); diff --git a/src/data/mystery-encounters/encounters/trash-to-treasure-encounter.ts b/src/data/mystery-encounters/encounters/trash-to-treasure-encounter.ts index 74a36a280d3..84567844a04 100644 --- a/src/data/mystery-encounters/encounters/trash-to-treasure-encounter.ts +++ b/src/data/mystery-encounters/encounters/trash-to-treasure-encounter.ts @@ -194,7 +194,7 @@ export const TrashToTreasureEncounter: MysteryEncounter = MysteryEncounterBuilde .withOptionPhase(async () => { // Investigate garbage, battle Gmax Garbodor globalScene.setFieldScale(0.75); - await showEncounterText(`${namespace}:option.2.selected_2`); + await showEncounterText(`${namespace}:option.2.selected2`); await transitionMysteryEncounterIntroVisuals(); const encounter = globalScene.currentBattle.mysteryEncounter!; diff --git a/src/data/mystery-encounters/encounters/uncommon-breed-encounter.ts b/src/data/mystery-encounters/encounters/uncommon-breed-encounter.ts index c9e2ffedeec..6aeff852de7 100644 --- a/src/data/mystery-encounters/encounters/uncommon-breed-encounter.ts +++ b/src/data/mystery-encounters/encounters/uncommon-breed-encounter.ts @@ -97,7 +97,7 @@ export const UncommonBreedEncounter: MysteryEncounter = MysteryEncounterBuilder. isBoss: false, tags: [BattlerTagType.MYSTERY_ENCOUNTER_POST_SUMMON], mysteryEncounterBattleEffects: (pokemon: Pokemon) => { - queueEncounterMessage(`${namespace}:option.1.stat_boost`); + queueEncounterMessage(`${namespace}:option.1.statBoost`); globalScene.phaseManager.unshiftNew( "StatStageChangePhase", pokemon.getBattlerIndex(), @@ -191,7 +191,7 @@ export const UncommonBreedEncounter: MysteryEncounter = MysteryEncounterBuilder. .withDialogue({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - disabledButtonTooltip: `${namespace}:option.2.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.2.disabledTooltip`, selected: [ { text: `${namespace}:option.2.selected`, @@ -236,7 +236,7 @@ export const UncommonBreedEncounter: MysteryEncounter = MysteryEncounterBuilder. .withDialogue({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - disabledButtonTooltip: `${namespace}:option.3.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.3.disabledTooltip`, selected: [ { text: `${namespace}:option.3.selected`, diff --git a/src/data/mystery-encounters/encounters/weird-dream-encounter.ts b/src/data/mystery-encounters/encounters/weird-dream-encounter.ts index 57b066e2ba2..790bdf0dbef 100644 --- a/src/data/mystery-encounters/encounters/weird-dream-encounter.ts +++ b/src/data/mystery-encounters/encounters/weird-dream-encounter.ts @@ -143,7 +143,7 @@ export const WeirdDreamEncounter: MysteryEncounter = MysteryEncounterBuilder.wit }, { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]) .setLocalizationKey(`${namespace}`) @@ -216,7 +216,7 @@ export const WeirdDreamEncounter: MysteryEncounter = MysteryEncounterBuilder.wit await cutsceneDialoguePromise; doHideDreamBackground(); - await showEncounterText(`${namespace}:option.1.dream_complete`); + await showEncounterText(`${namespace}:option.1.dreamComplete`); await doNewTeamPostProcess(transformations); setEncounterRewards({ @@ -329,7 +329,7 @@ export const WeirdDreamEncounter: MysteryEncounter = MysteryEncounterBuilder.wit onBeforeRewards, ); - await showEncounterText(`${namespace}:option.2.selected_2`, null, undefined, true); + await showEncounterText(`${namespace}:option.2.selected2`, null, undefined, true); await initBattleWithEnemyConfig(enemyPartyConfig); }, ) diff --git a/test/mystery-encounter/encounters/an-offer-you-cant-refuse-encounter.test.ts b/test/mystery-encounter/encounters/an-offer-you-cant-refuse-encounter.test.ts index d903568785a..dfd102daa43 100644 --- a/test/mystery-encounter/encounters/an-offer-you-cant-refuse-encounter.test.ts +++ b/test/mystery-encounter/encounters/an-offer-you-cant-refuse-encounter.test.ts @@ -66,7 +66,7 @@ describe("An Offer You Can't Refuse - Mystery Encounter", () => { expect(AnOfferYouCantRefuseEncounter.dialogue).toBeDefined(); expect(AnOfferYouCantRefuseEncounter.dialogue.intro).toStrictEqual([ { text: `${namespace}:intro` }, - { speaker: `${namespace}:speaker`, text: `${namespace}:intro_dialogue` }, + { speaker: `${namespace}:speaker`, text: `${namespace}:introDialogue` }, ]); expect(AnOfferYouCantRefuseEncounter.dialogue.encounterOptionsDialogue?.title).toBe(`${namespace}:title`); expect(AnOfferYouCantRefuseEncounter.dialogue.encounterOptionsDialogue?.description).toBe( @@ -180,7 +180,7 @@ describe("An Offer You Can't Refuse - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - disabledButtonTooltip: `${namespace}:option.2.tooltip_disabled`, + disabledButtonTooltip: `${namespace}:option.2.tooltipDisabled`, selected: [ { speaker: `${namespace}:speaker`, diff --git a/test/mystery-encounter/encounters/berries-abound-encounter.test.ts b/test/mystery-encounter/encounters/berries-abound-encounter.test.ts index 25116a89ec5..ecd08b5e57b 100644 --- a/test/mystery-encounter/encounters/berries-abound-encounter.test.ts +++ b/test/mystery-encounter/encounters/berries-abound-encounter.test.ts @@ -194,7 +194,7 @@ describe("Berries Abound - Mystery Encounter", () => { // Should be enraged expect(enemyField[0].summonData.statStages).toEqual([0, 1, 0, 1, 1, 0, 0]); - expect(encounterTextSpy).toHaveBeenCalledWith(`${namespace}:option.2.selected_bad`); + expect(encounterTextSpy).toHaveBeenCalledWith(`${namespace}:option.2.selectedBad`); }); it("should start battle if fastest pokemon is slower than boss above wave 50", async () => { @@ -218,7 +218,7 @@ describe("Berries Abound - Mystery Encounter", () => { // Should be enraged expect(enemyField[0].summonData.statStages).toEqual([1, 1, 1, 1, 1, 0, 0]); - expect(encounterTextSpy).toHaveBeenCalledWith(`${namespace}:option.2.selected_bad`); + expect(encounterTextSpy).toHaveBeenCalledWith(`${namespace}:option.2.selectedBad`); }); it("Should skip battle when fastest pokemon is faster than boss", async () => { diff --git a/test/mystery-encounter/encounters/bug-type-superfan-encounter.test.ts b/test/mystery-encounter/encounters/bug-type-superfan-encounter.test.ts index bed9d48d063..f0fe8be6a01 100644 --- a/test/mystery-encounter/encounters/bug-type-superfan-encounter.test.ts +++ b/test/mystery-encounter/encounters/bug-type-superfan-encounter.test.ts @@ -181,7 +181,7 @@ describe("Bug-Type Superfan - Mystery Encounter", () => { }, { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]); expect(BugTypeSuperfanEncounter.dialogue.encounterOptionsDialogue?.title).toBe(`${namespace}:title`); @@ -389,7 +389,7 @@ describe("Bug-Type Superfan - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - disabledButtonTooltip: `${namespace}:option.2.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.2.disabledTooltip`, }); }); @@ -513,17 +513,17 @@ describe("Bug-Type Superfan - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - disabledButtonTooltip: `${namespace}:option.3.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.3.disabledTooltip`, selected: [ { text: `${namespace}:option.3.selected`, }, { speaker: `${namespace}:speaker`, - text: `${namespace}:option.3.selected_dialogue`, + text: `${namespace}:option.3.selectedDialogue`, }, ], - secondOptionPrompt: `${namespace}:option.3.select_prompt`, + secondOptionPrompt: `${namespace}:option.3.selectPrompt`, }); }); diff --git a/test/mystery-encounter/encounters/clowning-around-encounter.test.ts b/test/mystery-encounter/encounters/clowning-around-encounter.test.ts index b573701d568..b0dacd0df08 100644 --- a/test/mystery-encounter/encounters/clowning-around-encounter.test.ts +++ b/test/mystery-encounter/encounters/clowning-around-encounter.test.ts @@ -80,7 +80,7 @@ describe("Clowning Around - Mystery Encounter", () => { { text: `${namespace}:intro` }, { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]); expect(ClowningAroundEncounter.dialogue.encounterOptionsDialogue?.title).toBe(`${namespace}:title`); @@ -249,11 +249,11 @@ describe("Clowning Around - Mystery Encounter", () => { text: `${namespace}:option.2.selected`, }, { - text: `${namespace}:option.2.selected_2`, + text: `${namespace}:option.2.selected2`, }, { speaker: `${namespace}:speaker`, - text: `${namespace}:option.2.selected_3`, + text: `${namespace}:option.2.selected3`, }, ], }); @@ -334,11 +334,11 @@ describe("Clowning Around - Mystery Encounter", () => { text: `${namespace}:option.3.selected`, }, { - text: `${namespace}:option.3.selected_2`, + text: `${namespace}:option.3.selected2`, }, { speaker: `${namespace}:speaker`, - text: `${namespace}:option.3.selected_3`, + text: `${namespace}:option.3.selected3`, }, ], }); diff --git a/test/mystery-encounter/encounters/dancing-lessons-encounter.test.ts b/test/mystery-encounter/encounters/dancing-lessons-encounter.test.ts index 97d0ce31367..95817abc1d8 100644 --- a/test/mystery-encounter/encounters/dancing-lessons-encounter.test.ts +++ b/test/mystery-encounter/encounters/dancing-lessons-encounter.test.ts @@ -186,8 +186,8 @@ describe("Dancing Lessons - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - disabledButtonTooltip: `${namespace}:option.3.disabled_tooltip`, - secondOptionPrompt: `${namespace}:option.3.select_prompt`, + disabledButtonTooltip: `${namespace}:option.3.disabledTooltip`, + secondOptionPrompt: `${namespace}:option.3.selectPrompt`, selected: [ { text: `${namespace}:option.3.selected`, diff --git a/test/mystery-encounter/encounters/delibirdy-encounter.test.ts b/test/mystery-encounter/encounters/delibirdy-encounter.test.ts index 16c726f1de6..aac7a5f75f5 100644 --- a/test/mystery-encounter/encounters/delibirdy-encounter.test.ts +++ b/test/mystery-encounter/encounters/delibirdy-encounter.test.ts @@ -186,7 +186,7 @@ describe("Delibird-y - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - secondOptionPrompt: `${namespace}:option.2.select_prompt`, + secondOptionPrompt: `${namespace}:option.2.selectPrompt`, selected: [ { text: `${namespace}:option.2.selected`, @@ -348,7 +348,7 @@ describe("Delibird-y - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - secondOptionPrompt: `${namespace}:option.3.select_prompt`, + secondOptionPrompt: `${namespace}:option.3.selectPrompt`, selected: [ { text: `${namespace}:option.3.selected`, diff --git a/test/mystery-encounter/encounters/department-store-sale-encounter.test.ts b/test/mystery-encounter/encounters/department-store-sale-encounter.test.ts index 3d84d70b47e..f8ff6beaf30 100644 --- a/test/mystery-encounter/encounters/department-store-sale-encounter.test.ts +++ b/test/mystery-encounter/encounters/department-store-sale-encounter.test.ts @@ -61,7 +61,7 @@ describe("Department Store Sale - Mystery Encounter", () => { { text: `${namespace}:intro` }, { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]); expect(DepartmentStoreSaleEncounter.dialogue.encounterOptionsDialogue?.title).toBe(`${namespace}:title`); diff --git a/test/mystery-encounter/encounters/field-trip-encounter.test.ts b/test/mystery-encounter/encounters/field-trip-encounter.test.ts index 8502137cc6e..fd3e20012b1 100644 --- a/test/mystery-encounter/encounters/field-trip-encounter.test.ts +++ b/test/mystery-encounter/encounters/field-trip-encounter.test.ts @@ -61,7 +61,7 @@ describe("Field Trip - Mystery Encounter", () => { }, { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]); expect(FieldTripEncounter.dialogue.encounterOptionsDialogue?.title).toBe(`${namespace}:title`); @@ -78,7 +78,7 @@ describe("Field Trip - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.1.label`, buttonTooltip: `${namespace}:option.1.tooltip`, - secondOptionPrompt: `${namespace}:second_option_prompt`, + secondOptionPrompt: `${namespace}:secondOptionPrompt`, }); }); @@ -139,7 +139,7 @@ describe("Field Trip - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - secondOptionPrompt: `${namespace}:second_option_prompt`, + secondOptionPrompt: `${namespace}:secondOptionPrompt`, }); }); @@ -200,7 +200,7 @@ describe("Field Trip - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - secondOptionPrompt: `${namespace}:second_option_prompt`, + secondOptionPrompt: `${namespace}:secondOptionPrompt`, }); }); diff --git a/test/mystery-encounter/encounters/fiery-fallout-encounter.test.ts b/test/mystery-encounter/encounters/fiery-fallout-encounter.test.ts index a48422c459f..54f790ca207 100644 --- a/test/mystery-encounter/encounters/fiery-fallout-encounter.test.ts +++ b/test/mystery-encounter/encounters/fiery-fallout-encounter.test.ts @@ -253,7 +253,7 @@ describe("Fiery Fallout - Mystery Encounter", () => { expect(option1.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - disabledButtonTooltip: `${namespace}:option.3.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.3.disabledTooltip`, selected: [ { text: `${namespace}:option.3.selected`, diff --git a/test/mystery-encounter/encounters/fight-or-flight-encounter.test.ts b/test/mystery-encounter/encounters/fight-or-flight-encounter.test.ts index 8149212f00f..e8cfd1ab79e 100644 --- a/test/mystery-encounter/encounters/fight-or-flight-encounter.test.ts +++ b/test/mystery-encounter/encounters/fight-or-flight-encounter.test.ts @@ -143,7 +143,7 @@ describe("Fight or Flight - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - disabledButtonTooltip: `${namespace}:option.2.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.2.disabledTooltip`, selected: [ { text: `${namespace}:option.2.selected`, diff --git a/test/mystery-encounter/encounters/fun-and-games-encounter.test.ts b/test/mystery-encounter/encounters/fun-and-games-encounter.test.ts index 3025b08b8b6..4b39aee2522 100644 --- a/test/mystery-encounter/encounters/fun-and-games-encounter.test.ts +++ b/test/mystery-encounter/encounters/fun-and-games-encounter.test.ts @@ -71,7 +71,7 @@ describe("Fun And Games! - Mystery Encounter", () => { expect(FunAndGamesEncounter.dialogue.intro).toStrictEqual([ { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]); expect(FunAndGamesEncounter.dialogue.encounterOptionsDialogue?.title).toBe(`${namespace}:title`); diff --git a/test/mystery-encounter/encounters/global-trade-system-encounter.test.ts b/test/mystery-encounter/encounters/global-trade-system-encounter.test.ts index 867a33f6ab6..410b99c7ebc 100644 --- a/test/mystery-encounter/encounters/global-trade-system-encounter.test.ts +++ b/test/mystery-encounter/encounters/global-trade-system-encounter.test.ts @@ -98,7 +98,7 @@ describe("Global Trade System - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.1.label`, buttonTooltip: `${namespace}:option.1.tooltip`, - secondOptionPrompt: `${namespace}:option.1.trade_options_prompt`, + secondOptionPrompt: `${namespace}:option.1.tradeOptionsPrompt`, }); }); @@ -210,7 +210,7 @@ describe("Global Trade System - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - secondOptionPrompt: `${namespace}:option.3.trade_options_prompt`, + secondOptionPrompt: `${namespace}:option.3.tradeOptionsPrompt`, }); }); diff --git a/test/mystery-encounter/encounters/lost-at-sea-encounter.test.ts b/test/mystery-encounter/encounters/lost-at-sea-encounter.test.ts index d29f8fe6a82..73134381553 100644 --- a/test/mystery-encounter/encounters/lost-at-sea-encounter.test.ts +++ b/test/mystery-encounter/encounters/lost-at-sea-encounter.test.ts @@ -99,9 +99,9 @@ describe("Lost at Sea - Mystery Encounter", () => { expect(option1.dialogue).toBeDefined(); expect(option1.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.1.label`, - disabledButtonLabel: `${namespace}:option.1.label_disabled`, + disabledButtonLabel: `${namespace}:option.1.labelDisabled`, buttonTooltip: `${namespace}:option.1.tooltip`, - disabledButtonTooltip: `${namespace}:option.1.tooltip_disabled`, + disabledButtonTooltip: `${namespace}:option.1.tooltipDisabled`, selected: [ { text: `${namespace}:option.1.selected`, @@ -162,9 +162,9 @@ describe("Lost at Sea - Mystery Encounter", () => { expect(option2.dialogue).toBeDefined(); expect(option2.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.2.label`, - disabledButtonLabel: `${namespace}:option.2.label_disabled`, + disabledButtonLabel: `${namespace}:option.2.labelDisabled`, buttonTooltip: `${namespace}:option.2.tooltip`, - disabledButtonTooltip: `${namespace}:option.2.tooltip_disabled`, + disabledButtonTooltip: `${namespace}:option.2.tooltipDisabled`, selected: [ { text: `${namespace}:option.2.selected`, diff --git a/test/mystery-encounter/encounters/part-timer-encounter.test.ts b/test/mystery-encounter/encounters/part-timer-encounter.test.ts index 63eea8bbca2..ae07d4c2004 100644 --- a/test/mystery-encounter/encounters/part-timer-encounter.test.ts +++ b/test/mystery-encounter/encounters/part-timer-encounter.test.ts @@ -65,7 +65,7 @@ describe("Part-Timer - Mystery Encounter", () => { { text: `${namespace}:intro` }, { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]); expect(PartTimerEncounter.dialogue.encounterOptionsDialogue?.title).toBe(`${namespace}:title`); @@ -219,7 +219,7 @@ describe("Part-Timer - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - disabledButtonTooltip: `${namespace}:option.3.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.3.disabledTooltip`, selected: [ { text: `${namespace}:option.3.selected`, diff --git a/test/mystery-encounter/encounters/teleporting-hijinks-encounter.test.ts b/test/mystery-encounter/encounters/teleporting-hijinks-encounter.test.ts index ff4f73cfbde..5d53e57d2eb 100644 --- a/test/mystery-encounter/encounters/teleporting-hijinks-encounter.test.ts +++ b/test/mystery-encounter/encounters/teleporting-hijinks-encounter.test.ts @@ -207,7 +207,7 @@ describe("Teleporting Hijinks - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - disabledButtonTooltip: `${namespace}:option.2.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.2.disabledTooltip`, selected: [ { text: `${namespace}:option.2.selected`, diff --git a/test/mystery-encounter/encounters/the-expert-breeder-encounter.test.ts b/test/mystery-encounter/encounters/the-expert-breeder-encounter.test.ts index 4556f7a7f45..31584048c78 100644 --- a/test/mystery-encounter/encounters/the-expert-breeder-encounter.test.ts +++ b/test/mystery-encounter/encounters/the-expert-breeder-encounter.test.ts @@ -71,7 +71,7 @@ describe("The Expert Pokémon Breeder - Mystery Encounter", () => { }, { speaker: "trainerNames:expert_pokemon_breeder", - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]); expect(TheExpertPokemonBreederEncounter.dialogue.encounterOptionsDialogue?.title).toBe(`${namespace}:title`); diff --git a/test/mystery-encounter/encounters/the-pokemon-salesman-encounter.test.ts b/test/mystery-encounter/encounters/the-pokemon-salesman-encounter.test.ts index 611a103dab2..7c60cbcb4a9 100644 --- a/test/mystery-encounter/encounters/the-pokemon-salesman-encounter.test.ts +++ b/test/mystery-encounter/encounters/the-pokemon-salesman-encounter.test.ts @@ -67,7 +67,7 @@ describe("The Pokemon Salesman - Mystery Encounter", () => { expect(dialogue).toBeDefined(); expect(dialogue.intro).toStrictEqual([ { text: `${namespace}:intro` }, - { speaker: `${namespace}:speaker`, text: `${namespace}:intro_dialogue` }, + { speaker: `${namespace}:speaker`, text: `${namespace}:introDialogue` }, ]); const { title, description, query } = dialogue.encounterOptionsDialogue!; expect(title).toBe(`${namespace}:title`); @@ -120,7 +120,7 @@ describe("The Pokemon Salesman - Mystery Encounter", () => { buttonTooltip: expect.stringMatching(new RegExp(`^${namespace}\\:option\\.1\\.tooltip(_shiny)?$`)), selected: [ { - text: `${namespace}:option.1.selected_message`, + text: `${namespace}:option.1.selectedMessage`, }, ], }); diff --git a/test/mystery-encounter/encounters/the-winstrate-challenge-encounter.test.ts b/test/mystery-encounter/encounters/the-winstrate-challenge-encounter.test.ts index ae2f9fd79ff..2da246bebb1 100644 --- a/test/mystery-encounter/encounters/the-winstrate-challenge-encounter.test.ts +++ b/test/mystery-encounter/encounters/the-winstrate-challenge-encounter.test.ts @@ -73,7 +73,7 @@ describe("The Winstrate Challenge - Mystery Encounter", () => { { text: `${namespace}:intro` }, { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]); expect(TheWinstrateChallengeEncounter.dialogue.encounterOptionsDialogue?.title).toBe(`${namespace}:title`); diff --git a/test/mystery-encounter/encounters/uncommon-breed-encounter.test.ts b/test/mystery-encounter/encounters/uncommon-breed-encounter.test.ts index 24d7960049e..4d7e10daa03 100644 --- a/test/mystery-encounter/encounters/uncommon-breed-encounter.test.ts +++ b/test/mystery-encounter/encounters/uncommon-breed-encounter.test.ts @@ -172,7 +172,7 @@ describe("Uncommon Breed - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.2.label`, buttonTooltip: `${namespace}:option.2.tooltip`, - disabledButtonTooltip: `${namespace}:option.2.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.2.disabledTooltip`, selected: [ { text: `${namespace}:option.2.selected`, @@ -237,7 +237,7 @@ describe("Uncommon Breed - Mystery Encounter", () => { expect(option.dialogue).toStrictEqual({ buttonLabel: `${namespace}:option.3.label`, buttonTooltip: `${namespace}:option.3.tooltip`, - disabledButtonTooltip: `${namespace}:option.3.disabled_tooltip`, + disabledButtonTooltip: `${namespace}:option.3.disabledTooltip`, selected: [ { text: `${namespace}:option.3.selected`, diff --git a/test/mystery-encounter/encounters/weird-dream-encounter.test.ts b/test/mystery-encounter/encounters/weird-dream-encounter.test.ts index 9b430ec046e..e2317d70896 100644 --- a/test/mystery-encounter/encounters/weird-dream-encounter.test.ts +++ b/test/mystery-encounter/encounters/weird-dream-encounter.test.ts @@ -68,7 +68,7 @@ describe("Weird Dream - Mystery Encounter", () => { }, { speaker: `${namespace}:speaker`, - text: `${namespace}:intro_dialogue`, + text: `${namespace}:introDialogue`, }, ]); expect(WeirdDreamEncounter.dialogue.encounterOptionsDialogue?.title).toBe(`${namespace}:title`); From 03f54c1d8ab6f9d1a54e6d92a64a1e2e457efa2e Mon Sep 17 00:00:00 2001 From: fabske0 <192151969+fabske0@users.noreply.github.com> Date: Sun, 17 Aug 2025 21:59:09 +0200 Subject: [PATCH 05/11] [i18n] Change i18n keys to be camel case Part 2 (#6250) * Change Achv locales * Change berry locales use * change bgm name locales use * change biome locales uses * change double battle dialogue use * change misc dialogue locales use * change dialogue locales use * change growth locales use * update menu-ui-handler locales use * change ME texts locales uses * fix biome drop down * fix a few missed keys * Update locales submodule --- public/locales | 2 +- src/data/balance/biomes.ts | 9 +- src/data/berry.ts | 4 +- src/data/dialogue.ts | 630 +++++++++--------- src/data/double-battle-dialogue.ts | 40 +- .../encounters/fun-and-games-encounter.ts | 2 +- .../encounters/part-timer-encounter.ts | 6 +- .../utils/encounter-phase-utils.ts | 8 +- src/phases/game-over-phase.ts | 4 +- src/system/achv.ts | 485 +++++++------- src/ui/achvs-ui-handler.ts | 4 +- src/ui/bgm-bar.ts | 4 +- src/ui/menu-ui-handler.ts | 3 +- src/ui/mystery-encounter-ui-handler.ts | 4 +- src/ui/pokedex-page-ui-handler.ts | 16 +- src/ui/pokedex-ui-handler.ts | 3 +- src/ui/starter-select-ui-handler.ts | 6 +- 17 files changed, 613 insertions(+), 617 deletions(-) diff --git a/public/locales b/public/locales index 748146c687f..100e607c03d 160000 --- a/public/locales +++ b/public/locales @@ -1 +1 @@ -Subproject commit 748146c687fd1bdddd015ec4592c4e2b1496af32 +Subproject commit 100e607c03d9c5ea0d405b2b75300cd0e6fa1635 diff --git a/src/data/balance/biomes.ts b/src/data/balance/biomes.ts index d8297636393..c0c57cb15fb 100644 --- a/src/data/balance/biomes.ts +++ b/src/data/balance/biomes.ts @@ -7,6 +7,7 @@ import { TimeOfDay } from "#enums/time-of-day"; import { TrainerType } from "#enums/trainer-type"; import { randSeedInt } from "#utils/common"; import { getEnumValues } from "#utils/enums"; +import { toCamelCase } from "#utils/strings"; import i18next from "i18next"; export function getBiomeName(biome: BiomeId | -1) { @@ -15,13 +16,13 @@ export function getBiomeName(biome: BiomeId | -1) { } switch (biome) { case BiomeId.GRASS: - return i18next.t("biome:GRASS"); + return i18next.t("biome:grass"); case BiomeId.RUINS: - return i18next.t("biome:RUINS"); + return i18next.t("biome:ruins"); case BiomeId.END: - return i18next.t("biome:END"); + return i18next.t("biome:end"); default: - return i18next.t(`biome:${BiomeId[biome].toUpperCase()}`); + return i18next.t(`biome:${toCamelCase(BiomeId[biome])}`); } } diff --git a/src/data/berry.ts b/src/data/berry.ts index 61235b75e21..762423799fe 100644 --- a/src/data/berry.ts +++ b/src/data/berry.ts @@ -11,11 +11,11 @@ import { NumberHolder, randSeedInt, toDmgValue } from "#utils/common"; import i18next from "i18next"; export function getBerryName(berryType: BerryType): string { - return i18next.t(`berry:${BerryType[berryType]}.name`); + return i18next.t(`berry:${BerryType[berryType].toLowerCase()}.name`); } export function getBerryEffectDescription(berryType: BerryType): string { - return i18next.t(`berry:${BerryType[berryType]}.effect`); + return i18next.t(`berry:${BerryType[berryType].toLowerCase()}.effect`); } export type BerryPredicate = (pokemon: Pokemon) => boolean; diff --git a/src/data/dialogue.ts b/src/data/dialogue.ts index 361d005e83b..1d672397777 100644 --- a/src/data/dialogue.ts +++ b/src/data/dialogue.ts @@ -85,20 +85,16 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { }, { encounter: [ - "dialogue:breeder_female.encounter.1", - "dialogue:breeder_female.encounter.2", - "dialogue:breeder_female.encounter.3", + "dialogue:breederFemale.encounter.1", + "dialogue:breederFemale.encounter.2", + "dialogue:breederFemale.encounter.3", ], victory: [ - "dialogue:breeder_female.victory.1", - "dialogue:breeder_female.victory.2", - "dialogue:breeder_female.victory.3", - ], - defeat: [ - "dialogue:breeder_female.defeat.1", - "dialogue:breeder_female.defeat.2", - "dialogue:breeder_female.defeat.3", + "dialogue:breederFemale.victory.1", + "dialogue:breederFemale.victory.2", + "dialogue:breederFemale.victory.3", ], + defeat: ["dialogue:breederFemale.defeat.1", "dialogue:breederFemale.defeat.2", "dialogue:breederFemale.defeat.3"], }, ], [TrainerType.FISHERMAN]: [ @@ -108,14 +104,14 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { }, { encounter: [ - "dialogue:fisherman_female.encounter.1", - "dialogue:fisherman_female.encounter.2", - "dialogue:fisherman_female.encounter.3", + "dialogue:fishermanFemale.encounter.1", + "dialogue:fishermanFemale.encounter.2", + "dialogue:fishermanFemale.encounter.3", ], victory: [ - "dialogue:fisherman_female.victory.1", - "dialogue:fisherman_female.victory.2", - "dialogue:fisherman_female.victory.3", + "dialogue:fishermanFemale.victory.1", + "dialogue:fishermanFemale.victory.2", + "dialogue:fishermanFemale.victory.3", ], }, ], @@ -144,29 +140,29 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { [TrainerType.ACE_TRAINER]: [ { encounter: [ - "dialogue:ace_trainer.encounter.1", - "dialogue:ace_trainer.encounter.2", - "dialogue:ace_trainer.encounter.3", - "dialogue:ace_trainer.encounter.4", + "dialogue:aceTrainer.encounter.1", + "dialogue:aceTrainer.encounter.2", + "dialogue:aceTrainer.encounter.3", + "dialogue:aceTrainer.encounter.4", ], victory: [ - "dialogue:ace_trainer.victory.1", - "dialogue:ace_trainer.victory.2", - "dialogue:ace_trainer.victory.3", - "dialogue:ace_trainer.victory.4", + "dialogue:aceTrainer.victory.1", + "dialogue:aceTrainer.victory.2", + "dialogue:aceTrainer.victory.3", + "dialogue:aceTrainer.victory.4", ], defeat: [ - "dialogue:ace_trainer.defeat.1", - "dialogue:ace_trainer.defeat.2", - "dialogue:ace_trainer.defeat.3", - "dialogue:ace_trainer.defeat.4", + "dialogue:aceTrainer.defeat.1", + "dialogue:aceTrainer.defeat.2", + "dialogue:aceTrainer.defeat.3", + "dialogue:aceTrainer.defeat.4", ], }, ], [TrainerType.PARASOL_LADY]: [ { - encounter: ["dialogue:parasol_lady.encounter.1"], - victory: ["dialogue:parasol_lady.victory.1"], + encounter: ["dialogue:parasolLady.encounter.1"], + victory: ["dialogue:parasolLady.victory.1"], }, ], [TrainerType.TWINS]: [ @@ -184,13 +180,13 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { ], [TrainerType.BLACK_BELT]: [ { - encounter: ["dialogue:black_belt.encounter.1", "dialogue:black_belt.encounter.2"], - victory: ["dialogue:black_belt.victory.1", "dialogue:black_belt.victory.2"], + encounter: ["dialogue:blackBelt.encounter.1", "dialogue:blackBelt.encounter.2"], + victory: ["dialogue:blackBelt.victory.1", "dialogue:blackBelt.victory.2"], }, //BATTLE GIRL { - encounter: ["dialogue:battle_girl.encounter.1"], - victory: ["dialogue:battle_girl.victory.1"], + encounter: ["dialogue:battleGirl.encounter.1"], + victory: ["dialogue:battleGirl.victory.1"], }, ], [TrainerType.HIKER]: [ @@ -214,8 +210,8 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { ], [TrainerType.SCHOOL_KID]: [ { - encounter: ["dialogue:school_kid.encounter.1", "dialogue:school_kid.encounter.2"], - victory: ["dialogue:school_kid.victory.1", "dialogue:school_kid.victory.2"], + encounter: ["dialogue:schoolKid.encounter.1", "dialogue:schoolKid.encounter.2"], + victory: ["dialogue:schoolKid.victory.1", "dialogue:schoolKid.victory.2"], }, ], [TrainerType.ARTIST]: [ @@ -236,31 +232,31 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { victory: ["dialogue:worker.victory.1"], }, { - encounter: ["dialogue:worker_female.encounter.1"], - victory: ["dialogue:worker_female.victory.1"], - defeat: ["dialogue:worker_female.defeat.1"], + encounter: ["dialogue:workerFemale.encounter.1"], + victory: ["dialogue:workerFemale.victory.1"], + defeat: ["dialogue:workerFemale.defeat.1"], }, { - encounter: ["dialogue:worker_double.encounter.1"], - victory: ["dialogue:worker_double.victory.1"], + encounter: ["dialogue:workerDouble.encounter.1"], + victory: ["dialogue:workerDouble.victory.1"], }, ], // Defeat dialogue in the language .JSONS exist as translated or placeholders; (en, fr, it, es, de, ja, ko, zh_cn, zh_tw, pt_br) [TrainerType.SNOW_WORKER]: [ { - encounter: ["dialogue:snow_worker.encounter.1"], - victory: ["dialogue:snow_worker.victory.1"], + encounter: ["dialogue:snowWorker.encounter.1"], + victory: ["dialogue:snowWorker.victory.1"], }, { - encounter: ["dialogue:snow_worker_double.encounter.1"], - victory: ["dialogue:snow_worker_double.victory.1"], + encounter: ["dialogue:snowWorkerDouble.encounter.1"], + victory: ["dialogue:snowWorkerDouble.victory.1"], }, ], [TrainerType.HEX_MANIAC]: [ { - encounter: ["dialogue:hex_maniac.encounter.1", "dialogue:hex_maniac.encounter.2"], - victory: ["dialogue:hex_maniac.victory.1", "dialogue:hex_maniac.victory.2"], - defeat: ["dialogue:hex_maniac.defeat.1", "dialogue:hex_maniac.defeat.2"], + encounter: ["dialogue:hexManiac.encounter.1", "dialogue:hexManiac.encounter.2"], + victory: ["dialogue:hexManiac.victory.1", "dialogue:hexManiac.victory.2"], + defeat: ["dialogue:hexManiac.defeat.1", "dialogue:hexManiac.defeat.2"], }, ], [TrainerType.PSYCHIC]: [ @@ -320,15 +316,11 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { }, { encounter: [ - "dialogue:clerk_female.encounter.1", - "dialogue:clerk_female.encounter.2", - "dialogue:clerk_female.encounter.3", - ], - victory: [ - "dialogue:clerk_female.victory.1", - "dialogue:clerk_female.victory.2", - "dialogue:clerk_female.victory.3", + "dialogue:clerkFemale.encounter.1", + "dialogue:clerkFemale.encounter.2", + "dialogue:clerkFemale.encounter.3", ], + victory: ["dialogue:clerkFemale.victory.1", "dialogue:clerkFemale.victory.2", "dialogue:clerkFemale.victory.3"], }, ], [TrainerType.HOOLIGANS]: [ @@ -371,14 +363,14 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { }, { encounter: [ - "dialogue:pokefan_female.encounter.1", - "dialogue:pokefan_female.encounter.2", - "dialogue:pokefan_female.encounter.3", + "dialogue:pokefanFemale.encounter.1", + "dialogue:pokefanFemale.encounter.2", + "dialogue:pokefanFemale.encounter.3", ], victory: [ - "dialogue:pokefan_female.victory.1", - "dialogue:pokefan_female.victory.2", - "dialogue:pokefan_female.victory.3", + "dialogue:pokefanFemale.victory.1", + "dialogue:pokefanFemale.victory.2", + "dialogue:pokefanFemale.victory.3", ], }, ], @@ -389,52 +381,52 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { }, { encounter: [ - "dialogue:rich_female.encounter.1", - "dialogue:rich_female.encounter.2", - "dialogue:rich_female.encounter.3", + "dialogue:richFemale.encounter.1", + "dialogue:richFemale.encounter.2", + "dialogue:richFemale.encounter.3", ], - victory: ["dialogue:rich_female.victory.1", "dialogue:rich_female.victory.2", "dialogue:rich_female.victory.3"], + victory: ["dialogue:richFemale.victory.1", "dialogue:richFemale.victory.2", "dialogue:richFemale.victory.3"], }, ], [TrainerType.RICH_KID]: [ { - encounter: ["dialogue:rich_kid.encounter.1", "dialogue:rich_kid.encounter.2", "dialogue:rich_kid.encounter.3"], + encounter: ["dialogue:richKid.encounter.1", "dialogue:richKid.encounter.2", "dialogue:richKid.encounter.3"], victory: [ - "dialogue:rich_kid.victory.1", - "dialogue:rich_kid.victory.2", - "dialogue:rich_kid.victory.3", - "dialogue:rich_kid.victory.4", + "dialogue:richKid.victory.1", + "dialogue:richKid.victory.2", + "dialogue:richKid.victory.3", + "dialogue:richKid.victory.4", ], }, { encounter: [ - "dialogue:rich_kid_female.encounter.1", - "dialogue:rich_kid_female.encounter.2", - "dialogue:rich_kid_female.encounter.3", + "dialogue:richKidFemale.encounter.1", + "dialogue:richKidFemale.encounter.2", + "dialogue:richKidFemale.encounter.3", ], victory: [ - "dialogue:rich_kid_female.victory.1", - "dialogue:rich_kid_female.victory.2", - "dialogue:rich_kid_female.victory.3", - "dialogue:rich_kid_female.victory.4", + "dialogue:richKidFemale.victory.1", + "dialogue:richKidFemale.victory.2", + "dialogue:richKidFemale.victory.3", + "dialogue:richKidFemale.victory.4", ], }, ], [TrainerType.ROCKET_GRUNT]: [ { encounter: [ - "dialogue:rocket_grunt.encounter.1", - "dialogue:rocket_grunt.encounter.2", - "dialogue:rocket_grunt.encounter.3", - "dialogue:rocket_grunt.encounter.4", - "dialogue:rocket_grunt.encounter.5", + "dialogue:rocketGrunt.encounter.1", + "dialogue:rocketGrunt.encounter.2", + "dialogue:rocketGrunt.encounter.3", + "dialogue:rocketGrunt.encounter.4", + "dialogue:rocketGrunt.encounter.5", ], victory: [ - "dialogue:rocket_grunt.victory.1", - "dialogue:rocket_grunt.victory.2", - "dialogue:rocket_grunt.victory.3", - "dialogue:rocket_grunt.victory.4", - "dialogue:rocket_grunt.victory.5", + "dialogue:rocketGrunt.victory.1", + "dialogue:rocketGrunt.victory.2", + "dialogue:rocketGrunt.victory.3", + "dialogue:rocketGrunt.victory.4", + "dialogue:rocketGrunt.victory.5", ], }, ], @@ -465,18 +457,18 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { [TrainerType.MAGMA_GRUNT]: [ { encounter: [ - "dialogue:magma_grunt.encounter.1", - "dialogue:magma_grunt.encounter.2", - "dialogue:magma_grunt.encounter.3", - "dialogue:magma_grunt.encounter.4", - "dialogue:magma_grunt.encounter.5", + "dialogue:magmaGrunt.encounter.1", + "dialogue:magmaGrunt.encounter.2", + "dialogue:magmaGrunt.encounter.3", + "dialogue:magmaGrunt.encounter.4", + "dialogue:magmaGrunt.encounter.5", ], victory: [ - "dialogue:magma_grunt.victory.1", - "dialogue:magma_grunt.victory.2", - "dialogue:magma_grunt.victory.3", - "dialogue:magma_grunt.victory.4", - "dialogue:magma_grunt.victory.5", + "dialogue:magmaGrunt.victory.1", + "dialogue:magmaGrunt.victory.2", + "dialogue:magmaGrunt.victory.3", + "dialogue:magmaGrunt.victory.4", + "dialogue:magmaGrunt.victory.5", ], }, ], @@ -495,18 +487,18 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { [TrainerType.AQUA_GRUNT]: [ { encounter: [ - "dialogue:aqua_grunt.encounter.1", - "dialogue:aqua_grunt.encounter.2", - "dialogue:aqua_grunt.encounter.3", - "dialogue:aqua_grunt.encounter.4", - "dialogue:aqua_grunt.encounter.5", + "dialogue:aquaGrunt.encounter.1", + "dialogue:aquaGrunt.encounter.2", + "dialogue:aquaGrunt.encounter.3", + "dialogue:aquaGrunt.encounter.4", + "dialogue:aquaGrunt.encounter.5", ], victory: [ - "dialogue:aqua_grunt.victory.1", - "dialogue:aqua_grunt.victory.2", - "dialogue:aqua_grunt.victory.3", - "dialogue:aqua_grunt.victory.4", - "dialogue:aqua_grunt.victory.5", + "dialogue:aquaGrunt.victory.1", + "dialogue:aquaGrunt.victory.2", + "dialogue:aquaGrunt.victory.3", + "dialogue:aquaGrunt.victory.4", + "dialogue:aquaGrunt.victory.5", ], }, ], @@ -525,18 +517,18 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { [TrainerType.GALACTIC_GRUNT]: [ { encounter: [ - "dialogue:galactic_grunt.encounter.1", - "dialogue:galactic_grunt.encounter.2", - "dialogue:galactic_grunt.encounter.3", - "dialogue:galactic_grunt.encounter.4", - "dialogue:galactic_grunt.encounter.5", + "dialogue:galacticGrunt.encounter.1", + "dialogue:galacticGrunt.encounter.2", + "dialogue:galacticGrunt.encounter.3", + "dialogue:galacticGrunt.encounter.4", + "dialogue:galacticGrunt.encounter.5", ], victory: [ - "dialogue:galactic_grunt.victory.1", - "dialogue:galactic_grunt.victory.2", - "dialogue:galactic_grunt.victory.3", - "dialogue:galactic_grunt.victory.4", - "dialogue:galactic_grunt.victory.5", + "dialogue:galacticGrunt.victory.1", + "dialogue:galacticGrunt.victory.2", + "dialogue:galacticGrunt.victory.3", + "dialogue:galacticGrunt.victory.4", + "dialogue:galacticGrunt.victory.5", ], }, ], @@ -561,18 +553,18 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { [TrainerType.PLASMA_GRUNT]: [ { encounter: [ - "dialogue:plasma_grunt.encounter.1", - "dialogue:plasma_grunt.encounter.2", - "dialogue:plasma_grunt.encounter.3", - "dialogue:plasma_grunt.encounter.4", - "dialogue:plasma_grunt.encounter.5", + "dialogue:plasmaGrunt.encounter.1", + "dialogue:plasmaGrunt.encounter.2", + "dialogue:plasmaGrunt.encounter.3", + "dialogue:plasmaGrunt.encounter.4", + "dialogue:plasmaGrunt.encounter.5", ], victory: [ - "dialogue:plasma_grunt.victory.1", - "dialogue:plasma_grunt.victory.2", - "dialogue:plasma_grunt.victory.3", - "dialogue:plasma_grunt.victory.4", - "dialogue:plasma_grunt.victory.5", + "dialogue:plasmaGrunt.victory.1", + "dialogue:plasmaGrunt.victory.2", + "dialogue:plasmaGrunt.victory.3", + "dialogue:plasmaGrunt.victory.4", + "dialogue:plasmaGrunt.victory.5", ], }, ], @@ -591,18 +583,18 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { [TrainerType.FLARE_GRUNT]: [ { encounter: [ - "dialogue:flare_grunt.encounter.1", - "dialogue:flare_grunt.encounter.2", - "dialogue:flare_grunt.encounter.3", - "dialogue:flare_grunt.encounter.4", - "dialogue:flare_grunt.encounter.5", + "dialogue:flareGrunt.encounter.1", + "dialogue:flareGrunt.encounter.2", + "dialogue:flareGrunt.encounter.3", + "dialogue:flareGrunt.encounter.4", + "dialogue:flareGrunt.encounter.5", ], victory: [ - "dialogue:flare_grunt.victory.1", - "dialogue:flare_grunt.victory.2", - "dialogue:flare_grunt.victory.3", - "dialogue:flare_grunt.victory.4", - "dialogue:flare_grunt.victory.5", + "dialogue:flareGrunt.victory.1", + "dialogue:flareGrunt.victory.2", + "dialogue:flareGrunt.victory.3", + "dialogue:flareGrunt.victory.4", + "dialogue:flareGrunt.victory.5", ], }, ], @@ -621,18 +613,18 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { [TrainerType.AETHER_GRUNT]: [ { encounter: [ - "dialogue:aether_grunt.encounter.1", - "dialogue:aether_grunt.encounter.2", - "dialogue:aether_grunt.encounter.3", - "dialogue:aether_grunt.encounter.4", - "dialogue:aether_grunt.encounter.5", + "dialogue:aetherGrunt.encounter.1", + "dialogue:aetherGrunt.encounter.2", + "dialogue:aetherGrunt.encounter.3", + "dialogue:aetherGrunt.encounter.4", + "dialogue:aetherGrunt.encounter.5", ], victory: [ - "dialogue:aether_grunt.victory.1", - "dialogue:aether_grunt.victory.2", - "dialogue:aether_grunt.victory.3", - "dialogue:aether_grunt.victory.4", - "dialogue:aether_grunt.victory.5", + "dialogue:aetherGrunt.victory.1", + "dialogue:aetherGrunt.victory.2", + "dialogue:aetherGrunt.victory.3", + "dialogue:aetherGrunt.victory.4", + "dialogue:aetherGrunt.victory.5", ], }, ], @@ -645,18 +637,18 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { [TrainerType.SKULL_GRUNT]: [ { encounter: [ - "dialogue:skull_grunt.encounter.1", - "dialogue:skull_grunt.encounter.2", - "dialogue:skull_grunt.encounter.3", - "dialogue:skull_grunt.encounter.4", - "dialogue:skull_grunt.encounter.5", + "dialogue:skullGrunt.encounter.1", + "dialogue:skullGrunt.encounter.2", + "dialogue:skullGrunt.encounter.3", + "dialogue:skullGrunt.encounter.4", + "dialogue:skullGrunt.encounter.5", ], victory: [ - "dialogue:skull_grunt.victory.1", - "dialogue:skull_grunt.victory.2", - "dialogue:skull_grunt.victory.3", - "dialogue:skull_grunt.victory.4", - "dialogue:skull_grunt.victory.5", + "dialogue:skullGrunt.victory.1", + "dialogue:skullGrunt.victory.2", + "dialogue:skullGrunt.victory.3", + "dialogue:skullGrunt.victory.4", + "dialogue:skullGrunt.victory.5", ], }, ], @@ -669,18 +661,18 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { [TrainerType.MACRO_GRUNT]: [ { encounter: [ - "dialogue:macro_grunt.encounter.1", - "dialogue:macro_grunt.encounter.2", - "dialogue:macro_grunt.encounter.3", - "dialogue:macro_grunt.encounter.4", - "dialogue:macro_grunt.encounter.5", + "dialogue:macroGrunt.encounter.1", + "dialogue:macroGrunt.encounter.2", + "dialogue:macroGrunt.encounter.3", + "dialogue:macroGrunt.encounter.4", + "dialogue:macroGrunt.encounter.5", ], victory: [ - "dialogue:macro_grunt.victory.1", - "dialogue:macro_grunt.victory.2", - "dialogue:macro_grunt.victory.3", - "dialogue:macro_grunt.victory.4", - "dialogue:macro_grunt.victory.5", + "dialogue:macroGrunt.victory.1", + "dialogue:macroGrunt.victory.2", + "dialogue:macroGrunt.victory.3", + "dialogue:macroGrunt.victory.4", + "dialogue:macroGrunt.victory.5", ], }, ], @@ -693,18 +685,18 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { [TrainerType.STAR_GRUNT]: [ { encounter: [ - "dialogue:star_grunt.encounter.1", - "dialogue:star_grunt.encounter.2", - "dialogue:star_grunt.encounter.3", - "dialogue:star_grunt.encounter.4", - "dialogue:star_grunt.encounter.5", + "dialogue:starGrunt.encounter.1", + "dialogue:starGrunt.encounter.2", + "dialogue:starGrunt.encounter.3", + "dialogue:starGrunt.encounter.4", + "dialogue:starGrunt.encounter.5", ], victory: [ - "dialogue:star_grunt.victory.1", - "dialogue:star_grunt.victory.2", - "dialogue:star_grunt.victory.3", - "dialogue:star_grunt.victory.4", - "dialogue:star_grunt.victory.5", + "dialogue:starGrunt.victory.1", + "dialogue:starGrunt.victory.2", + "dialogue:starGrunt.victory.3", + "dialogue:starGrunt.victory.4", + "dialogue:starGrunt.victory.5", ], }, ], @@ -740,207 +732,207 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { ], [TrainerType.ROCKET_BOSS_GIOVANNI_1]: [ { - encounter: ["dialogue:rocket_boss_giovanni_1.encounter.1"], - victory: ["dialogue:rocket_boss_giovanni_1.victory.1"], - defeat: ["dialogue:rocket_boss_giovanni_1.defeat.1"], + encounter: ["dialogue:rocketBossGiovanni1.encounter.1"], + victory: ["dialogue:rocketBossGiovanni1.victory.1"], + defeat: ["dialogue:rocketBossGiovanni1.defeat.1"], }, ], [TrainerType.ROCKET_BOSS_GIOVANNI_2]: [ { - encounter: ["dialogue:rocket_boss_giovanni_2.encounter.1"], - victory: ["dialogue:rocket_boss_giovanni_2.victory.1"], - defeat: ["dialogue:rocket_boss_giovanni_2.defeat.1"], + encounter: ["dialogue:rocketBossGiovanni2.encounter.1"], + victory: ["dialogue:rocketBossGiovanni2.victory.1"], + defeat: ["dialogue:rocketBossGiovanni2.defeat.1"], }, ], [TrainerType.MAXIE]: [ { - encounter: ["dialogue:magma_boss_maxie_1.encounter.1"], - victory: ["dialogue:magma_boss_maxie_1.victory.1"], - defeat: ["dialogue:magma_boss_maxie_1.defeat.1"], + encounter: ["dialogue:magmaBossMaxie1.encounter.1"], + victory: ["dialogue:magmaBossMaxie1.victory.1"], + defeat: ["dialogue:magmaBossMaxie1.defeat.1"], }, ], [TrainerType.MAXIE_2]: [ { - encounter: ["dialogue:magma_boss_maxie_2.encounter.1"], - victory: ["dialogue:magma_boss_maxie_2.victory.1"], - defeat: ["dialogue:magma_boss_maxie_2.defeat.1"], + encounter: ["dialogue:magmaBossMaxie2.encounter.1"], + victory: ["dialogue:magmaBossMaxie2.victory.1"], + defeat: ["dialogue:magmaBossMaxie2.defeat.1"], }, ], [TrainerType.ARCHIE]: [ { - encounter: ["dialogue:aqua_boss_archie_1.encounter.1"], - victory: ["dialogue:aqua_boss_archie_1.victory.1"], - defeat: ["dialogue:aqua_boss_archie_1.defeat.1"], + encounter: ["dialogue:aquaBossArchie1.encounter.1"], + victory: ["dialogue:aquaBossArchie1.victory.1"], + defeat: ["dialogue:aquaBossArchie1.defeat.1"], }, ], [TrainerType.ARCHIE_2]: [ { - encounter: ["dialogue:aqua_boss_archie_2.encounter.1"], - victory: ["dialogue:aqua_boss_archie_2.victory.1"], - defeat: ["dialogue:aqua_boss_archie_2.defeat.1"], + encounter: ["dialogue:aquaBossArchie2.encounter.1"], + victory: ["dialogue:aquaBossArchie2.victory.1"], + defeat: ["dialogue:aquaBossArchie2.defeat.1"], }, ], [TrainerType.CYRUS]: [ { - encounter: ["dialogue:galactic_boss_cyrus_1.encounter.1"], - victory: ["dialogue:galactic_boss_cyrus_1.victory.1"], - defeat: ["dialogue:galactic_boss_cyrus_1.defeat.1"], + encounter: ["dialogue:galacticBossCyrus1.encounter.1"], + victory: ["dialogue:galacticBossCyrus1.victory.1"], + defeat: ["dialogue:galacticBossCyrus1.defeat.1"], }, ], [TrainerType.CYRUS_2]: [ { - encounter: ["dialogue:galactic_boss_cyrus_2.encounter.1"], - victory: ["dialogue:galactic_boss_cyrus_2.victory.1"], - defeat: ["dialogue:galactic_boss_cyrus_2.defeat.1"], + encounter: ["dialogue:galacticBossCyrus2.encounter.1"], + victory: ["dialogue:galacticBossCyrus2.victory.1"], + defeat: ["dialogue:galacticBossCyrus2.defeat.1"], }, ], [TrainerType.GHETSIS]: [ { - encounter: ["dialogue:plasma_boss_ghetsis_1.encounter.1"], - victory: ["dialogue:plasma_boss_ghetsis_1.victory.1"], - defeat: ["dialogue:plasma_boss_ghetsis_1.defeat.1"], + encounter: ["dialogue:plasmaBossGhetsis1.encounter.1"], + victory: ["dialogue:plasmaBossGhetsis1.victory.1"], + defeat: ["dialogue:plasmaBossGhetsis1.defeat.1"], }, ], [TrainerType.GHETSIS_2]: [ { - encounter: ["dialogue:plasma_boss_ghetsis_2.encounter.1"], - victory: ["dialogue:plasma_boss_ghetsis_2.victory.1"], - defeat: ["dialogue:plasma_boss_ghetsis_2.defeat.1"], + encounter: ["dialogue:plasmaBossGhetsis2.encounter.1"], + victory: ["dialogue:plasmaBossGhetsis2.victory.1"], + defeat: ["dialogue:plasmaBossGhetsis2.defeat.1"], }, ], [TrainerType.LYSANDRE]: [ { - encounter: ["dialogue:flare_boss_lysandre_1.encounter.1"], - victory: ["dialogue:flare_boss_lysandre_1.victory.1"], - defeat: ["dialogue:flare_boss_lysandre_1.defeat.1"], + encounter: ["dialogue:flareBossLysandre1.encounter.1"], + victory: ["dialogue:flareBossLysandre1.victory.1"], + defeat: ["dialogue:flareBossLysandre1.defeat.1"], }, ], [TrainerType.LYSANDRE_2]: [ { - encounter: ["dialogue:flare_boss_lysandre_2.encounter.1"], - victory: ["dialogue:flare_boss_lysandre_2.victory.1"], - defeat: ["dialogue:flare_boss_lysandre_2.defeat.1"], + encounter: ["dialogue:flareBossLysandre2.encounter.1"], + victory: ["dialogue:flareBossLysandre2.victory.1"], + defeat: ["dialogue:flareBossLysandre2.defeat.1"], }, ], [TrainerType.LUSAMINE]: [ { - encounter: ["dialogue:aether_boss_lusamine_1.encounter.1"], - victory: ["dialogue:aether_boss_lusamine_1.victory.1"], - defeat: ["dialogue:aether_boss_lusamine_1.defeat.1"], + encounter: ["dialogue:aetherBossLusamine1.encounter.1"], + victory: ["dialogue:aetherBossLusamine1.victory.1"], + defeat: ["dialogue:aetherBossLusamine1.defeat.1"], }, ], [TrainerType.LUSAMINE_2]: [ { - encounter: ["dialogue:aether_boss_lusamine_2.encounter.1"], - victory: ["dialogue:aether_boss_lusamine_2.victory.1"], - defeat: ["dialogue:aether_boss_lusamine_2.defeat.1"], + encounter: ["dialogue:aetherBossLusamine2.encounter.1"], + victory: ["dialogue:aetherBossLusamine2.victory.1"], + defeat: ["dialogue:aetherBossLusamine2.defeat.1"], }, ], [TrainerType.GUZMA]: [ { - encounter: ["dialogue:skull_boss_guzma_1.encounter.1"], - victory: ["dialogue:skull_boss_guzma_1.victory.1"], - defeat: ["dialogue:skull_boss_guzma_1.defeat.1"], + encounter: ["dialogue:skullBossGuzma1.encounter.1"], + victory: ["dialogue:skullBossGuzma1.victory.1"], + defeat: ["dialogue:skullBossGuzma1.defeat.1"], }, ], [TrainerType.GUZMA_2]: [ { - encounter: ["dialogue:skull_boss_guzma_2.encounter.1"], - victory: ["dialogue:skull_boss_guzma_2.victory.1"], - defeat: ["dialogue:skull_boss_guzma_2.defeat.1"], + encounter: ["dialogue:skullBossGuzma2.encounter.1"], + victory: ["dialogue:skullBossGuzma2.victory.1"], + defeat: ["dialogue:skullBossGuzma2.defeat.1"], }, ], [TrainerType.ROSE]: [ { - encounter: ["dialogue:macro_boss_rose_1.encounter.1"], - victory: ["dialogue:macro_boss_rose_1.victory.1"], - defeat: ["dialogue:macro_boss_rose_1.defeat.1"], + encounter: ["dialogue:macroBossRose1.encounter.1"], + victory: ["dialogue:macroBossRose1.victory.1"], + defeat: ["dialogue:macroBossRose1.defeat.1"], }, ], [TrainerType.ROSE_2]: [ { - encounter: ["dialogue:macro_boss_rose_2.encounter.1"], - victory: ["dialogue:macro_boss_rose_2.victory.1"], - defeat: ["dialogue:macro_boss_rose_2.defeat.1"], + encounter: ["dialogue:macroBossRose2.encounter.1"], + victory: ["dialogue:macroBossRose2.victory.1"], + defeat: ["dialogue:macroBossRose2.defeat.1"], }, ], [TrainerType.PENNY]: [ { - encounter: ["dialogue:star_boss_penny_1.encounter.1"], - victory: ["dialogue:star_boss_penny_1.victory.1"], - defeat: ["dialogue:star_boss_penny_1.defeat.1"], + encounter: ["dialogue:starBossPenny1.encounter.1"], + victory: ["dialogue:starBossPenny1.victory.1"], + defeat: ["dialogue:starBossPenny1.defeat.1"], }, ], [TrainerType.PENNY_2]: [ { - encounter: ["dialogue:star_boss_penny_2.encounter.1"], - victory: ["dialogue:star_boss_penny_2.victory.1"], - defeat: ["dialogue:star_boss_penny_2.defeat.1"], + encounter: ["dialogue:starBossPenny2.encounter.1"], + victory: ["dialogue:starBossPenny2.victory.1"], + defeat: ["dialogue:starBossPenny2.defeat.1"], }, ], [TrainerType.BUCK]: [ { - encounter: ["dialogue:stat_trainer_buck.encounter.1", "dialogue:stat_trainer_buck.encounter.2"], - victory: ["dialogue:stat_trainer_buck.victory.1", "dialogue:stat_trainer_buck.victory.2"], - defeat: ["dialogue:stat_trainer_buck.defeat.1", "dialogue:stat_trainer_buck.defeat.2"], + encounter: ["dialogue:statTrainerBuck.encounter.1", "dialogue:statTrainerBuck.encounter.2"], + victory: ["dialogue:statTrainerBuck.victory.1", "dialogue:statTrainerBuck.victory.2"], + defeat: ["dialogue:statTrainerBuck.defeat.1", "dialogue:statTrainerBuck.defeat.2"], }, ], [TrainerType.CHERYL]: [ { - encounter: ["dialogue:stat_trainer_cheryl.encounter.1", "dialogue:stat_trainer_cheryl.encounter.2"], - victory: ["dialogue:stat_trainer_cheryl.victory.1", "dialogue:stat_trainer_cheryl.victory.2"], - defeat: ["dialogue:stat_trainer_cheryl.defeat.1", "dialogue:stat_trainer_cheryl.defeat.2"], + encounter: ["dialogue:statTrainerCheryl.encounter.1", "dialogue:statTrainerCheryl.encounter.2"], + victory: ["dialogue:statTrainerCheryl.victory.1", "dialogue:statTrainerCheryl.victory.2"], + defeat: ["dialogue:statTrainerCheryl.defeat.1", "dialogue:statTrainerCheryl.defeat.2"], }, ], [TrainerType.MARLEY]: [ { - encounter: ["dialogue:stat_trainer_marley.encounter.1", "dialogue:stat_trainer_marley.encounter.2"], - victory: ["dialogue:stat_trainer_marley.victory.1", "dialogue:stat_trainer_marley.victory.2"], - defeat: ["dialogue:stat_trainer_marley.defeat.1", "dialogue:stat_trainer_marley.defeat.2"], + encounter: ["dialogue:statTrainerMarley.encounter.1", "dialogue:statTrainerMarley.encounter.2"], + victory: ["dialogue:statTrainerMarley.victory.1", "dialogue:statTrainerMarley.victory.2"], + defeat: ["dialogue:statTrainerMarley.defeat.1", "dialogue:statTrainerMarley.defeat.2"], }, ], [TrainerType.MIRA]: [ { - encounter: ["dialogue:stat_trainer_mira.encounter.1", "dialogue:stat_trainer_mira.encounter.2"], - victory: ["dialogue:stat_trainer_mira.victory.1", "dialogue:stat_trainer_mira.victory.2"], - defeat: ["dialogue:stat_trainer_mira.defeat.1", "dialogue:stat_trainer_mira.defeat.2"], + encounter: ["dialogue:statTrainerMira.encounter.1", "dialogue:statTrainerMira.encounter.2"], + victory: ["dialogue:statTrainerMira.victory.1", "dialogue:statTrainerMira.victory.2"], + defeat: ["dialogue:statTrainerMira.defeat.1", "dialogue:statTrainerMira.defeat.2"], }, ], [TrainerType.RILEY]: [ { - encounter: ["dialogue:stat_trainer_riley.encounter.1", "dialogue:stat_trainer_riley.encounter.2"], - victory: ["dialogue:stat_trainer_riley.victory.1", "dialogue:stat_trainer_riley.victory.2"], - defeat: ["dialogue:stat_trainer_riley.defeat.1", "dialogue:stat_trainer_riley.defeat.2"], + encounter: ["dialogue:statTrainerRiley.encounter.1", "dialogue:statTrainerRiley.encounter.2"], + victory: ["dialogue:statTrainerRiley.victory.1", "dialogue:statTrainerRiley.victory.2"], + defeat: ["dialogue:statTrainerRiley.defeat.1", "dialogue:statTrainerRiley.defeat.2"], }, ], [TrainerType.VICTOR]: [ { - encounter: ["dialogue:winstrates_victor.encounter.1"], - victory: ["dialogue:winstrates_victor.victory.1"], + encounter: ["dialogue:winstratesVictor.encounter.1"], + victory: ["dialogue:winstratesVictor.victory.1"], }, ], [TrainerType.VICTORIA]: [ { - encounter: ["dialogue:winstrates_victoria.encounter.1"], - victory: ["dialogue:winstrates_victoria.victory.1"], + encounter: ["dialogue:winstratesVictoria.encounter.1"], + victory: ["dialogue:winstratesVictoria.victory.1"], }, ], [TrainerType.VIVI]: [ { - encounter: ["dialogue:winstrates_vivi.encounter.1"], - victory: ["dialogue:winstrates_vivi.victory.1"], + encounter: ["dialogue:winstratesVivi.encounter.1"], + victory: ["dialogue:winstratesVivi.victory.1"], }, ], [TrainerType.VICKY]: [ { - encounter: ["dialogue:winstrates_vicky.encounter.1"], - victory: ["dialogue:winstrates_vicky.victory.1"], + encounter: ["dialogue:winstratesVicky.encounter.1"], + victory: ["dialogue:winstratesVicky.victory.1"], }, ], [TrainerType.VITO]: [ { - encounter: ["dialogue:winstrates_vito.encounter.1"], - victory: ["dialogue:winstrates_vito.victory.1"], + encounter: ["dialogue:winstratesVito.encounter.1"], + victory: ["dialogue:winstratesVito.victory.1"], }, ], [TrainerType.BROCK]: { @@ -954,9 +946,9 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { defeat: ["dialogue:misty.defeat.1", "dialogue:misty.defeat.2", "dialogue:misty.defeat.3"], }, [TrainerType.LT_SURGE]: { - encounter: ["dialogue:lt_surge.encounter.1", "dialogue:lt_surge.encounter.2", "dialogue:lt_surge.encounter.3"], - victory: ["dialogue:lt_surge.victory.1", "dialogue:lt_surge.victory.2", "dialogue:lt_surge.victory.3"], - defeat: ["dialogue:lt_surge.defeat.1", "dialogue:lt_surge.defeat.2", "dialogue:lt_surge.defeat.3"], + encounter: ["dialogue:ltSurge.encounter.1", "dialogue:ltSurge.encounter.2", "dialogue:ltSurge.encounter.3"], + victory: ["dialogue:ltSurge.victory.1", "dialogue:ltSurge.victory.2", "dialogue:ltSurge.victory.3"], + defeat: ["dialogue:ltSurge.defeat.1", "dialogue:ltSurge.defeat.2", "dialogue:ltSurge.defeat.3"], }, [TrainerType.ERIKA]: { encounter: [ @@ -1055,12 +1047,12 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { }, [TrainerType.CRASHER_WAKE]: { encounter: [ - "dialogue:crasher_wake.encounter.1", - "dialogue:crasher_wake.encounter.2", - "dialogue:crasher_wake.encounter.3", + "dialogue:crasherWake.encounter.1", + "dialogue:crasherWake.encounter.2", + "dialogue:crasherWake.encounter.3", ], - victory: ["dialogue:crasher_wake.victory.1", "dialogue:crasher_wake.victory.2", "dialogue:crasher_wake.victory.3"], - defeat: ["dialogue:crasher_wake.defeat.1", "dialogue:crasher_wake.defeat.2", "dialogue:crasher_wake.defeat.3"], + victory: ["dialogue:crasherWake.victory.1", "dialogue:crasherWake.victory.2", "dialogue:crasherWake.victory.3"], + defeat: ["dialogue:crasherWake.defeat.1", "dialogue:crasherWake.defeat.2", "dialogue:crasherWake.defeat.3"], }, [TrainerType.FALKNER]: { encounter: ["dialogue:falkner.encounter.1", "dialogue:falkner.encounter.2", "dialogue:falkner.encounter.3"], @@ -1354,9 +1346,9 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { defeat: ["dialogue:acerola.defeat.1"], }, [TrainerType.LARRY_ELITE]: { - encounter: ["dialogue:larry_elite.encounter.1"], - victory: ["dialogue:larry_elite.victory.1"], - defeat: ["dialogue:larry_elite.defeat.1"], + encounter: ["dialogue:larryElite.encounter.1"], + victory: ["dialogue:larryElite.victory.1"], + defeat: ["dialogue:larryElite.defeat.1"], }, [TrainerType.LANCE]: { encounter: ["dialogue:lance.encounter.1", "dialogue:lance.encounter.2"], @@ -1414,9 +1406,9 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { defeat: ["dialogue:jasmine.defeat.1"], }, [TrainerType.LANCE_CHAMPION]: { - encounter: ["dialogue:lance_champion.encounter.1"], - victory: ["dialogue:lance_champion.victory.1"], - defeat: ["dialogue:lance_champion.defeat.1"], + encounter: ["dialogue:lanceChampion.encounter.1"], + victory: ["dialogue:lanceChampion.victory.1"], + defeat: ["dialogue:lanceChampion.defeat.1"], }, [TrainerType.STEVEN]: { encounter: ["dialogue:steven.encounter.1"], @@ -1624,29 +1616,29 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { defeat: ["dialogue:grusha.defeat.1"], }, [TrainerType.MARNIE_ELITE]: { - encounter: ["dialogue:marnie_elite.encounter.1", "dialogue:marnie_elite.encounter.2"], - victory: ["dialogue:marnie_elite.victory.1", "dialogue:marnie_elite.victory.2"], - defeat: ["dialogue:marnie_elite.defeat.1", "dialogue:marnie_elite.defeat.2"], + encounter: ["dialogue:marnieElite.encounter.1", "dialogue:marnieElite.encounter.2"], + victory: ["dialogue:marnieElite.victory.1", "dialogue:marnieElite.victory.2"], + defeat: ["dialogue:marnieElite.defeat.1", "dialogue:marnieElite.defeat.2"], }, [TrainerType.NESSA_ELITE]: { - encounter: ["dialogue:nessa_elite.encounter.1", "dialogue:nessa_elite.encounter.2"], - victory: ["dialogue:nessa_elite.victory.1", "dialogue:nessa_elite.victory.2"], - defeat: ["dialogue:nessa_elite.defeat.1", "dialogue:nessa_elite.defeat.2"], + encounter: ["dialogue:nessaElite.encounter.1", "dialogue:nessaElite.encounter.2"], + victory: ["dialogue:nessaElite.victory.1", "dialogue:nessaElite.victory.2"], + defeat: ["dialogue:nessaElite.defeat.1", "dialogue:nessaElite.defeat.2"], }, [TrainerType.BEA_ELITE]: { - encounter: ["dialogue:bea_elite.encounter.1", "dialogue:bea_elite.encounter.2"], - victory: ["dialogue:bea_elite.victory.1", "dialogue:bea_elite.victory.2"], - defeat: ["dialogue:bea_elite.defeat.1", "dialogue:bea_elite.defeat.2"], + encounter: ["dialogue:beaElite.encounter.1", "dialogue:beaElite.encounter.2"], + victory: ["dialogue:beaElite.victory.1", "dialogue:beaElite.victory.2"], + defeat: ["dialogue:beaElite.defeat.1", "dialogue:beaElite.defeat.2"], }, [TrainerType.ALLISTER_ELITE]: { - encounter: ["dialogue:allister_elite.encounter.1", "dialogue:allister_elite.encounter.2"], - victory: ["dialogue:allister_elite.victory.1", "dialogue:allister_elite.victory.2"], - defeat: ["dialogue:allister_elite.defeat.1", "dialogue:allister_elite.defeat.2"], + encounter: ["dialogue:allisterElite.encounter.1", "dialogue:allisterElite.encounter.2"], + victory: ["dialogue:allisterElite.victory.1", "dialogue:allisterElite.victory.2"], + defeat: ["dialogue:allisterElite.defeat.1", "dialogue:allisterElite.defeat.2"], }, [TrainerType.RAIHAN_ELITE]: { - encounter: ["dialogue:raihan_elite.encounter.1", "dialogue:raihan_elite.encounter.2"], - victory: ["dialogue:raihan_elite.victory.1", "dialogue:raihan_elite.victory.2"], - defeat: ["dialogue:raihan_elite.defeat.1", "dialogue:raihan_elite.defeat.2"], + encounter: ["dialogue:raihanElite.encounter.1", "dialogue:raihanElite.encounter.2"], + victory: ["dialogue:raihanElite.victory.1", "dialogue:raihanElite.victory.2"], + defeat: ["dialogue:raihanElite.defeat.1", "dialogue:raihanElite.defeat.2"], }, [TrainerType.ALDER]: { encounter: ["dialogue:alder.encounter.1"], @@ -1664,62 +1656,62 @@ export const trainerTypeDialogue: TrainerTypeDialogue = { victory: ["dialogue:rival.victory.1"], }, { - encounter: ["dialogue:rival_female.encounter.1"], - victory: ["dialogue:rival_female.victory.1"], + encounter: ["dialogue:rivalFemale.encounter.1"], + victory: ["dialogue:rivalFemale.victory.1"], }, ], [TrainerType.RIVAL_2]: [ { - encounter: ["dialogue:rival_2.encounter.1"], - victory: ["dialogue:rival_2.victory.1"], + encounter: ["dialogue:rival2.encounter.1"], + victory: ["dialogue:rival2.victory.1"], }, { - encounter: ["dialogue:rival_2_female.encounter.1"], - victory: ["dialogue:rival_2_female.victory.1"], - defeat: ["dialogue:rival_2_female.defeat.1"], + encounter: ["dialogue:rival2Female.encounter.1"], + victory: ["dialogue:rival2Female.victory.1"], + defeat: ["dialogue:rival2Female.defeat.1"], }, ], [TrainerType.RIVAL_3]: [ { - encounter: ["dialogue:rival_3.encounter.1"], - victory: ["dialogue:rival_3.victory.1"], + encounter: ["dialogue:rival3.encounter.1"], + victory: ["dialogue:rival3.victory.1"], }, { - encounter: ["dialogue:rival_3_female.encounter.1"], - victory: ["dialogue:rival_3_female.victory.1"], - defeat: ["dialogue:rival_3_female.defeat.1"], + encounter: ["dialogue:rival3Female.encounter.1"], + victory: ["dialogue:rival3Female.victory.1"], + defeat: ["dialogue:rival3Female.defeat.1"], }, ], [TrainerType.RIVAL_4]: [ { - encounter: ["dialogue:rival_4.encounter.1"], - victory: ["dialogue:rival_4.victory.1"], + encounter: ["dialogue:rival4.encounter.1"], + victory: ["dialogue:rival4.victory.1"], }, { - encounter: ["dialogue:rival_4_female.encounter.1"], - victory: ["dialogue:rival_4_female.victory.1"], - defeat: ["dialogue:rival_4_female.defeat.1"], + encounter: ["dialogue:rival4Female.encounter.1"], + victory: ["dialogue:rival4Female.victory.1"], + defeat: ["dialogue:rival4Female.defeat.1"], }, ], [TrainerType.RIVAL_5]: [ { - encounter: ["dialogue:rival_5.encounter.1"], - victory: ["dialogue:rival_5.victory.1"], + encounter: ["dialogue:rival5.encounter.1"], + victory: ["dialogue:rival5.victory.1"], }, { - encounter: ["dialogue:rival_5_female.encounter.1"], - victory: ["dialogue:rival_5_female.victory.1"], - defeat: ["dialogue:rival_5_female.defeat.1"], + encounter: ["dialogue:rival5Female.encounter.1"], + victory: ["dialogue:rival5Female.victory.1"], + defeat: ["dialogue:rival5Female.defeat.1"], }, ], [TrainerType.RIVAL_6]: [ { - encounter: ["dialogue:rival_6.encounter.1"], - victory: ["dialogue:rival_6.victory.1"], + encounter: ["dialogue:rival6.encounter.1"], + victory: ["dialogue:rival6.victory.1"], }, { - encounter: ["dialogue:rival_6_female.encounter.1"], - victory: ["dialogue:rival_6_female.victory.1"], + encounter: ["dialogue:rival6Female.encounter.1"], + victory: ["dialogue:rival6Female.victory.1"], }, ], }; diff --git a/src/data/double-battle-dialogue.ts b/src/data/double-battle-dialogue.ts index f15b74e4729..d4deee62037 100644 --- a/src/data/double-battle-dialogue.ts +++ b/src/data/double-battle-dialogue.ts @@ -2,43 +2,43 @@ // that caused this to be moved out in the first place export const doubleBattleDialogue = { blue_red_double: { - encounter: ["doubleBattleDialogue:blue_red_double.encounter.1"], - victory: ["doubleBattleDialogue:blue_red_double.victory.1"], + encounter: ["doubleBattleDialogue:blueRedDouble.encounter.1"], + victory: ["doubleBattleDialogue:blueRedDouble.victory.1"], }, red_blue_double: { - encounter: ["doubleBattleDialogue:red_blue_double.encounter.1"], - victory: ["doubleBattleDialogue:red_blue_double.victory.1"], + encounter: ["doubleBattleDialogue:redBlueDouble.encounter.1"], + victory: ["doubleBattleDialogue:redBlueDouble.victory.1"], }, tate_liza_double: { - encounter: ["doubleBattleDialogue:tate_liza_double.encounter.1"], - victory: ["doubleBattleDialogue:tate_liza_double.victory.1"], + encounter: ["doubleBattleDialogue:tateLizaDouble.encounter.1"], + victory: ["doubleBattleDialogue:tateLizaDouble.victory.1"], }, liza_tate_double: { - encounter: ["doubleBattleDialogue:liza_tate_double.encounter.1"], - victory: ["doubleBattleDialogue:liza_tate_double.victory.1"], + encounter: ["doubleBattleDialogue:lizaTateDouble.encounter.1"], + victory: ["doubleBattleDialogue:lizaTateDouble.victory.1"], }, wallace_steven_double: { - encounter: ["doubleBattleDialogue:wallace_steven_double.encounter.1"], - victory: ["doubleBattleDialogue:wallace_steven_double.victory.1"], + encounter: ["doubleBattleDialogue:wallaceStevenDouble.encounter.1"], + victory: ["doubleBattleDialogue:wallaceStevenDouble.victory.1"], }, steven_wallace_double: { - encounter: ["doubleBattleDialogue:steven_wallace_double.encounter.1"], - victory: ["doubleBattleDialogue:steven_wallace_double.victory.1"], + encounter: ["doubleBattleDialogue:stevenWallaceDouble.encounter.1"], + victory: ["doubleBattleDialogue:stevenWallaceDouble.victory.1"], }, alder_iris_double: { - encounter: ["doubleBattleDialogue:alder_iris_double.encounter.1"], - victory: ["doubleBattleDialogue:alder_iris_double.victory.1"], + encounter: ["doubleBattleDialogue:alderIrisDouble.encounter.1"], + victory: ["doubleBattleDialogue:alderIrisDouble.victory.1"], }, iris_alder_double: { - encounter: ["doubleBattleDialogue:iris_alder_double.encounter.1"], - victory: ["doubleBattleDialogue:iris_alder_double.victory.1"], + encounter: ["doubleBattleDialogue:irisAlderDouble.encounter.1"], + victory: ["doubleBattleDialogue:irisAlderDouble.victory.1"], }, marnie_piers_double: { - encounter: ["doubleBattleDialogue:marnie_piers_double.encounter.1"], - victory: ["doubleBattleDialogue:marnie_piers_double.victory.1"], + encounter: ["doubleBattleDialogue:marniePiersDouble.encounter.1"], + victory: ["doubleBattleDialogue:marniePiersDouble.victory.1"], }, piers_marnie_double: { - encounter: ["doubleBattleDialogue:piers_marnie_double.encounter.1"], - victory: ["doubleBattleDialogue:piers_marnie_double.victory.1"], + encounter: ["doubleBattleDialogue:piersMarnieDouble.encounter.1"], + victory: ["doubleBattleDialogue:piersMarnieDouble.victory.1"], }, }; diff --git a/src/data/mystery-encounters/encounters/fun-and-games-encounter.ts b/src/data/mystery-encounters/encounters/fun-and-games-encounter.ts index 71279b52cfc..d883fdbb567 100644 --- a/src/data/mystery-encounters/encounters/fun-and-games-encounter.ts +++ b/src/data/mystery-encounters/encounters/fun-and-games-encounter.ts @@ -132,7 +132,7 @@ export const FunAndGamesEncounter: MysteryEncounter = MysteryEncounterBuilder.wi const moneyCost = (encounter.options[0].requirements[0] as MoneyRequirement).requiredMoney; updatePlayerMoney(-moneyCost, true, false); await showEncounterText( - i18next.t("mysteryEncounterMessages:paid_money", { + i18next.t("mysteryEncounterMessages:paidMoney", { amount: moneyCost, }), ); diff --git a/src/data/mystery-encounters/encounters/part-timer-encounter.ts b/src/data/mystery-encounters/encounters/part-timer-encounter.ts index d6dfc635608..bf1b077647a 100644 --- a/src/data/mystery-encounters/encounters/part-timer-encounter.ts +++ b/src/data/mystery-encounters/encounters/part-timer-encounter.ts @@ -149,7 +149,7 @@ export const PartTimerEncounter: MysteryEncounter = MysteryEncounterBuilder.with const moneyChange = globalScene.getWaveMoneyAmount(moneyMultiplier); updatePlayerMoney(moneyChange, true, false); await showEncounterText( - i18next.t("mysteryEncounterMessages:receive_money", { + i18next.t("mysteryEncounterMessages:receiveMoney", { amount: moneyChange, }), ); @@ -231,7 +231,7 @@ export const PartTimerEncounter: MysteryEncounter = MysteryEncounterBuilder.with const moneyChange = globalScene.getWaveMoneyAmount(moneyMultiplier); updatePlayerMoney(moneyChange, true, false); await showEncounterText( - i18next.t("mysteryEncounterMessages:receive_money", { + i18next.t("mysteryEncounterMessages:receiveMoney", { amount: moneyChange, }), ); @@ -286,7 +286,7 @@ export const PartTimerEncounter: MysteryEncounter = MysteryEncounterBuilder.with const moneyChange = globalScene.getWaveMoneyAmount(2.5); updatePlayerMoney(moneyChange, true, false); await showEncounterText( - i18next.t("mysteryEncounterMessages:receive_money", { + i18next.t("mysteryEncounterMessages:receiveMoney", { amount: moneyChange, }), ); diff --git a/src/data/mystery-encounters/utils/encounter-phase-utils.ts b/src/data/mystery-encounters/utils/encounter-phase-utils.ts index b599f923534..5c976cbc8cd 100644 --- a/src/data/mystery-encounters/utils/encounter-phase-utils.ts +++ b/src/data/mystery-encounters/utils/encounter-phase-utils.ts @@ -467,7 +467,7 @@ export function updatePlayerMoney(changeValue: number, playSound = true, showMes if (showMessage) { if (changeValue < 0) { globalScene.phaseManager.queueMessage( - i18next.t("mysteryEncounterMessages:paid_money", { + i18next.t("mysteryEncounterMessages:paidMoney", { amount: -changeValue, }), null, @@ -475,7 +475,7 @@ export function updatePlayerMoney(changeValue: number, playSound = true, showMes ); } else { globalScene.phaseManager.queueMessage( - i18next.t("mysteryEncounterMessages:receive_money", { + i18next.t("mysteryEncounterMessages:receiveMoney", { amount: changeValue, }), null, @@ -587,7 +587,7 @@ export function selectPokemonForOption( return true; }, onHover: () => { - showEncounterText(i18next.t("mysteryEncounterMessages:cancel_option"), 0, 0, false); + showEncounterText(i18next.t("mysteryEncounterMessages:cancelOption"), 0, 0, false); }, }); @@ -720,7 +720,7 @@ export function selectOptionThenPokemon( if (onHoverOverCancelOption) { onHoverOverCancelOption(); } - showEncounterText(i18next.t("mysteryEncounterMessages:cancel_option"), 0, 0, false); + showEncounterText(i18next.t("mysteryEncounterMessages:cancelOption"), 0, 0, false); }, }); diff --git a/src/phases/game-over-phase.ts b/src/phases/game-over-phase.ts index 25dfffaa582..9b980f9982c 100644 --- a/src/phases/game-over-phase.ts +++ b/src/phases/game-over-phase.ts @@ -65,8 +65,8 @@ export class GameOverPhase extends BattlePhase { const genderIndex = globalScene.gameData.gender ?? PlayerGender.UNSET; const genderStr = PlayerGender[genderIndex].toLowerCase(); globalScene.ui.showDialogue( - i18next.t("miscDialogue:ending_endless", { context: genderStr }), - i18next.t("miscDialogue:ending_name"), + i18next.t("miscDialogue:endingEndless", { context: genderStr }), + i18next.t("miscDialogue:endingName"), 0, () => this.handleGameOver(), ); diff --git a/src/system/achv.ts b/src/system/achv.ts index f238acbda3a..45718a3690f 100644 --- a/src/system/achv.ts +++ b/src/system/achv.ts @@ -214,244 +214,245 @@ export function getAchievementDescription(localizationKey: string): string { const genderStr = PlayerGender[genderIndex].toLowerCase(); switch (localizationKey) { - case "10K_MONEY": - return i18next.t("achv:MoneyAchv.description", { + case "10KMoney": + return i18next.t("achv:moneyAchv.description", { context: genderStr, moneyAmount: achvs._10K_MONEY.moneyAmount.toLocaleString("en-US"), }); - case "100K_MONEY": - return i18next.t("achv:MoneyAchv.description", { + case "100KMoney": + return i18next.t("achv:moneyAchv.description", { context: genderStr, moneyAmount: achvs._100K_MONEY.moneyAmount.toLocaleString("en-US"), }); - case "1M_MONEY": - return i18next.t("achv:MoneyAchv.description", { + case "1MMoney": + return i18next.t("achv:moneyAchv.description", { context: genderStr, moneyAmount: achvs._1M_MONEY.moneyAmount.toLocaleString("en-US"), }); - case "10M_MONEY": - return i18next.t("achv:MoneyAchv.description", { + case "10MMoney": + return i18next.t("achv:moneyAchv.description", { context: genderStr, moneyAmount: achvs._10M_MONEY.moneyAmount.toLocaleString("en-US"), }); - case "250_DMG": - return i18next.t("achv:DamageAchv.description", { + case "250Dmg": + return i18next.t("achv:damageAchv.description", { context: genderStr, damageAmount: achvs._250_DMG.damageAmount.toLocaleString("en-US"), }); - case "1000_DMG": - return i18next.t("achv:DamageAchv.description", { + case "1000Dmg": + return i18next.t("achv:damageAchv.description", { context: genderStr, damageAmount: achvs._1000_DMG.damageAmount.toLocaleString("en-US"), }); - case "2500_DMG": - return i18next.t("achv:DamageAchv.description", { + case "2500Dmg": + return i18next.t("achv:damageAchv.description", { context: genderStr, damageAmount: achvs._2500_DMG.damageAmount.toLocaleString("en-US"), }); - case "10000_DMG": - return i18next.t("achv:DamageAchv.description", { + case "10000Dmg": + return i18next.t("achv:damageAchv.description", { context: genderStr, damageAmount: achvs._10000_DMG.damageAmount.toLocaleString("en-US"), }); - case "250_HEAL": - return i18next.t("achv:HealAchv.description", { + case "250Heal": + return i18next.t("achv:healAchv.description", { context: genderStr, healAmount: achvs._250_HEAL.healAmount.toLocaleString("en-US"), HP: i18next.t(getShortenedStatKey(Stat.HP)), }); - case "1000_HEAL": - return i18next.t("achv:HealAchv.description", { + case "1000Heal": + return i18next.t("achv:healAchv.description", { context: genderStr, healAmount: achvs._1000_HEAL.healAmount.toLocaleString("en-US"), HP: i18next.t(getShortenedStatKey(Stat.HP)), }); - case "2500_HEAL": - return i18next.t("achv:HealAchv.description", { + case "2500Heal": + return i18next.t("achv:healAchv.description", { context: genderStr, healAmount: achvs._2500_HEAL.healAmount.toLocaleString("en-US"), HP: i18next.t(getShortenedStatKey(Stat.HP)), }); - case "10000_HEAL": - return i18next.t("achv:HealAchv.description", { + case "10000Heal": + return i18next.t("achv:healAchv.description", { context: genderStr, healAmount: achvs._10000_HEAL.healAmount.toLocaleString("en-US"), HP: i18next.t(getShortenedStatKey(Stat.HP)), }); - case "LV_100": - return i18next.t("achv:LevelAchv.description", { + case "lv100": + return i18next.t("achv:levelAchv.description", { context: genderStr, level: achvs.LV_100.level, }); - case "LV_250": - return i18next.t("achv:LevelAchv.description", { + case "lv250": + return i18next.t("achv:levelAchv.description", { context: genderStr, level: achvs.LV_250.level, }); - case "LV_1000": - return i18next.t("achv:LevelAchv.description", { + case "lv1000": + return i18next.t("achv:levelAchv.description", { context: genderStr, level: achvs.LV_1000.level, }); - case "10_RIBBONS": - return i18next.t("achv:RibbonAchv.description", { + case "10Ribbons": + return i18next.t("achv:ribbonAchv.description", { context: genderStr, ribbonAmount: achvs._10_RIBBONS.ribbonAmount.toLocaleString("en-US"), }); - case "25_RIBBONS": - return i18next.t("achv:RibbonAchv.description", { + case "25Ribbons": + return i18next.t("achv:ribbonAchv.description", { context: genderStr, ribbonAmount: achvs._25_RIBBONS.ribbonAmount.toLocaleString("en-US"), }); - case "50_RIBBONS": - return i18next.t("achv:RibbonAchv.description", { + case "50Ribbons": + return i18next.t("achv:ribbonAchv.description", { context: genderStr, ribbonAmount: achvs._50_RIBBONS.ribbonAmount.toLocaleString("en-US"), }); - case "75_RIBBONS": - return i18next.t("achv:RibbonAchv.description", { + case "75Ribbons": + return i18next.t("achv:ribbonAchv.description", { context: genderStr, ribbonAmount: achvs._75_RIBBONS.ribbonAmount.toLocaleString("en-US"), }); - case "100_RIBBONS": - return i18next.t("achv:RibbonAchv.description", { + case "100Ribbons": + return i18next.t("achv:ribbonAchv.description", { context: genderStr, ribbonAmount: achvs._100_RIBBONS.ribbonAmount.toLocaleString("en-US"), }); - case "TRANSFER_MAX_STAT_STAGE": - return i18next.t("achv:TRANSFER_MAX_STAT_STAGE.description", { + case "transferMaxStatStage": + return i18next.t("achv:transferMaxStatStage.description", { context: genderStr, }); - case "MAX_FRIENDSHIP": - return i18next.t("achv:MAX_FRIENDSHIP.description", { + case "maxFriendship": + return i18next.t("achv:maxFriendship.description", { context: genderStr, }); - case "MEGA_EVOLVE": - return i18next.t("achv:MEGA_EVOLVE.description", { context: genderStr }); - case "GIGANTAMAX": - return i18next.t("achv:GIGANTAMAX.description", { context: genderStr }); - case "TERASTALLIZE": - return i18next.t("achv:TERASTALLIZE.description", { context: genderStr }); - case "STELLAR_TERASTALLIZE": - return i18next.t("achv:STELLAR_TERASTALLIZE.description", { + case "megaEvolve": + return i18next.t("achv:megaEvolve.description", { context: genderStr }); + case "gigantamax": + return i18next.t("achv:gigantamax.description", { context: genderStr }); + case "terastallize": + return i18next.t("achv:terastallize.description", { context: genderStr }); + case "stellarTerastallize": + return i18next.t("achv:stellarTerastallize.description", { context: genderStr, }); - case "SPLICE": - return i18next.t("achv:SPLICE.description", { context: genderStr }); - case "MINI_BLACK_HOLE": - return i18next.t("achv:MINI_BLACK_HOLE.description", { + case "splice": + return i18next.t("achv:splice.description", { context: genderStr }); + case "miniBlackHole": + return i18next.t("achv:miniBlackHole.description", { context: genderStr, }); - case "CATCH_MYTHICAL": - return i18next.t("achv:CATCH_MYTHICAL.description", { + case "catchMythical": + return i18next.t("achv:catchMythical.description", { context: genderStr, }); - case "CATCH_SUB_LEGENDARY": - return i18next.t("achv:CATCH_SUB_LEGENDARY.description", { + case "catchSubLegendary": + return i18next.t("achv:catchSubLegendary.description", { context: genderStr, }); - case "CATCH_LEGENDARY": - return i18next.t("achv:CATCH_LEGENDARY.description", { + case "catchLegendary": + return i18next.t("achv:catchLegendary.description", { context: genderStr, }); - case "SEE_SHINY": - return i18next.t("achv:SEE_SHINY.description", { context: genderStr }); - case "SHINY_PARTY": - return i18next.t("achv:SHINY_PARTY.description", { context: genderStr }); - case "HATCH_MYTHICAL": - return i18next.t("achv:HATCH_MYTHICAL.description", { + case "seeShiny": + return i18next.t("achv:seeShiny.description", { context: genderStr }); + case "shinyParty": + return i18next.t("achv:shinyParty.description", { context: genderStr }); + case "hatchMythical": + return i18next.t("achv:hatchMythical.description", { context: genderStr, }); - case "HATCH_SUB_LEGENDARY": - return i18next.t("achv:HATCH_SUB_LEGENDARY.description", { + case "hatchSubLegendary": + return i18next.t("achv:hatchSubLegendary.description", { context: genderStr, }); - case "HATCH_LEGENDARY": - return i18next.t("achv:HATCH_LEGENDARY.description", { + case "hatchLegendary": + return i18next.t("achv:hatchLegendary.description", { context: genderStr, }); - case "HATCH_SHINY": - return i18next.t("achv:HATCH_SHINY.description", { context: genderStr }); - case "HIDDEN_ABILITY": - return i18next.t("achv:HIDDEN_ABILITY.description", { + case "hatchShiny": + return i18next.t("achv:hatchShiny.description", { context: genderStr }); + case "hiddenAbility": + return i18next.t("achv:hiddenAbility.description", { context: genderStr, }); - case "PERFECT_IVS": - return i18next.t("achv:PERFECT_IVS.description", { context: genderStr }); - case "CLASSIC_VICTORY": - return i18next.t("achv:CLASSIC_VICTORY.description", { + case "perfectIvs": + return i18next.t("achv:perfectIvs.description", { context: genderStr }); + case "classicVictory": + return i18next.t("achv:classicVictory.description", { context: genderStr, }); - case "UNEVOLVED_CLASSIC_VICTORY": - return i18next.t("achv:UNEVOLVED_CLASSIC_VICTORY.description", { + case "unevolvedClassicVictory": + return i18next.t("achv:unevolvedClassicVictory.description", { context: genderStr, }); - case "MONO_GEN_ONE": - return i18next.t("achv:MONO_GEN_ONE.description", { context: genderStr }); - case "MONO_GEN_TWO": - return i18next.t("achv:MONO_GEN_TWO.description", { context: genderStr }); - case "MONO_GEN_THREE": - return i18next.t("achv:MONO_GEN_THREE.description", { + case "monoGenOne": + return i18next.t("achv:monoGenOne.description", { context: genderStr }); + case "monoGenTwo": + return i18next.t("achv:monoGenTwo.description", { context: genderStr }); + case "monoGenThree": + return i18next.t("achv:monoGenThree.description", { context: genderStr, }); - case "MONO_GEN_FOUR": - return i18next.t("achv:MONO_GEN_FOUR.description", { + case "monoGenFour": + return i18next.t("achv:monoGenFour.description", { context: genderStr, }); - case "MONO_GEN_FIVE": - return i18next.t("achv:MONO_GEN_FIVE.description", { + case "monoGenFive": + return i18next.t("achv:monoGenFive.description", { context: genderStr, }); - case "MONO_GEN_SIX": - return i18next.t("achv:MONO_GEN_SIX.description", { context: genderStr }); - case "MONO_GEN_SEVEN": - return i18next.t("achv:MONO_GEN_SEVEN.description", { + case "monoGenSix": + return i18next.t("achv:monoGenSix.description", { context: genderStr }); + case "monoGenSeven": + return i18next.t("achv:monoGenSeven.description", { context: genderStr, }); - case "MONO_GEN_EIGHT": - return i18next.t("achv:MONO_GEN_EIGHT.description", { + case "monoGenEight": + return i18next.t("achv:monoGenEight.description", { context: genderStr, }); - case "MONO_GEN_NINE": - return i18next.t("achv:MONO_GEN_NINE.description", { + case "monoGenNine": + return i18next.t("achv:monoGenNine.description", { context: genderStr, }); - case "MONO_NORMAL": - case "MONO_FIGHTING": - case "MONO_FLYING": - case "MONO_POISON": - case "MONO_GROUND": - case "MONO_ROCK": - case "MONO_BUG": - case "MONO_GHOST": - case "MONO_STEEL": - case "MONO_FIRE": - case "MONO_WATER": - case "MONO_GRASS": - case "MONO_ELECTRIC": - case "MONO_PSYCHIC": - case "MONO_ICE": - case "MONO_DRAGON": - case "MONO_DARK": - case "MONO_FAIRY": - return i18next.t("achv:MonoType.description", { + case "monoNormal": + case "monoFighting": + case "monoFlying": + case "monoPoison": + case "monoGround": + case "monoRock": + case "monoBug": + case "monoGhost": + case "monoSteel": + case "monoFire": + case "monoWater": + case "monoGrass": + case "monoElectric": + case "monoPsychic": + case "monoIce": + case "monoDragon": + case "monoDark": + case "monoFairy": + return i18next.t("achv:monoType.description", { context: genderStr, - type: i18next.t(`pokemonInfo:Type.${localizationKey.slice(5)}`), + // Todo: Remove the `toUpperCase()` again after changing the `pokemonInfo.json` locales + type: i18next.t(`pokemonInfo:Type.${localizationKey.slice(4).toUpperCase()}`), }); - case "FRESH_START": - return i18next.t("achv:FRESH_START.description", { context: genderStr }); - case "INVERSE_BATTLE": - return i18next.t("achv:INVERSE_BATTLE.description", { + case "freshStart": + return i18next.t("achv:freshStart.description", { context: genderStr }); + case "inverseBattle": + return i18next.t("achv:inverseBattle.description", { context: genderStr, }); - case "FLIP_STATS": - return i18next.t("achv:FLIP_STATS.description", { context: genderStr }); - case "FLIP_INVERSE": - return i18next.t("achv:FLIP_INVERSE.description", { context: genderStr }); - case "NUZLOCKE": - return i18next.t("achv:NUZLOCKE.description", { context: genderStr }); - case "BREEDERS_IN_SPACE": - return i18next.t("achv:BREEDERS_IN_SPACE.description", { + case "flipStats": + return i18next.t("achv:flipStats.description", { context: genderStr }); + case "flipInverse": + return i18next.t("achv:flipInverse.description", { context: genderStr }); + case "nuzlocke": + return i18next.t("achv:nuzlocke.description", { context: genderStr }); + case "breedersInSpace": + return i18next.t("achv:breedersInSpace.description", { context: genderStr, }); default: @@ -460,84 +461,84 @@ export function getAchievementDescription(localizationKey: string): string { } export const achvs = { - _10K_MONEY: new MoneyAchv("10K_MONEY", "", 10000, "nugget", 10), - _100K_MONEY: new MoneyAchv("100K_MONEY", "", 100000, "big_nugget", 25).setSecret(true), - _1M_MONEY: new MoneyAchv("1M_MONEY", "", 1000000, "relic_gold", 50).setSecret(true), - _10M_MONEY: new MoneyAchv("10M_MONEY", "", 10000000, "coin_case", 100).setSecret(true), - _250_DMG: new DamageAchv("250_DMG", "", 250, "lucky_punch", 10), - _1000_DMG: new DamageAchv("1000_DMG", "", 1000, "lucky_punch_great", 25).setSecret(true), - _2500_DMG: new DamageAchv("2500_DMG", "", 2500, "lucky_punch_ultra", 50).setSecret(true), - _10000_DMG: new DamageAchv("10000_DMG", "", 10000, "lucky_punch_master", 100).setSecret(true), - _250_HEAL: new HealAchv("250_HEAL", "", 250, "potion", 10), - _1000_HEAL: new HealAchv("1000_HEAL", "", 1000, "super_potion", 25).setSecret(true), - _2500_HEAL: new HealAchv("2500_HEAL", "", 2500, "hyper_potion", 50).setSecret(true), - _10000_HEAL: new HealAchv("10000_HEAL", "", 10000, "max_potion", 100).setSecret(true), - LV_100: new LevelAchv("LV_100", "", 100, "rare_candy", 25).setSecret(), - LV_250: new LevelAchv("LV_250", "", 250, "rarer_candy", 50).setSecret(true), - LV_1000: new LevelAchv("LV_1000", "", 1000, "candy_jar", 100).setSecret(true), - _10_RIBBONS: new RibbonAchv("10_RIBBONS", "", 10, "bronze_ribbon", 10), - _25_RIBBONS: new RibbonAchv("25_RIBBONS", "", 25, "great_ribbon", 25).setSecret(true), - _50_RIBBONS: new RibbonAchv("50_RIBBONS", "", 50, "ultra_ribbon", 50).setSecret(true), - _75_RIBBONS: new RibbonAchv("75_RIBBONS", "", 75, "rogue_ribbon", 75).setSecret(true), - _100_RIBBONS: new RibbonAchv("100_RIBBONS", "", 100, "master_ribbon", 100).setSecret(true), - TRANSFER_MAX_STAT_STAGE: new Achv("TRANSFER_MAX_STAT_STAGE", "", "TRANSFER_MAX_STAT_STAGE.description", "baton", 20), - MAX_FRIENDSHIP: new Achv("MAX_FRIENDSHIP", "", "MAX_FRIENDSHIP.description", "soothe_bell", 25), - MEGA_EVOLVE: new Achv("MEGA_EVOLVE", "", "MEGA_EVOLVE.description", "mega_bracelet", 50), - GIGANTAMAX: new Achv("GIGANTAMAX", "", "GIGANTAMAX.description", "dynamax_band", 50), - TERASTALLIZE: new Achv("TERASTALLIZE", "", "TERASTALLIZE.description", "tera_orb", 25), + _10K_MONEY: new MoneyAchv("10KMoney", "", 10000, "nugget", 10), + _100K_MONEY: new MoneyAchv("100KMoney", "", 100000, "big_nugget", 25).setSecret(true), + _1M_MONEY: new MoneyAchv("1MMoney", "", 1000000, "relic_gold", 50).setSecret(true), + _10M_MONEY: new MoneyAchv("10MMoney", "", 10000000, "coin_case", 100).setSecret(true), + _250_DMG: new DamageAchv("250Dmg", "", 250, "lucky_punch", 10), + _1000_DMG: new DamageAchv("1000Dmg", "", 1000, "lucky_punch_great", 25).setSecret(true), + _2500_DMG: new DamageAchv("2500Dmg", "", 2500, "lucky_punch_ultra", 50).setSecret(true), + _10000_DMG: new DamageAchv("10000Dmg", "", 10000, "lucky_punch_master", 100).setSecret(true), + _250_HEAL: new HealAchv("250Heal", "", 250, "potion", 10), + _1000_HEAL: new HealAchv("1000Heal", "", 1000, "super_potion", 25).setSecret(true), + _2500_HEAL: new HealAchv("2500Heal", "", 2500, "hyper_potion", 50).setSecret(true), + _10000_HEAL: new HealAchv("10000Heal", "", 10000, "max_potion", 100).setSecret(true), + LV_100: new LevelAchv("lv100", "", 100, "rare_candy", 25).setSecret(), + LV_250: new LevelAchv("lv250", "", 250, "rarer_candy", 50).setSecret(true), + LV_1000: new LevelAchv("lv1000", "", 1000, "candy_jar", 100).setSecret(true), + _10_RIBBONS: new RibbonAchv("10Ribbons", "", 10, "bronze_ribbon", 10), + _25_RIBBONS: new RibbonAchv("25Ribbons", "", 25, "great_ribbon", 25).setSecret(true), + _50_RIBBONS: new RibbonAchv("50Ribbons", "", 50, "ultra_ribbon", 50).setSecret(true), + _75_RIBBONS: new RibbonAchv("75Ribbons", "", 75, "rogue_ribbon", 75).setSecret(true), + _100_RIBBONS: new RibbonAchv("100Ribbons", "", 100, "master_ribbon", 100).setSecret(true), + TRANSFER_MAX_STAT_STAGE: new Achv("transferMaxStatStage", "", "transferMaxStatStage.description", "baton", 20), + MAX_FRIENDSHIP: new Achv("maxFriendship", "", "maxFriendship.description", "soothe_bell", 25), + MEGA_EVOLVE: new Achv("megaEvolve", "", "megaEvolve.description", "mega_bracelet", 50), + GIGANTAMAX: new Achv("gigantamax", "", "gigantamax.description", "dynamax_band", 50), + TERASTALLIZE: new Achv("terastallize", "", "terastallize.description", "tera_orb", 25), STELLAR_TERASTALLIZE: new Achv( - "STELLAR_TERASTALLIZE", + "stellarTerastallize", "", - "STELLAR_TERASTALLIZE.description", + "stellarTerastallize.description", "stellar_tera_shard", 25, ).setSecret(true), - SPLICE: new Achv("SPLICE", "", "SPLICE.description", "dna_splicers", 10), + SPLICE: new Achv("splice", "", "splice.description", "dna_splicers", 10), MINI_BLACK_HOLE: new ModifierAchv( - "MINI_BLACK_HOLE", + "miniBlackHole", "", - "MINI_BLACK_HOLE.description", + "miniBlackHole.description", "mini_black_hole", 25, modifier => modifier instanceof TurnHeldItemTransferModifier, ).setSecret(), - CATCH_MYTHICAL: new Achv("CATCH_MYTHICAL", "", "CATCH_MYTHICAL.description", "strange_ball", 50).setSecret(), - CATCH_SUB_LEGENDARY: new Achv("CATCH_SUB_LEGENDARY", "", "CATCH_SUB_LEGENDARY.description", "rb", 75).setSecret(), - CATCH_LEGENDARY: new Achv("CATCH_LEGENDARY", "", "CATCH_LEGENDARY.description", "mb", 100).setSecret(), - SEE_SHINY: new Achv("SEE_SHINY", "", "SEE_SHINY.description", "pb_gold", 75), - SHINY_PARTY: new Achv("SHINY_PARTY", "", "SHINY_PARTY.description", "shiny_charm", 100).setSecret(true), - HATCH_MYTHICAL: new Achv("HATCH_MYTHICAL", "", "HATCH_MYTHICAL.description", "mystery_egg", 75).setSecret(), + CATCH_MYTHICAL: new Achv("catchMythical", "", "catchMythical.description", "strange_ball", 50).setSecret(), + CATCH_SUB_LEGENDARY: new Achv("catchSubLegendary", "", "catchSubLegendary.description", "rb", 75).setSecret(), + CATCH_LEGENDARY: new Achv("catchLegendary", "", "catchLegendary.description", "mb", 100).setSecret(), + SEE_SHINY: new Achv("seeShiny", "", "seeShiny.description", "pb_gold", 75), + SHINY_PARTY: new Achv("shinyParty", "", "shinyParty.description", "shiny_charm", 100).setSecret(true), + HATCH_MYTHICAL: new Achv("hatchMythical", "", "hatchMythical.description", "mystery_egg", 75).setSecret(), HATCH_SUB_LEGENDARY: new Achv( - "HATCH_SUB_LEGENDARY", + "hatchSubLegendary", "", - "HATCH_SUB_LEGENDARY.description", + "hatchSubLegendary.description", "oval_stone", 100, ).setSecret(), - HATCH_LEGENDARY: new Achv("HATCH_LEGENDARY", "", "HATCH_LEGENDARY.description", "lucky_egg", 125).setSecret(), - HATCH_SHINY: new Achv("HATCH_SHINY", "", "HATCH_SHINY.description", "golden_egg", 100).setSecret(), - HIDDEN_ABILITY: new Achv("HIDDEN_ABILITY", "", "HIDDEN_ABILITY.description", "ability_charm", 75), - PERFECT_IVS: new Achv("PERFECT_IVS", "", "PERFECT_IVS.description", "blunder_policy", 100), + HATCH_LEGENDARY: new Achv("hatchLegendary", "", "hatchLegendary.description", "lucky_egg", 125).setSecret(), + HATCH_SHINY: new Achv("hatchShiny", "", "hatchShiny.description", "golden_egg", 100).setSecret(), + HIDDEN_ABILITY: new Achv("hiddenAbility", "", "hiddenAbility.description", "ability_charm", 75), + PERFECT_IVS: new Achv("perfectIvs", "", "perfectIvs.description", "blunder_policy", 100), CLASSIC_VICTORY: new Achv( - "CLASSIC_VICTORY", + "classicVictory", "", - "CLASSIC_VICTORY.description", + "classicVictory.description", "relic_crown", 150, _ => globalScene.gameData.gameStats.sessionsWon === 0, ), UNEVOLVED_CLASSIC_VICTORY: new Achv( - "UNEVOLVED_CLASSIC_VICTORY", + "unevolvedClassicVictory", "", - "UNEVOLVED_CLASSIC_VICTORY.description", + "unevolvedClassicVictory.description", "eviolite", 175, _ => globalScene.getPlayerParty().some(p => p.getSpeciesForm(true).speciesId in pokemonEvolutions), ), MONO_GEN_ONE_VICTORY: new ChallengeAchv( - "MONO_GEN_ONE", + "monoGenOne", "", - "MONO_GEN_ONE.description", + "monoGenOne.description", "ribbon_gen1", 100, c => @@ -548,9 +549,9 @@ export const achvs = { ), ), MONO_GEN_TWO_VICTORY: new ChallengeAchv( - "MONO_GEN_TWO", + "monoGenTwo", "", - "MONO_GEN_TWO.description", + "monoGenTwo.description", "ribbon_gen2", 100, c => @@ -561,9 +562,9 @@ export const achvs = { ), ), MONO_GEN_THREE_VICTORY: new ChallengeAchv( - "MONO_GEN_THREE", + "monoGenThree", "", - "MONO_GEN_THREE.description", + "monoGenThree.description", "ribbon_gen3", 100, c => @@ -574,9 +575,9 @@ export const achvs = { ), ), MONO_GEN_FOUR_VICTORY: new ChallengeAchv( - "MONO_GEN_FOUR", + "monoGenFour", "", - "MONO_GEN_FOUR.description", + "monoGenFour.description", "ribbon_gen4", 100, c => @@ -587,9 +588,9 @@ export const achvs = { ), ), MONO_GEN_FIVE_VICTORY: new ChallengeAchv( - "MONO_GEN_FIVE", + "monoGenFive", "", - "MONO_GEN_FIVE.description", + "monoGenFive.description", "ribbon_gen5", 100, c => @@ -600,9 +601,9 @@ export const achvs = { ), ), MONO_GEN_SIX_VICTORY: new ChallengeAchv( - "MONO_GEN_SIX", + "monoGenSix", "", - "MONO_GEN_SIX.description", + "monoGenSix.description", "ribbon_gen6", 100, c => @@ -613,9 +614,9 @@ export const achvs = { ), ), MONO_GEN_SEVEN_VICTORY: new ChallengeAchv( - "MONO_GEN_SEVEN", + "monoGenSeven", "", - "MONO_GEN_SEVEN.description", + "monoGenSeven.description", "ribbon_gen7", 100, c => @@ -626,9 +627,9 @@ export const achvs = { ), ), MONO_GEN_EIGHT_VICTORY: new ChallengeAchv( - "MONO_GEN_EIGHT", + "monoGenEight", "", - "MONO_GEN_EIGHT.description", + "monoGenEight.description", "ribbon_gen8", 100, c => @@ -639,9 +640,9 @@ export const achvs = { ), ), MONO_GEN_NINE_VICTORY: new ChallengeAchv( - "MONO_GEN_NINE", + "monoGenNine", "", - "MONO_GEN_NINE.description", + "monoGenNine.description", "ribbon_gen9", 100, c => @@ -652,9 +653,9 @@ export const achvs = { ), ), MONO_NORMAL: new ChallengeAchv( - "MONO_NORMAL", + "monoNormal", "", - "MONO_NORMAL.description", + "monoNormal.description", "silk_scarf", 100, c => @@ -665,9 +666,9 @@ export const achvs = { ), ), MONO_FIGHTING: new ChallengeAchv( - "MONO_FIGHTING", + "monoFighting", "", - "MONO_FIGHTING.description", + "monoFighting.description", "black_belt", 100, c => @@ -678,9 +679,9 @@ export const achvs = { ), ), MONO_FLYING: new ChallengeAchv( - "MONO_FLYING", + "monoFlying", "", - "MONO_FLYING.description", + "monoFlying.description", "sharp_beak", 100, c => @@ -691,9 +692,9 @@ export const achvs = { ), ), MONO_POISON: new ChallengeAchv( - "MONO_POISON", + "monoPoison", "", - "MONO_POISON.description", + "monoPoison.description", "poison_barb", 100, c => @@ -704,9 +705,9 @@ export const achvs = { ), ), MONO_GROUND: new ChallengeAchv( - "MONO_GROUND", + "monoGround", "", - "MONO_GROUND.description", + "monoGround.description", "soft_sand", 100, c => @@ -717,9 +718,9 @@ export const achvs = { ), ), MONO_ROCK: new ChallengeAchv( - "MONO_ROCK", + "monoRock", "", - "MONO_ROCK.description", + "monoRock.description", "hard_stone", 100, c => @@ -730,9 +731,9 @@ export const achvs = { ), ), MONO_BUG: new ChallengeAchv( - "MONO_BUG", + "monoBug", "", - "MONO_BUG.description", + "monoBug.description", "silver_powder", 100, c => @@ -743,9 +744,9 @@ export const achvs = { ), ), MONO_GHOST: new ChallengeAchv( - "MONO_GHOST", + "monoGhost", "", - "MONO_GHOST.description", + "monoGhost.description", "spell_tag", 100, c => @@ -756,9 +757,9 @@ export const achvs = { ), ), MONO_STEEL: new ChallengeAchv( - "MONO_STEEL", + "monoSteel", "", - "MONO_STEEL.description", + "monoSteel.description", "metal_coat", 100, c => @@ -769,9 +770,9 @@ export const achvs = { ), ), MONO_FIRE: new ChallengeAchv( - "MONO_FIRE", + "monoFire", "", - "MONO_FIRE.description", + "monoFire.description", "charcoal", 100, c => @@ -782,9 +783,9 @@ export const achvs = { ), ), MONO_WATER: new ChallengeAchv( - "MONO_WATER", + "monoWater", "", - "MONO_WATER.description", + "monoWater.description", "mystic_water", 100, c => @@ -795,9 +796,9 @@ export const achvs = { ), ), MONO_GRASS: new ChallengeAchv( - "MONO_GRASS", + "monoGrass", "", - "MONO_GRASS.description", + "monoGrass.description", "miracle_seed", 100, c => @@ -808,9 +809,9 @@ export const achvs = { ), ), MONO_ELECTRIC: new ChallengeAchv( - "MONO_ELECTRIC", + "monoElectric", "", - "MONO_ELECTRIC.description", + "monoElectric.description", "magnet", 100, c => @@ -821,9 +822,9 @@ export const achvs = { ), ), MONO_PSYCHIC: new ChallengeAchv( - "MONO_PSYCHIC", + "monoPsychic", "", - "MONO_PSYCHIC.description", + "monoPsychic.description", "twisted_spoon", 100, c => @@ -834,9 +835,9 @@ export const achvs = { ), ), MONO_ICE: new ChallengeAchv( - "MONO_ICE", + "monoIce", "", - "MONO_ICE.description", + "monoIce.description", "never_melt_ice", 100, c => @@ -847,9 +848,9 @@ export const achvs = { ), ), MONO_DRAGON: new ChallengeAchv( - "MONO_DRAGON", + "monoDragon", "", - "MONO_DRAGON.description", + "monoDragon.description", "dragon_fang", 100, c => @@ -860,9 +861,9 @@ export const achvs = { ), ), MONO_DARK: new ChallengeAchv( - "MONO_DARK", + "monoDark", "", - "MONO_DARK.description", + "monoDark.description", "black_glasses", 100, c => @@ -873,9 +874,9 @@ export const achvs = { ), ), MONO_FAIRY: new ChallengeAchv( - "MONO_FAIRY", + "monoFairy", "", - "MONO_FAIRY.description", + "monoFairy.description", "fairy_feather", 100, c => @@ -886,9 +887,9 @@ export const achvs = { ), ), FRESH_START: new ChallengeAchv( - "FRESH_START", + "freshStart", "", - "FRESH_START.description", + "freshStart.description", "reviver_seed", 100, c => @@ -899,25 +900,25 @@ export const achvs = { ), ), INVERSE_BATTLE: new ChallengeAchv( - "INVERSE_BATTLE", + "inverseBattle", "", - "INVERSE_BATTLE.description", + "inverseBattle.description", "inverse", 100, c => c instanceof InverseBattleChallenge && c.value > 0, ), FLIP_STATS: new ChallengeAchv( - "FLIP_STATS", + "flipStats", "", - "FLIP_STATS.description", + "flipStats.description", "dubious_disc", 100, c => c instanceof FlipStatChallenge && c.value > 0, ), FLIP_INVERSE: new ChallengeAchv( - "FLIP_INVERSE", + "flipInverse", "", - "FLIP_INVERSE.description", + "flipInverse.description", "cracked_pot", 100, c => @@ -926,8 +927,8 @@ export const achvs = { globalScene.gameMode.challenges.some(c => c.id === Challenges.INVERSE_BATTLE && c.value > 0), ).setSecret(), // TODO: Decide on icon - NUZLOCKE: new ChallengeAchv("NUZLOCKE", "", "NUZLOCKE.description", "leaf_stone", 100, isNuzlockeChallenge), - BREEDERS_IN_SPACE: new Achv("BREEDERS_IN_SPACE", "", "BREEDERS_IN_SPACE.description", "moon_stone", 50).setSecret(), + NUZLOCKE: new ChallengeAchv("nuzlocke", "", "nuzlocke.description", "leaf_stone", 100, isNuzlockeChallenge), + BREEDERS_IN_SPACE: new Achv("breedersInSpace", "", "breedersInSpace.description", "moon_stone", 50).setSecret(), }; export function initAchievements() { diff --git a/src/ui/achvs-ui-handler.ts b/src/ui/achvs-ui-handler.ts index 2c04e24e0f2..7763e3be7fe 100644 --- a/src/ui/achvs-ui-handler.ts +++ b/src/ui/achvs-ui-handler.ts @@ -96,7 +96,7 @@ export class AchvsUiHandler extends MessageUiHandler { const genderIndex = globalScene.gameData.gender ?? PlayerGender.MALE; const genderStr = PlayerGender[genderIndex].toLowerCase(); - this.achvsName = i18next.t("achv:Achievements.name", { context: genderStr }); + this.achvsName = i18next.t("achv:achievements.name", { context: genderStr }); this.vouchersName = i18next.t("voucher:vouchers"); this.iconsBg = addWindow(0, this.headerBg.height, WIDTH - 2, HEIGHT - this.headerBg.height - 68).setOrigin(0); @@ -214,7 +214,7 @@ export class AchvsUiHandler extends MessageUiHandler { this.showText(!hidden ? achv.description : ""); this.scoreText.setText(`${achv.score}pt`); this.unlockText.setText( - unlocked ? new Date(achvUnlocks[achv.id]).toLocaleDateString() : i18next.t("achv:Locked.name"), + unlocked ? new Date(achvUnlocks[achv.id]).toLocaleDateString() : i18next.t("achv:locked.name"), ); } diff --git a/src/ui/bgm-bar.ts b/src/ui/bgm-bar.ts index e2c6925ec30..f24f372a804 100644 --- a/src/ui/bgm-bar.ts +++ b/src/ui/bgm-bar.ts @@ -1,7 +1,7 @@ import { globalScene } from "#app/global-scene"; import { TextStyle } from "#enums/text-style"; import { addTextObject } from "#ui/text"; -import { toTitleCase } from "#utils/strings"; +import { toCamelCase, toTitleCase } from "#utils/strings"; import i18next from "i18next"; const hiddenX = -150; @@ -100,7 +100,7 @@ export class BgmBar extends Phaser.GameObjects.Container { } getRealBgmName(bgmName: string): string { - return i18next.t([`bgmName:${bgmName}`, "bgmName:missing_entries"], { + return i18next.t([`bgmName:${toCamelCase(bgmName)}`, "bgmName:missingEntries"], { name: toTitleCase(bgmName), }); } diff --git a/src/ui/menu-ui-handler.ts b/src/ui/menu-ui-handler.ts index da6bc9ced78..4f6d6ede488 100644 --- a/src/ui/menu-ui-handler.ts +++ b/src/ui/menu-ui-handler.ts @@ -17,6 +17,7 @@ import { addWindow, WindowVariant } from "#ui/ui-theme"; import { fixedInt, isLocal, sessionIdKey } from "#utils/common"; import { getCookie } from "#utils/cookies"; import { getEnumValues } from "#utils/enums"; +import { toCamelCase } from "#utils/strings"; import { isBeta } from "#utils/utility-vars"; import i18next from "i18next"; @@ -138,7 +139,7 @@ export class MenuUiHandler extends MessageUiHandler { this.optionSelectText = addTextObject( 0, 0, - this.menuOptions.map(o => `${i18next.t(`menuUiHandler:${MenuOptions[o]}`)}`).join("\n"), + this.menuOptions.map(o => `${i18next.t(`menuUiHandler:${toCamelCase(MenuOptions[o])}`)}`).join("\n"), TextStyle.WINDOW, { maxLines: this.menuOptions.length }, ); diff --git a/src/ui/mystery-encounter-ui-handler.ts b/src/ui/mystery-encounter-ui-handler.ts index 881c375fa8a..37f77cf43b9 100644 --- a/src/ui/mystery-encounter-ui-handler.ts +++ b/src/ui/mystery-encounter-ui-handler.ts @@ -473,7 +473,7 @@ export class MysteryEncounterUiHandler extends UiHandler { const viewPartyText = addBBCodeTextObject( globalScene.scaledCanvas.width, -24, - getBBCodeFrag(i18next.t("mysteryEncounterMessages:view_party_button"), TextStyle.PARTY), + getBBCodeFrag(i18next.t("mysteryEncounterMessages:viewPartyButton"), TextStyle.PARTY), TextStyle.PARTY, ); this.optionsContainer.add(viewPartyText); @@ -694,7 +694,7 @@ export class MysteryEncounterUiHandler extends UiHandler { duration: 750, onComplete: () => { this.dexProgressContainer.on("pointerover", () => { - globalScene.ui.showTooltip("", i18next.t("mysteryEncounterMessages:affects_pokedex"), true); + globalScene.ui.showTooltip("", i18next.t("mysteryEncounterMessages:affectsPokedex"), true); }); this.dexProgressContainer.on("pointerout", () => { globalScene.ui.hideTooltip(); diff --git a/src/ui/pokedex-page-ui-handler.ts b/src/ui/pokedex-page-ui-handler.ts index 49658d9cfc9..ae89a85c402 100644 --- a/src/ui/pokedex-page-ui-handler.ts +++ b/src/ui/pokedex-page-ui-handler.ts @@ -57,7 +57,7 @@ import { addWindow } from "#ui/ui-theme"; import { BooleanHolder, getLocalizedSpriteKey, isNullOrUndefined, padInt, rgbHexToRgba } from "#utils/common"; import { getEnumValues } from "#utils/enums"; import { getPokemonSpecies, getPokemonSpeciesForm } from "#utils/pokemon-utils"; -import { toTitleCase } from "#utils/strings"; +import { toCamelCase, toTitleCase } from "#utils/strings"; import { argbFromRgba } from "@material/material-color-utilities"; import i18next from "i18next"; import type BBCodeText from "phaser3-rex-plugins/plugins/gameobjects/tagtext/bbcodetext/BBCodeText"; @@ -1517,13 +1517,13 @@ export class PokedexPageUiHandler extends MessageUiHandler { this.biomes.map(b => { options.push({ label: - i18next.t(`biome:${BiomeId[b.biome].toUpperCase()}`) + + i18next.t(`biome:${toCamelCase(BiomeId[b.biome])}`) + " - " + - i18next.t(`biome:${BiomePoolTier[b.tier].toUpperCase()}`) + + i18next.t(`biome:${toCamelCase(BiomePoolTier[b.tier])}`) + (b.tod.length === 1 && b.tod[0] === -1 ? "" : " (" + - b.tod.map(tod => i18next.t(`biome:${TimeOfDay[tod].toUpperCase()}`)).join(", ") + + b.tod.map(tod => i18next.t(`biome:${toCamelCase(TimeOfDay[tod])}`)).join(", ") + ")"), handler: () => false, }); @@ -1538,13 +1538,13 @@ export class PokedexPageUiHandler extends MessageUiHandler { this.preBiomes.map(b => { options.push({ label: - i18next.t(`biome:${BiomeId[b.biome].toUpperCase()}`) + + i18next.t(`biome:${toCamelCase(BiomeId[b.biome])}`) + " - " + - i18next.t(`biome:${BiomePoolTier[b.tier].toUpperCase()}`) + + i18next.t(`biome:${toCamelCase(BiomePoolTier[b.tier])}`) + (b.tod.length === 1 && b.tod[0] === -1 ? "" : " (" + - b.tod.map(tod => i18next.t(`biome:${TimeOfDay[tod].toUpperCase()}`)).join(", ") + + b.tod.map(tod => i18next.t(`biome:${toCamelCase(TimeOfDay[tod])}`)).join(", ") + ")"), handler: () => false, }); @@ -2612,7 +2612,7 @@ export class PokedexPageUiHandler extends MessageUiHandler { // Setting growth rate text if (isFormCaught) { let growthReadable = toTitleCase(GrowthRate[species.growthRate]); - const growthAux = growthReadable.replace(" ", "_"); + const growthAux = toCamelCase(growthReadable); if (i18next.exists("growth:" + growthAux)) { growthReadable = i18next.t(("growth:" + growthAux) as any); } diff --git a/src/ui/pokedex-ui-handler.ts b/src/ui/pokedex-ui-handler.ts index 6a6afea9798..034f4f8e615 100644 --- a/src/ui/pokedex-ui-handler.ts +++ b/src/ui/pokedex-ui-handler.ts @@ -47,6 +47,7 @@ import { BooleanHolder, fixedInt, getLocalizedSpriteKey, padInt, randIntRange, r import type { StarterPreferences } from "#utils/data"; import { loadStarterPreferences } from "#utils/data"; import { getPokemonSpeciesForm, getPokerusStarters } from "#utils/pokemon-utils"; +import { toCamelCase } from "#utils/strings"; import { argbFromRgba } from "@material/material-color-utilities"; import i18next from "i18next"; @@ -324,7 +325,7 @@ export class PokedexUiHandler extends MessageUiHandler { .filter(value => typeof value === "number") // Filter numeric values from the enum .map( (biomeValue, index) => - new DropDownOption(index, new DropDownLabel(i18next.t(`biome:${BiomeId[biomeValue].toUpperCase()}`))), + new DropDownOption(index, new DropDownLabel(i18next.t(`biome:${toCamelCase(BiomeId[biomeValue])}`))), ); biomeOptions.push(new DropDownOption(biomeOptions.length, new DropDownLabel(i18next.t("filterBar:uncatchable")))); const biomeDropDown: DropDown = new DropDown(0, 0, biomeOptions, this.updateStarters, DropDownType.HYBRID); diff --git a/src/ui/starter-select-ui-handler.ts b/src/ui/starter-select-ui-handler.ts index 82467506720..83a38ed7fe0 100644 --- a/src/ui/starter-select-ui-handler.ts +++ b/src/ui/starter-select-ui-handler.ts @@ -73,7 +73,7 @@ import { import type { StarterPreferences } from "#utils/data"; import { loadStarterPreferences, saveStarterPreferences } from "#utils/data"; import { getPokemonSpeciesForm, getPokerusStarters } from "#utils/pokemon-utils"; -import { toTitleCase } from "#utils/strings"; +import { toCamelCase, toTitleCase } from "#utils/strings"; import { argbFromRgba } from "@material/material-color-utilities"; import i18next from "i18next"; import type { GameObjects } from "phaser"; @@ -2264,7 +2264,7 @@ export class StarterSelectUiHandler extends MessageUiHandler { }); }; options.push({ - label: i18next.t("menuUiHandler:POKEDEX"), + label: i18next.t("menuUiHandler:pokedex"), handler: () => { ui.setMode(UiMode.STARTER_SELECT).then(() => { const attributes = { @@ -3470,7 +3470,7 @@ export class StarterSelectUiHandler extends MessageUiHandler { //Growth translate let growthReadable = toTitleCase(GrowthRate[species.growthRate]); - const growthAux = growthReadable.replace(" ", "_"); + const growthAux = toCamelCase(growthReadable); if (i18next.exists("growth:" + growthAux)) { growthReadable = i18next.t(("growth:" + growthAux) as any); } From 06496f913514d46f13123f1fd9b51f0d558bc675 Mon Sep 17 00:00:00 2001 From: fabske0 <192151969+fabske0@users.noreply.github.com> Date: Sun, 17 Aug 2025 22:13:09 +0200 Subject: [PATCH 06/11] [i18n] Change i18n keys to be camel case Part 3 (#6266) * chnage nature locales use * chnage party ui locales use * change pokemon category locales use * chnage pokemon evos locales uses * change pokemon form battle use * change pokemon form uses * Change pokemon info uses * fix `stat.ts` workflow fail * Change pokemon summary * Change pokemon localize * Temporarily revert changes to `achv.ts` * Re-add changes to `achv.ts` * Update locales submodule --- public/locales | 2 +- src/data/abilities/ability.ts | 8 +++--- src/data/balance/pokemon-evolutions.ts | 11 ++++---- src/data/battler-tags.ts | 3 ++- src/data/challenge.ts | 2 +- src/data/moves/move.ts | 6 ++--- src/data/nature.ts | 4 +-- .../pokemon-forms/form-change-triggers.ts | 26 +++++++++---------- src/data/pokemon-species.ts | 20 +++++++------- src/enums/stat.ts | 4 +-- src/modifier/modifier-type.ts | 7 ++--- src/phases/tera-phase.ts | 3 ++- src/system/achv.ts | 4 +-- src/ui/base-stats-overlay.ts | 5 +++- src/ui/battle-info/battle-info.ts | 3 ++- src/ui/confirm-ui-handler.ts | 4 +-- src/ui/party-ui-handler.ts | 16 ++++++------ src/ui/run-info-ui-handler.ts | 18 ++++++++----- src/ui/summary-ui-handler.ts | 4 +-- 19 files changed, 83 insertions(+), 67 deletions(-) diff --git a/public/locales b/public/locales index 100e607c03d..38d7c1baa23 160000 --- a/public/locales +++ b/public/locales @@ -1 +1 @@ -Subproject commit 100e607c03d9c5ea0d405b2b75300cd0e6fa1635 +Subproject commit 38d7c1baa2367582770d62b3f4b0239874c1c7e5 diff --git a/src/data/abilities/ability.ts b/src/data/abilities/ability.ts index 03670835dbd..199e0af3efb 100644 --- a/src/data/abilities/ability.ts +++ b/src/data/abilities/ability.ts @@ -1184,7 +1184,7 @@ export class PostDefendTypeChangeAbAttr extends PostDefendAbAttr { return i18next.t("abilityTriggers:postDefendTypeChange", { pokemonNameWithAffix: getPokemonNameWithAffix(pokemon), abilityName, - typeName: i18next.t(`pokemonInfo:Type.${PokemonType[this.type]}`), + typeName: i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[this.type])}`), }); } } @@ -1749,7 +1749,7 @@ export class PokemonTypeChangeAbAttr extends PreAttackAbAttr { getTriggerMessage({ pokemon }: AugmentMoveInteractionAbAttrParams, _abilityName: string): string { return i18next.t("abilityTriggers:pokemonTypeChange", { pokemonNameWithAffix: getPokemonNameWithAffix(pokemon), - moveType: i18next.t(`pokemonInfo:Type.${PokemonType[this.moveType]}`), + moveType: i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[this.moveType])}`), }); } } @@ -6222,7 +6222,9 @@ export class TerrainEventTypeChangeAbAttr extends PostSummonAbAttr { if (currentTerrain === TerrainType.NONE) { return i18next.t("abilityTriggers:pokemonTypeChangeRevert", { pokemonNameWithAffix }); } - const moveType = i18next.t(`pokemonInfo:Type.${PokemonType[this.determineTypeChange(pokemon, currentTerrain)[0]]}`); + const moveType = i18next.t( + `pokemonInfo:type.${toCamelCase(PokemonType[this.determineTypeChange(pokemon, currentTerrain)[0]])}`, + ); return i18next.t("abilityTriggers:pokemonTypeChange", { pokemonNameWithAffix, moveType }); } } diff --git a/src/data/balance/pokemon-evolutions.ts b/src/data/balance/pokemon-evolutions.ts index 5d3537f4255..a09c1e38eff 100644 --- a/src/data/balance/pokemon-evolutions.ts +++ b/src/data/balance/pokemon-evolutions.ts @@ -15,6 +15,7 @@ import type { Pokemon } from "#field/pokemon"; import type { SpeciesStatBoosterItem, SpeciesStatBoosterModifierType } from "#modifiers/modifier-type"; import { coerceArray, isNullOrUndefined, randSeedInt } from "#utils/common"; import { getPokemonSpecies } from "#utils/pokemon-utils"; +import { toCamelCase } from "#utils/strings"; import i18next from "i18next"; export enum SpeciesWildEvolutionDelay { @@ -133,11 +134,11 @@ export class SpeciesEvolutionCondition { case EvoCondKey.FRIENDSHIP: return i18next.t("pokemonEvolutions:friendship"); case EvoCondKey.TIME: - return i18next.t(`pokemonEvolutions:timeOfDay.${TimeOfDay[cond.time[cond.time.length - 1]]}`); // For Day and Night evos, the key we want goes last + return i18next.t(`pokemonEvolutions:timeOfDay.${toCamelCase(TimeOfDay[cond.time[cond.time.length - 1]])}`); // For Day and Night evos, the key we want goes last case EvoCondKey.MOVE_TYPE: - return i18next.t("pokemonEvolutions:moveType", {type: i18next.t(`pokemonInfo:Type.${PokemonType[cond.pkmnType]}`)}); + return i18next.t("pokemonEvolutions:moveType", {type: i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[cond.pkmnType])}`)}); case EvoCondKey.PARTY_TYPE: - return i18next.t("pokemonEvolutions:partyType", {type: i18next.t(`pokemonInfo:Type.${PokemonType[cond.pkmnType]}`)}); + return i18next.t("pokemonEvolutions:partyType", {type: i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[cond.pkmnType])}`)}); case EvoCondKey.GENDER: return i18next.t("pokemonEvolutions:gender", {gender: getGenderSymbol(cond.gender)}); case EvoCondKey.MOVE: @@ -156,7 +157,7 @@ export class SpeciesEvolutionCondition { case EvoCondKey.SPECIES_CAUGHT: return i18next.t("pokemonEvolutions:caught", {species: getPokemonSpecies(cond.speciesCaught).name}); case EvoCondKey.HELD_ITEM: - return i18next.t(`pokemonEvolutions:heldItem.${cond.itemKey}`); + return i18next.t(`pokemonEvolutions:heldItem.${toCamelCase(cond.itemKey)}`); } }).filter(s => !isNullOrUndefined(s)); // Filter out stringless conditions return this.desc; @@ -245,7 +246,7 @@ export class SpeciesFormEvolution { } if (this.item) { const itemDescription = i18next.t(`modifierType:EvolutionItem.${EvolutionItem[this.item].toUpperCase()}`); - const rarity = this.item > 50 ? i18next.t("pokemonEvolutions:ULTRA") : i18next.t("pokemonEvolutions:GREAT"); + const rarity = this.item > 50 ? i18next.t("pokemonEvolutions:ultra") : i18next.t("pokemonEvolutions:great"); strings.push(i18next.t("pokemonEvolutions:using", {item: itemDescription, tier: rarity})); } if (this.condition) { diff --git a/src/data/battler-tags.ts b/src/data/battler-tags.ts index 1199ac581a6..5fcc831f447 100644 --- a/src/data/battler-tags.ts +++ b/src/data/battler-tags.ts @@ -50,6 +50,7 @@ import type { } from "#types/battler-tags"; import type { Mutable } from "#types/type-helpers"; import { BooleanHolder, coerceArray, getFrameMs, isNullOrUndefined, NumberHolder, toDmgValue } from "#utils/common"; +import { toCamelCase } from "#utils/strings"; /** * @module @@ -2305,7 +2306,7 @@ export class TypeBoostTag extends SerializableBattlerTag { globalScene.phaseManager.queueMessage( i18next.t("abilityTriggers:typeImmunityPowerBoost", { pokemonNameWithAffix: getPokemonNameWithAffix(pokemon), - typeName: i18next.t(`pokemonInfo:Type.${PokemonType[this.boostedType]}`), + typeName: i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[this.boostedType])}`), }), ); } diff --git a/src/data/challenge.ts b/src/data/challenge.ts index 89435149d2f..34fc338b248 100644 --- a/src/data/challenge.ts +++ b/src/data/challenge.ts @@ -756,7 +756,7 @@ export class SingleTypeChallenge extends Challenge { } getDescription(overrideValue: number = this.value): string { - const type = i18next.t(`pokemonInfo:Type.${PokemonType[overrideValue - 1]}`); + const type = i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[overrideValue - 1])}`); const typeColor = `[color=${TypeColor[PokemonType[overrideValue - 1]]}][shadow=${TypeShadow[PokemonType[this.value - 1]]}]${type}[/shadow][/color]`; const defaultDesc = i18next.t("challenges:singleType.desc_default"); const typeDesc = i18next.t("challenges:singleType.desc", { diff --git a/src/data/moves/move.ts b/src/data/moves/move.ts index 4b8c4f2129b..ffcd844224c 100644 --- a/src/data/moves/move.ts +++ b/src/data/moves/move.ts @@ -6675,7 +6675,7 @@ export class CopyBiomeTypeAttr extends MoveEffectAttr { user.summonData.types = [ typeChange ]; user.updateInfo(); - globalScene.phaseManager.queueMessage(i18next.t("moveTriggers:transformedIntoType", { pokemonName: getPokemonNameWithAffix(user), typeName: i18next.t(`pokemonInfo:Type.${PokemonType[typeChange]}`) })); + globalScene.phaseManager.queueMessage(i18next.t("moveTriggers:transformedIntoType", { pokemonName: getPokemonNameWithAffix(user), typeName: i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[typeChange])}`) })); return true; } @@ -6803,7 +6803,7 @@ export class AddTypeAttr extends MoveEffectAttr { target.summonData.addedType = this.type; target.updateInfo(); - globalScene.phaseManager.queueMessage(i18next.t("moveTriggers:addType", { typeName: i18next.t(`pokemonInfo:Type.${PokemonType[this.type]}`), pokemonName: getPokemonNameWithAffix(target) })); + globalScene.phaseManager.queueMessage(i18next.t("moveTriggers:addType", { typeName: i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[this.type])}`), pokemonName: getPokemonNameWithAffix(target) })); return true; } @@ -6825,7 +6825,7 @@ export class FirstMoveTypeAttr extends MoveEffectAttr { const firstMoveType = target.getMoveset()[0].getMove().type; user.summonData.types = [ firstMoveType ]; - globalScene.phaseManager.queueMessage(i18next.t("battle:transformedIntoType", { pokemonName: getPokemonNameWithAffix(user), type: i18next.t(`pokemonInfo:Type.${PokemonType[firstMoveType]}`) })); + globalScene.phaseManager.queueMessage(i18next.t("battle:transformedIntoType", { pokemonName: getPokemonNameWithAffix(user), type: i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[firstMoveType])}`) })); return true; } diff --git a/src/data/nature.ts b/src/data/nature.ts index b085faebb80..65e401cd288 100644 --- a/src/data/nature.ts +++ b/src/data/nature.ts @@ -3,7 +3,7 @@ import { EFFECTIVE_STATS, getShortenedStatKey, Stat } from "#enums/stat"; import { TextStyle } from "#enums/text-style"; import { UiTheme } from "#enums/ui-theme"; import { getBBCodeFrag } from "#ui/text"; -import { toTitleCase } from "#utils/strings"; +import { toCamelCase } from "#utils/strings"; import i18next from "i18next"; export function getNatureName( @@ -13,7 +13,7 @@ export function getNatureName( ignoreBBCode = false, uiTheme: UiTheme = UiTheme.DEFAULT, ): string { - let ret = toTitleCase(Nature[nature]); + let ret = toCamelCase(Nature[nature]); //Translating nature if (i18next.exists(`nature:${ret}`)) { ret = i18next.t(`nature:${ret}` as any); diff --git a/src/data/pokemon-forms/form-change-triggers.ts b/src/data/pokemon-forms/form-change-triggers.ts index c24466eb5ec..7c042b27058 100644 --- a/src/data/pokemon-forms/form-change-triggers.ts +++ b/src/data/pokemon-forms/form-change-triggers.ts @@ -30,7 +30,7 @@ export abstract class SpeciesFormChangeTrigger { export class SpeciesFormChangeManualTrigger extends SpeciesFormChangeTrigger {} export class SpeciesFormChangeAbilityTrigger extends SpeciesFormChangeTrigger { - public description: string = i18next.t("pokemonEvolutions:Forms.ability"); + public description: string = i18next.t("pokemonEvolutions:forms.ability"); } export class SpeciesFormChangeCompoundTrigger { @@ -69,10 +69,10 @@ export class SpeciesFormChangeItemTrigger extends SpeciesFormChangeTrigger { this.item = item; this.active = active; this.description = this.active - ? i18next.t("pokemonEvolutions:Forms.item", { + ? i18next.t("pokemonEvolutions:forms.item", { item: i18next.t(`modifierType:FormChangeItem.${FormChangeItem[this.item]}`), }) - : i18next.t("pokemonEvolutions:Forms.deactivateItem", { + : i18next.t("pokemonEvolutions:forms.deactivateItem", { item: i18next.t(`modifierType:FormChangeItem.${FormChangeItem[this.item]}`), }); } @@ -97,7 +97,7 @@ export class SpeciesFormChangeTimeOfDayTrigger extends SpeciesFormChangeTrigger constructor(...timesOfDay: TimeOfDay[]) { super(); this.timesOfDay = timesOfDay; - this.description = i18next.t("pokemonEvolutions:Forms.timeOfDay"); + this.description = i18next.t("pokemonEvolutions:orms.timeOfDay"); } canChange(_pokemon: Pokemon): boolean { @@ -111,8 +111,8 @@ export class SpeciesFormChangeActiveTrigger extends SpeciesFormChangeTrigger { super(); this.active = active; this.description = this.active - ? i18next.t("pokemonEvolutions:Forms.enter") - : i18next.t("pokemonEvolutions:Forms.leave"); + ? i18next.t("pokemonEvolutions:forms.enter") + : i18next.t("pokemonEvolutions:forms.leave"); } canChange(pokemon: Pokemon): boolean { @@ -128,7 +128,7 @@ export class SpeciesFormChangeStatusEffectTrigger extends SpeciesFormChangeTrigg super(); this.statusEffects = coerceArray(statusEffects); this.invert = invert; - // this.description = i18next.t("pokemonEvolutions:Forms.statusEffect"); + // this.description = i18next.t("pokemonEvolutions:forms.statusEffect"); } canChange(pokemon: Pokemon): boolean { @@ -146,10 +146,10 @@ export class SpeciesFormChangeMoveLearnedTrigger extends SpeciesFormChangeTrigge this.known = known; const moveKey = toCamelCase(MoveId[this.move]); this.description = known - ? i18next.t("pokemonEvolutions:Forms.moveLearned", { + ? i18next.t("pokemonEvolutions:forms.moveLearned", { move: i18next.t(`move:${moveKey}.name`), }) - : i18next.t("pokemonEvolutions:Forms.moveForgotten", { + : i18next.t("pokemonEvolutions:forms.moveForgotten", { move: i18next.t(`move:${moveKey}.name`), }); } @@ -171,7 +171,7 @@ export abstract class SpeciesFormChangeMoveTrigger extends SpeciesFormChangeTrig } export class SpeciesFormChangePreMoveTrigger extends SpeciesFormChangeMoveTrigger { - description = i18next.t("pokemonEvolutions:Forms.preMove"); + description = i18next.t("pokemonEvolutions:forms.preMove"); canChange(pokemon: Pokemon): boolean { const command = globalScene.currentBattle.turnCommands[pokemon.getBattlerIndex()]; return !!command?.move && this.movePredicate(command.move.move) === this.used; @@ -179,7 +179,7 @@ export class SpeciesFormChangePreMoveTrigger extends SpeciesFormChangeMoveTrigge } export class SpeciesFormChangePostMoveTrigger extends SpeciesFormChangeMoveTrigger { - description = i18next.t("pokemonEvolutions:Forms.postMove"); + description = i18next.t("pokemonEvolutions:forms.postMove"); canChange(pokemon: Pokemon): boolean { return ( pokemon.summonData && !!pokemon.getLastXMoves(1).filter(m => this.movePredicate(m.move)).length === this.used @@ -244,7 +244,7 @@ export class SpeciesFormChangeWeatherTrigger extends SpeciesFormChangeTrigger { super(); this.ability = ability; this.weathers = weathers; - this.description = i18next.t("pokemonEvolutions:Forms.weather"); + this.description = i18next.t("pokemonEvolutions:forms.weather"); } /** @@ -282,7 +282,7 @@ export class SpeciesFormChangeRevertWeatherFormTrigger extends SpeciesFormChange super(); this.ability = ability; this.weathers = weathers; - this.description = i18next.t("pokemonEvolutions:Forms.weatherRevert"); + this.description = i18next.t("pokemonEvolutions:forms.weatherRevert"); } /** diff --git a/src/data/pokemon-species.ts b/src/data/pokemon-species.ts index 7bfe02d9086..064ad57cfb3 100644 --- a/src/data/pokemon-species.ts +++ b/src/data/pokemon-species.ts @@ -778,7 +778,7 @@ export class PokemonSpecies extends PokemonSpeciesForm implements Localizable { } if (key) { - return i18next.t(`battlePokemonForm:${key}`, { + return i18next.t(`battlePokemonForm:${toCamelCase(key)}`, { pokemonName: this.name, }); } @@ -810,7 +810,9 @@ export class PokemonSpecies extends PokemonSpeciesForm implements Localizable { return this.name; // Other special cases could be put here too } // Everything beyond this point essentially follows the pattern of FORMNAME_SPECIES - return i18next.t(`pokemonForm:appendForm.${SpeciesId[this.speciesId].split("_")[0]}`, { pokemonName: this.name }); + return i18next.t(`pokemonForm:appendForm.${toCamelCase(SpeciesId[this.speciesId].split("_")[0])}`, { + pokemonName: this.name, + }); } /** @@ -827,7 +829,7 @@ export class PokemonSpecies extends PokemonSpeciesForm implements Localizable { const region = this.getRegion(); if (this.speciesId === SpeciesId.ARCEUS) { - ret = i18next.t(`pokemonInfo:Type.${formText.toUpperCase()}`); + ret = i18next.t(`pokemonInfo:type.${toCamelCase(formText)}`); } else if ( [ SpeciesFormKey.MEGA, @@ -841,8 +843,8 @@ export class PokemonSpecies extends PokemonSpeciesForm implements Localizable { ].includes(formKey as SpeciesFormKey) ) { return append - ? i18next.t(`battlePokemonForm:${formKey}`, { pokemonName: this.name }) - : i18next.t(`pokemonForm:battleForm.${formKey}`); + ? i18next.t(`battlePokemonForm:${toCamelCase(formKey)}`, { pokemonName: this.name }) + : i18next.t(`pokemonForm:battleForm.${toCamelCase(formKey)}`); } else if ( region === Region.NORMAL || (this.speciesId === SpeciesId.GALAR_DARMANITAN && formIndex > 0) || @@ -868,10 +870,10 @@ export class PokemonSpecies extends PokemonSpeciesForm implements Localizable { return i18next.t("pokemonForm:ursalunaBloodmoon"); } else { // Only regional forms should be left at this point - return i18next.t(`pokemonForm:regionalForm.${Region[region]}`); + return i18next.t(`pokemonForm:regionalForm.${toCamelCase(Region[region])}`); } return append - ? i18next.t("pokemonForm:appendForm.GENERIC", { + ? i18next.t("pokemonForm:appendForm.generic", { pokemonName: this.name, formName: ret, }) @@ -879,8 +881,8 @@ export class PokemonSpecies extends PokemonSpeciesForm implements Localizable { } localize(): void { - this.name = i18next.t(`pokemon:${SpeciesId[this.speciesId].toLowerCase()}`); - this.category = i18next.t(`pokemonCategory:${SpeciesId[this.speciesId].toLowerCase()}_category`); + this.name = i18next.t(`pokemon:${toCamelCase(SpeciesId[this.speciesId])}`); + this.category = i18next.t(`pokemonCategory:${toCamelCase(SpeciesId[this.speciesId])}Category`); } getWildSpeciesForLevel(level: number, allowEvolving: boolean, isBoss: boolean, gameMode: GameMode): SpeciesId { diff --git a/src/enums/stat.ts b/src/enums/stat.ts index a2b81b7e64b..72ccc065850 100644 --- a/src/enums/stat.ts +++ b/src/enums/stat.ts @@ -64,7 +64,7 @@ export function getStatStageChangeDescriptionKey(stages: number, isIncrease: boo * @returns the translation key corresponding to the given {@linkcode Stat} */ export function getStatKey(stat: Stat) { - return `pokemonInfo:Stat.${Stat[stat]}`; + return `pokemonInfo:stat.${Stat[stat].toLowerCase()}`; } /** @@ -73,5 +73,5 @@ export function getStatKey(stat: Stat) { * @returns the translation key corresponding to the given {@linkcode Stat} */ export function getShortenedStatKey(stat: PermanentStat) { - return `pokemonInfo:Stat.${Stat[stat]}shortened`; + return `pokemonInfo:stat.${Stat[stat].toLowerCase()}Shortened`; } diff --git a/src/modifier/modifier-type.ts b/src/modifier/modifier-type.ts index aca49313ff5..8b77900cb62 100644 --- a/src/modifier/modifier-type.ts +++ b/src/modifier/modifier-type.ts @@ -130,6 +130,7 @@ import { } from "#utils/common"; import { getEnumKeys, getEnumValues } from "#utils/enums"; import { getModifierPoolForType, getModifierType } from "#utils/modifier-utils"; +import { toCamelCase } from "#utils/strings"; import i18next from "i18next"; const outputModifierData = false; @@ -451,13 +452,13 @@ export class TerastallizeModifierType extends PokemonModifierType { get name(): string { return i18next.t("modifierType:ModifierType.TerastallizeModifierType.name", { - teraType: i18next.t(`pokemonInfo:Type.${PokemonType[this.teraType]}`), + teraType: i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[this.teraType])}`), }); } getDescription(): string { return i18next.t("modifierType:ModifierType.TerastallizeModifierType.description", { - teraType: i18next.t(`pokemonInfo:Type.${PokemonType[this.teraType]}`), + teraType: i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[this.teraType])}`), }); } @@ -861,7 +862,7 @@ export class AttackTypeBoosterModifierType getDescription(): string { // TODO: Need getTypeName? return i18next.t("modifierType:ModifierType.AttackTypeBoosterModifierType.description", { - moveType: i18next.t(`pokemonInfo:Type.${PokemonType[this.moveType]}`), + moveType: i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[this.moveType])}`), }); } diff --git a/src/phases/tera-phase.ts b/src/phases/tera-phase.ts index 84b05d88abe..5e42fab82ba 100644 --- a/src/phases/tera-phase.ts +++ b/src/phases/tera-phase.ts @@ -7,6 +7,7 @@ import { PokemonType } from "#enums/pokemon-type"; import type { Pokemon } from "#field/pokemon"; import { BattlePhase } from "#phases/battle-phase"; import { achvs } from "#system/achv"; +import { toCamelCase } from "#utils/strings"; import i18next from "i18next"; export class TeraPhase extends BattlePhase { @@ -25,7 +26,7 @@ export class TeraPhase extends BattlePhase { globalScene.phaseManager.queueMessage( i18next.t("battle:pokemonTerastallized", { pokemonNameWithAffix: getPokemonNameWithAffix(this.pokemon), - type: i18next.t(`pokemonInfo:Type.${PokemonType[this.pokemon.getTeraType()]}`), + type: i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[this.pokemon.getTeraType()])}`), }), ); new CommonBattleAnim(CommonAnim.TERASTALLIZE, this.pokemon).play(false, () => { diff --git a/src/system/achv.ts b/src/system/achv.ts index 45718a3690f..f51e5ea459c 100644 --- a/src/system/achv.ts +++ b/src/system/achv.ts @@ -15,6 +15,7 @@ import { TurnHeldItemTransferModifier } from "#modifiers/modifier"; import type { ConditionFn } from "#types/common"; import { isNuzlockeChallenge } from "#utils/challenge-utils"; import { NumberHolder } from "#utils/common"; +import { toCamelCase } from "#utils/strings"; import i18next from "i18next"; import type { Modifier } from "typescript"; @@ -436,8 +437,7 @@ export function getAchievementDescription(localizationKey: string): string { case "monoFairy": return i18next.t("achv:monoType.description", { context: genderStr, - // Todo: Remove the `toUpperCase()` again after changing the `pokemonInfo.json` locales - type: i18next.t(`pokemonInfo:Type.${localizationKey.slice(4).toUpperCase()}`), + type: i18next.t(`pokemonInfo:type.${toCamelCase(localizationKey.slice(4))}`), }); case "freshStart": return i18next.t("achv:freshStart.description", { context: genderStr }); diff --git a/src/ui/base-stats-overlay.ts b/src/ui/base-stats-overlay.ts index 3b432e13096..b3cccf34298 100644 --- a/src/ui/base-stats-overlay.ts +++ b/src/ui/base-stats-overlay.ts @@ -4,6 +4,7 @@ import { TextStyle } from "#enums/text-style"; import { addTextObject } from "#ui/text"; import { addWindow } from "#ui/ui-theme"; import { fixedInt } from "#utils/common"; +import { toCamelCase } from "#utils/strings"; import i18next from "i18next"; interface BaseStatsOverlaySettings { @@ -68,7 +69,9 @@ export class BaseStatsOverlay extends Phaser.GameObjects.Container implements In // show this component with infos for the specific move show(values: number[], total: number): boolean { for (let i = 0; i < 6; i++) { - this.statsLabels[i].setText(i18next.t(`pokemonInfo:Stat.${shortStats[i]}shortened`) + ": " + `${values[i]}`); + this.statsLabels[i].setText( + i18next.t(`pokemonInfo:stat.${toCamelCase(shortStats[i])}Shortened`) + ": " + `${values[i]}`, + ); // This accounts for base stats up to 200, might not be enough. // TODO: change color based on value. this.statsShadows[i].setSize(values[i] / 2, 5); diff --git a/src/ui/battle-info/battle-info.ts b/src/ui/battle-info/battle-info.ts index 0aedfbdf5e7..810d0c7c328 100644 --- a/src/ui/battle-info/battle-info.ts +++ b/src/ui/battle-info/battle-info.ts @@ -9,6 +9,7 @@ import type { Pokemon } from "#field/pokemon"; import { getVariantTint } from "#sprites/variant"; import { addTextObject } from "#ui/text"; import { fixedInt, getLocalizedSpriteKey, getShinyDescriptor } from "#utils/common"; +import { toCamelCase } from "#utils/strings"; import i18next from "i18next"; /** @@ -361,7 +362,7 @@ export abstract class BattleInfo extends Phaser.GameObjects.Container { globalScene.ui.showTooltip( "", i18next.t("fightUiHandler:teraHover", { - type: i18next.t(`pokemonInfo:Type.${PokemonType[this.lastTeraType]}`), + type: i18next.t(`pokemonInfo:type.${toCamelCase(PokemonType[this.lastTeraType])}`), }), ); } diff --git a/src/ui/confirm-ui-handler.ts b/src/ui/confirm-ui-handler.ts index 49e88556f1b..529d1bd8bbb 100644 --- a/src/ui/confirm-ui-handler.ts +++ b/src/ui/confirm-ui-handler.ts @@ -31,14 +31,14 @@ export class ConfirmUiHandler extends AbstractOptionSelectUiHandler { const config: OptionSelectConfig = { options: [ { - label: i18next.t("partyUiHandler:SUMMARY"), + label: i18next.t("partyUiHandler:summary"), handler: () => { args[0](); return true; }, }, { - label: i18next.t("partyUiHandler:POKEDEX"), + label: i18next.t("partyUiHandler:pokedex"), handler: () => { args[1](); return true; diff --git a/src/ui/party-ui-handler.ts b/src/ui/party-ui-handler.ts index 3101f46f098..6ca134ebd75 100644 --- a/src/ui/party-ui-handler.ts +++ b/src/ui/party-ui-handler.ts @@ -27,7 +27,7 @@ import { addBBCodeTextObject, addTextObject, getTextColor } from "#ui/text"; import { addWindow } from "#ui/ui-theme"; import { applyChallenges } from "#utils/challenge-utils"; import { BooleanHolder, getLocalizedSpriteKey, randInt } from "#utils/common"; -import { toTitleCase } from "#utils/strings"; +import { toCamelCase, toTitleCase } from "#utils/strings"; import i18next from "i18next"; import type BBCodeText from "phaser3-rex-plugins/plugins/bbcodetext"; @@ -1573,12 +1573,12 @@ export class PartyUiHandler extends MessageUiHandler { const formChangeItemModifiers = this.getFormChangeItemsModifiers(pokemon); if (formChangeItemModifiers && option >= PartyOption.FORM_CHANGE_ITEM) { const modifier = formChangeItemModifiers[option - PartyOption.FORM_CHANGE_ITEM]; - optionName = `${modifier.active ? i18next.t("partyUiHandler:DEACTIVATE") : i18next.t("partyUiHandler:ACTIVATE")} ${modifier.type.name}`; + optionName = `${modifier.active ? i18next.t("partyUiHandler:deactivate") : i18next.t("partyUiHandler:activate")} ${modifier.type.name}`; } else if (option === PartyOption.UNPAUSE_EVOLUTION) { - optionName = `${pokemon.pauseEvolutions ? i18next.t("partyUiHandler:UNPAUSE_EVOLUTION") : i18next.t("partyUiHandler:PAUSE_EVOLUTION")}`; + optionName = `${pokemon.pauseEvolutions ? i18next.t("partyUiHandler:unpausedEvolution") : i18next.t("partyUiHandler:pauseEvolution")}`; } else { if (this.localizedOptions.includes(option)) { - optionName = i18next.t(`partyUiHandler:${PartyOption[option]}`); + optionName = i18next.t(`partyUiHandler:${toCamelCase(PartyOption[option])}`); } else { optionName = toTitleCase(PartyOption[option]); } @@ -1595,7 +1595,7 @@ export class PartyUiHandler extends MessageUiHandler { .getLevelMoves() .find(plm => plm[1] === move); } else if (option === PartyOption.ALL) { - optionName = i18next.t("partyUiHandler:ALL"); + optionName = i18next.t("partyUiHandler:all"); } else { const itemModifiers = this.getItemModifiers(pokemon); const itemModifier = itemModifiers[option]; @@ -2190,7 +2190,7 @@ class PartyDiscardModeButton extends Phaser.GameObjects.Container { setup(party: PartyUiHandler) { this.transferIcon = globalScene.add.sprite(0, 0, "party_transfer"); this.discardIcon = globalScene.add.sprite(0, 0, "party_discard"); - this.textBox = addTextObject(-8, -7, i18next.t("partyUiHandler:TRANSFER"), TextStyle.PARTY); + this.textBox = addTextObject(-8, -7, i18next.t("partyUiHandler:transfer"), TextStyle.PARTY); this.party = party; this.add(this.transferIcon); @@ -2238,14 +2238,14 @@ class PartyDiscardModeButton extends Phaser.GameObjects.Container { this.transferIcon.setVisible(true); this.discardIcon.setVisible(false); this.textBox.setVisible(true); - this.textBox.setText(i18next.t("partyUiHandler:TRANSFER")); + this.textBox.setText(i18next.t("partyUiHandler:transfer")); this.transferIcon.displayWidth = this.textBox.text.length * 9 + 3; break; case PartyUiMode.DISCARD: this.transferIcon.setVisible(false); this.discardIcon.setVisible(true); this.textBox.setVisible(true); - this.textBox.setText(i18next.t("partyUiHandler:DISCARD")); + this.textBox.setText(i18next.t("partyUiHandler:discard")); this.discardIcon.displayWidth = this.textBox.text.length * 9 + 3; break; } diff --git a/src/ui/run-info-ui-handler.ts b/src/ui/run-info-ui-handler.ts index db0790275fc..a5e21a3a0a1 100644 --- a/src/ui/run-info-ui-handler.ts +++ b/src/ui/run-info-ui-handler.ts @@ -700,7 +700,11 @@ export class RunInfoUiHandler extends UiHandler { const typeTextColor = `[color=${TypeColor[typeRule]}]`; const typeShadowColor = `[shadow=${TypeShadow[typeRule]}]`; const typeText = - typeTextColor + typeShadowColor + i18next.t(`pokemonInfo:Type.${typeRule}`)! + "[/color]" + "[/shadow]"; + typeTextColor + + typeShadowColor + + i18next.t(`pokemonInfo:type.${toCamelCase(typeRule)}`)! + + "[/color]" + + "[/shadow]"; rules.push(typeText); break; } @@ -794,15 +798,15 @@ export class RunInfoUiHandler extends UiHandler { pStats[i] = isMult < 1 ? pStats[i] + "[color=#40c8f8]↓[/color]" : pStats[i]; pStats[i] = isMult > 1 ? pStats[i] + "[color=#f89890]↑[/color]" : pStats[i]; } - const hp = i18next.t("pokemonInfo:Stat.HPshortened") + ": " + pStats[0]; - const atk = i18next.t("pokemonInfo:Stat.ATKshortened") + ": " + pStats[1]; - const def = i18next.t("pokemonInfo:Stat.DEFshortened") + ": " + pStats[2]; - const spatk = i18next.t("pokemonInfo:Stat.SPATKshortened") + ": " + pStats[3]; - const spdef = i18next.t("pokemonInfo:Stat.SPDEFshortened") + ": " + pStats[4]; + const hp = i18next.t("pokemonInfo:stat.hpShortened") + ": " + pStats[0]; + const atk = i18next.t("pokemonInfo:stat.atkShortened") + ": " + pStats[1]; + const def = i18next.t("pokemonInfo:stat.defShortened") + ": " + pStats[2]; + const spatk = i18next.t("pokemonInfo:stat.spatkShortened") + ": " + pStats[3]; + const spdef = i18next.t("pokemonInfo:stat.spdefShortened") + ": " + pStats[4]; const speedLabel = currentLanguage === "es-ES" || currentLanguage === "pt_BR" ? i18next.t("runHistory:SPDshortened") - : i18next.t("pokemonInfo:Stat.SPDshortened"); + : i18next.t("pokemonInfo:stat.spdShortened"); const speed = speedLabel + ": " + pStats[5]; // Column 1: HP Atk Def const pokeStatText1 = addBBCodeTextObject(-5, 0, hp, TextStyle.SUMMARY, { diff --git a/src/ui/summary-ui-handler.ts b/src/ui/summary-ui-handler.ts index b6ce0a706f8..01d9b981563 100644 --- a/src/ui/summary-ui-handler.ts +++ b/src/ui/summary-ui-handler.ts @@ -37,7 +37,7 @@ import { rgbHexToRgba, } from "#utils/common"; import { getEnumValues } from "#utils/enums"; -import { toTitleCase } from "#utils/strings"; +import { toCamelCase, toTitleCase } from "#utils/strings"; import { argbFromRgba } from "@material/material-color-utilities"; import i18next from "i18next"; @@ -962,7 +962,7 @@ export class SummaryUiHandler extends UiHandler { this.passiveContainer?.descriptionText?.setVisible(false); const closeFragment = getBBCodeFrag("", TextStyle.WINDOW_ALT); - const rawNature = toTitleCase(Nature[this.pokemon?.getNature()!]); // TODO: is this bang correct? + const rawNature = toCamelCase(Nature[this.pokemon?.getNature()!]); // TODO: is this bang correct? const nature = `${getBBCodeFrag(toTitleCase(getNatureName(this.pokemon?.getNature()!)), TextStyle.SUMMARY_RED)}${closeFragment}`; // TODO: is this bang correct? const memoString = i18next.t("pokemonSummary:memoString", { From 432f505f65ede157191acacd607a2848d5695d26 Mon Sep 17 00:00:00 2001 From: Bertie690 <136088738+Bertie690@users.noreply.github.com> Date: Sun, 17 Aug 2025 16:26:20 -0400 Subject: [PATCH 07/11] [Dev] Added `devcontainer.json` and VS code config files (#6190) * [Dev] Added `devcontainer.json` and VS code config files * Update settings.json * Removed "don't lint vscode json files" setting from `biome.jsonc` * Update settings.json * Update extensions.json Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com> * Update settings.json Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com> * Update settings.json Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com> * Update settings.json * Re-add `.vscode/` to Biome ignore list * Update settings.json Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com> * Update .devcontainer/devcontainer.json Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com> * Removed non-`extensions.json` files; added default config directly to devcontainer * Added mention of alternate dev setup to `CONTRIBUTING.md` * Update CONTRIBUTING.md Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com> --------- Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com> --- .devcontainer/devcontainer.json | 61 +++++++++++++++++++++++++++++++++ .gitignore | 5 +-- .ls-lint.yml | 1 + .vscode/extensions.json | 13 +++++++ CONTRIBUTING.md | 43 ++++++++++++++++------- biome.jsonc | 1 - 6 files changed, 108 insertions(+), 16 deletions(-) create mode 100644 .devcontainer/devcontainer.json create mode 100644 .vscode/extensions.json diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json new file mode 100644 index 00000000000..e94afd0a9be --- /dev/null +++ b/.devcontainer/devcontainer.json @@ -0,0 +1,61 @@ +// For format details, see https://aka.ms/devcontainer.json. For config options, see the +// README at: https://github.com/devcontainers/templates/tree/main/src/typescript-node +{ + "name": "Node.js & TypeScript", + // Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile + "image": "mcr.microsoft.com/devcontainers/typescript-node:1-22-bookworm", + "features": { + "ghcr.io/devcontainers/features/github-cli:1": { + "installDirectlyFromGitHubRelease": true, + "version": "latest" + }, + "ghcr.io/devcontainers-extra/features/pnpm:2": { + "version": "latest" + } + }, + "customizations": { + "vscode": { + "settings": { + // # Formatter configs + "editor.defaultFormatter": "biomejs.biome", + "editor.tabSize": 2, + "editor.insertSpaces": true, + "editor.codeActionsOnSave": { + "source.addMissingImports.ts": "always", + "source.removeUnusedImports": "always", + "source.fixAll.biome": "always", + "source.organizeImports.biome": "always" + }, + "biome.suggestInstallingGlobally": false, + + // # JS/TS setting overrides + "javascript.preferences.importModuleSpecifier": "non-relative", + "javascript.preferences.importModuleSpecifierEnding": "index", + "javascript.preferGoToSourceDefinition": true, + "javascript.updateImportsOnFileMove.enabled": "always", + + "typescript.preferences.importModuleSpecifier": "non-relative", + "typescript.preferences.importModuleSpecifierEnding": "index", + "typescript.preferGoToSourceDefinition": true, + "typescript.updateImportsOnFileMove.enabled": "always", + + "typescript.tsserver.experimental.enableProjectDiagnostics": true, + + // # Miscellaneous + "npm.packageManager": "pnpm", + "npm.scriptRunner": "pnpm", + "vitest.cliArguments": "--no-isolate" + }, + "extensions": [ + "biomejs.biome", + "YoavBls.pretty-ts-errors", + "vitest.explorer", + "adpyke.codesnap", // Bind to a hotkey (ctrl+\, etc) for best results + "aaron-bond.better-comments", + "MuTsunTsai.jsdoc-link" + ] + } + }, + "postCreateCommand": "pnpm install", + "forwardPorts": [8000] +} diff --git a/.gitignore b/.gitignore index 00df0002e01..299767e742a 100644 --- a/.gitignore +++ b/.gitignore @@ -12,9 +12,10 @@ dist dist-ssr *.local -# Editor directories and files -.vscode +# Editor directories and files (excluding `extensions.json` for devcontainer) *.code-workspace +.vscode/* +!.vscode/extensions.json .idea .DS_Store *.suo diff --git a/.ls-lint.yml b/.ls-lint.yml index 22f08f72938..0086367367b 100644 --- a/.ls-lint.yml +++ b/.ls-lint.yml @@ -26,3 +26,4 @@ ignore: - .git - public - dist + - .devcontainer diff --git a/.vscode/extensions.json b/.vscode/extensions.json new file mode 100644 index 00000000000..81abc8df2c0 --- /dev/null +++ b/.vscode/extensions.json @@ -0,0 +1,13 @@ +{ + "recommendations": [ + "biomejs.biome", + "YoavBls.pretty-ts-errors", + "vitest.explorer", + + // This stuff isn't mandatory - it's just nice to have :) + + "adpyke.codesnap", // Bind to a hotkey (ctrl+\, etc) for best results + "aaron-bond.better-comments", + "MuTsunTsai.jsdoc-link" + ] +} \ No newline at end of file diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 0217ebd28a6..04ab7ff4faa 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -2,7 +2,7 @@ Thank you for taking the time to contribute, every little bit helps. This project is entirely open-source and unmonetized - community contributions are what keep it alive! -Please make sure you understand everything relevant to your changes from the [Table of Contents](#-table-of-contents), and absolutely *feel free to reach out in the **#dev-corner** channel on [Discord](https://discord.gg/pokerogue)*. +Please make sure you understand everything relevant to your changes from the [Table of Contents](#-table-of-contents), and absolutely *feel free to reach out in the **#dev-corner** channel on [Discord](https://discord.gg/pokerogue)*. We are here to help and the better you understand what you're working on, the easier it will be for it to find its way into the game. ## 📄 Table of Contents @@ -16,19 +16,36 @@ We are here to help and the better you understand what you're working on, the ea ## 🛠️ Development Basics -PokéRogue is built with [Typescript](https://www.typescriptlang.org/docs/handbook/intro.html), using the [Phaser](https://github.com/phaserjs/phaser) game framework. +PokéRogue is built with [Typescript](https://www.typescriptlang.org/docs/handbook/intro.html), using the [Phaser](https://github.com/phaserjs/phaser) game framework. -If you have the motivation and experience with Typescript/Javascript (or are willing to learn) you can contribute by forking the repository and making pull requests with contributions. +If you have the motivation and experience with Typescript/Javascript (or are willing to learn), you can contribute by forking the repository and making pull requests with contributions. ## 💻 Environment Setup -### Prerequisites +### Codespaces/Devcontainer Environment -- node: >=22.14.0 - [manage with pnpm](https://pnpm.io/cli/env) | [manage with fnm](https://github.com/Schniz/fnm) | [manage with nvm](https://github.com/nvm-sh/nvm) +Arguably the easiest way to get started is by using the prepared development environment. + +We have a `.devcontainer/devcontainer.json` file, meaning we are compatible with: + +- [![Open in GitHub Codespaces][codespaces-badge]][codespaces-link], or +- the [Visual Studio Code Remote - Containers][devcontainer-ext] extension. + +This Linux environment comes with all required dependencies needed to start working on the project. + +[codespaces-badge]: +[codespaces-link]: +[devcontainer-ext]: + +### Local Development + +#### Prerequisites + +- node: >=22.14.0 - [manage with pnpm](https://pnpm.io/cli/env) | [manage with fnm](https://github.com/Schniz/fnm) | [manage with nvm](https://github.com/nvm-sh/nvm) | [manage with volta.sh](https://volta.sh/) - pnpm: 10.x - [how to install](https://pnpm.io/installation) (not recommended to install via `npm` on Windows native) | [alternate method - volta.sh](https://volta.sh/) - The repository [forked](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/fork-a-repo) and [cloned](https://docs.github.com/en/repositories/creating-and-managing-repositories/cloning-a-repository) locally on your device -### Running Locally +#### Running Locally 1. Run `pnpm install` from the repository root - *if you run into any errors, reach out in the **#dev-corner** channel on Discord* @@ -36,7 +53,7 @@ If you have the motivation and experience with Typescript/Javascript (or are wil ## 🚀 Getting Started -A great way to develop an understanding of how the project works is to look at test cases (located in [the `test` folder](./test/)). +A great way to develop an understanding of how the project works is to look at test cases (located in [the `test` folder](./test/)). Tests show you both how things are supposed to work and the expected "flow" to get from point A to point B in battles. *This is a big project and you will be confused at times - never be afraid to reach out and ask questions in **#dev-corner***! @@ -50,7 +67,7 @@ Most issues are bugs and are labeled with their area, such as `Move`, `Ability`, - `P2`: Minor - Incorrect (but non-crashing) move/ability/interaction - `P3`: No gameplay impact - typo, minor graphical error, etc. -Also under issues, you can take a look at the [List of Partial / Unimplemented Moves and Abilities](https://github.com/pagefaultgames/pokerogue/issues/3503) and the [Bug Board](https://github.com/orgs/pagefaultgames/projects/3) (the latter is essentially the same as the issues page but easier to work with). +Also under issues, you can take a look at the [List of Partial / Unimplemented Moves and Abilities](https://github.com/pagefaultgames/pokerogue/issues/3503) and the [Bug Board](https://github.com/orgs/pagefaultgames/projects/3). The latter is essentially the same as the issues page, so take your pick. You are free to comment on any issue so that you may be assigned to it and we can avoid multiple people working on the same thing. @@ -58,7 +75,7 @@ You are free to comment on any issue so that you may be assigned to it and we ca You can find the auto-generated documentation [here](https://pagefaultgames.github.io/pokerogue/main/index.html). -Additionally, the [docs folder](./docs) contains a variety of in-depth documents and guides useful for aspiring contributors. +Additionally, the [docs folder](./docs) contains a variety of in-depth documents and guides useful for aspiring contributors. \ Notable topics include: - [Commenting your code](./docs/comments.md) - [Linting & Formatting](./docs/linting.md) @@ -86,17 +103,17 @@ const overrides = { ``` Read through `src/overrides.ts` file to find the override that fits your needs - there are a lot of them! -If the situation you're trying to test can't be created using existing overrides (or with the [Dev Save](#-development-save-file)), reach out in **#dev-corner**. +If the situation you're trying to test can't be created using existing overrides (or with the [Dev Save](#-development-save-file)), reach out in **#dev-corner**. You can get help testing your specific changes, and you might have found a new override that needs to be created! ### 2 - Automatic Testing > PokéRogue uses [Vitest](https://vitest.dev/) for automatic testing. Checking out the existing tests in the [test](./test/) folder is a great way to understand how this works, and to get familiar with the project as a whole. -To make sure your changes didn't break any existing test cases, run `pnpm test:silent` in your terminal. You can also provide an argument to the command: to run only the Dancer (ability) tests, you could write `pnpm test:silent dancer`. +To make sure your changes didn't break any existing test cases, run `pnpm test:silent` in your terminal. You can also provide an argument to the command: to run only the Dancer (ability) tests, you could write `pnpm test:silent dancer`. - __Note that passing all test cases does *not* guarantee that everything is working properly__. The project does not have complete regression testing. -Most non-trivial changes (*especially bug fixes*) should come along with new test cases. +Most non-trivial changes (*especially bug fixes*) should come along with new test cases. - To make a new test file, run `pnpm test:create` and follow the prompts. If the move/ability/etc. you're modifying already has tests, simply add new cases to the end of the file. As mentioned before, the easiest way to get familiar with the system and understand how to write your own tests is simply to read the existing tests, particularly ones similar to the tests you intend to write. - Ensure that new tests: - Are deterministic. In other words, the test should never pass or fail when it shouldn't due to randomness. This involves primarily ensuring that abilities and moves are never randomly selected. @@ -107,4 +124,4 @@ Most non-trivial changes (*especially bug fixes*) should come along with new tes > Some issues may require you to have unlocks on your save file which go beyond normal overrides. For this reason, the repository contains a [save file](../test/test-utils/saves/everything.psrv) with _everything_ unlocked (even ones not legitimately obtainable, like unimplemented variant shinies). 1. Start the game up locally and navigate to `Menu -> Manage Data -> Import Data` -2. Select [everything.prsv](test/test-utils/saves/everything.prsv) (`test/test-utils/saves/everything.prsv`) and confirm. +2. Select [everything.prsv](test/test-utils/saves/everything.prsv) (`test/test-utils/saves/everything.prsv`) and confirm. \ No newline at end of file diff --git a/biome.jsonc b/biome.jsonc index d2f7c711dc9..a63ce0ee07d 100644 --- a/biome.jsonc +++ b/biome.jsonc @@ -36,7 +36,6 @@ "!**/src/data/balance/tms.ts" ] }, - "assist": { "actions": { "source": { From bf9f0880b6e641619856e591954036a71727d8f6 Mon Sep 17 00:00:00 2001 From: G Sai Nikhilesh <134734453+Nikhilesh002@users.noreply.github.com> Date: Mon, 18 Aug 2025 02:32:29 +0530 Subject: [PATCH 08/11] [UI/UX] Add Username to Stats Screen (#6270) * [Feature] Add Username to Stats Screen * [Feature] username fallback to "Guest" * [UI/UX] Update display name fallback to use translation for guest user * Update locales submodule * [Fix] Username updates without refresh * Update locales submodule --------- Co-authored-by: Wlowscha <54003515+Wlowscha@users.noreply.github.com> Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com> --- public/locales | 2 +- src/ui/game-stats-ui-handler.ts | 30 ++++++++++++++++++++++++++++-- 2 files changed, 29 insertions(+), 3 deletions(-) diff --git a/public/locales b/public/locales index 38d7c1baa23..7fa231e7239 160000 --- a/public/locales +++ b/public/locales @@ -1 +1 @@ -Subproject commit 38d7c1baa2367582770d62b3f4b0239874c1c7e5 +Subproject commit 7fa231e7239ed23e17a026670c007c97c3cd9e4a diff --git a/src/ui/game-stats-ui-handler.ts b/src/ui/game-stats-ui-handler.ts index ed66230bed7..d2a9779f515 100644 --- a/src/ui/game-stats-ui-handler.ts +++ b/src/ui/game-stats-ui-handler.ts @@ -1,7 +1,9 @@ +import { loggedInUser } from "#app/account"; import { globalScene } from "#app/global-scene"; import { speciesStarterCosts } from "#balance/starters"; import { Button } from "#enums/buttons"; import { DexAttr } from "#enums/dex-attr"; +import { PlayerGender } from "#enums/player-gender"; import { TextStyle } from "#enums/text-style"; import { UiTheme } from "#enums/ui-theme"; import type { GameData } from "#system/game-data"; @@ -227,6 +229,9 @@ export class GameStatsUiHandler extends UiHandler { private arrowUp: Phaser.GameObjects.Sprite; private arrowDown: Phaser.GameObjects.Sprite; + /** Logged in username */ + private headerText: Phaser.GameObjects.Text; + /** Whether the UI is single column mode */ private get singleCol(): boolean { const resolvedLang = i18next.resolvedLanguage ?? "en"; @@ -296,6 +301,23 @@ export class GameStatsUiHandler extends UiHandler { return GameStatsUiHandler.ROWS_PER_PAGE * this.columnCount; } + /** + * Returns the username of logged in user. If the username is hidden, the trainer name based on gender will be displayed. + * @returns The username of logged in user + */ + private getUsername(): string { + const usernameReplacement = + globalScene.gameData.gender === PlayerGender.FEMALE + ? i18next.t("trainerNames:player_f") + : i18next.t("trainerNames:player_m"); + + const displayName = !globalScene.hideUsername + ? (loggedInUser?.username ?? i18next.t("common:guest")) + : usernameReplacement; + + return i18next.t("gameStatsUiHandler:stats", { username: displayName }); + } + // #endregion Columnar-specific properties setup() { @@ -316,11 +338,11 @@ export class GameStatsUiHandler extends UiHandler { const headerBg = addWindow(0, 0, sWidth - 2, 24).setOrigin(0); - const headerText = addTextObject(0, 0, i18next.t("gameStatsUiHandler:stats"), TextStyle.HEADER_LABEL) + this.headerText = addTextObject(0, 0, this.getUsername(), TextStyle.HEADER_LABEL) .setOrigin(0) .setPositionRelative(headerBg, 8, 4); - this.gameStatsContainer.add([headerBg, headerText]); + this.gameStatsContainer.add([headerBg, this.headerText]); const colWidth = this.colWidth; @@ -368,6 +390,10 @@ export class GameStatsUiHandler extends UiHandler { show(args: any[]): boolean { super.show(args); + + // show updated username on every render + this.headerText.setText(this.getUsername()); + this.gameStatsContainer.setActive(true).setVisible(true); this.arrowUp.setActive(true).play("prompt").setVisible(false); From a5190396fa7b4e586ecad702b78e5d4dfd8b2d8d Mon Sep 17 00:00:00 2001 From: NightKev <34855794+DayKev@users.noreply.github.com> Date: Sun, 17 Aug 2025 14:13:48 -0700 Subject: [PATCH 09/11] [i18n] Update locales submodule --- public/locales | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/locales b/public/locales index 7fa231e7239..17b353bd575 160000 --- a/public/locales +++ b/public/locales @@ -1 +1 @@ -Subproject commit 7fa231e7239ed23e17a026670c007c97c3cd9e4a +Subproject commit 17b353bd5752b7ce5c9e7051a17ec310e0b99c1e From 02de2595547417e4271979dec30cd2af01c7c682 Mon Sep 17 00:00:00 2001 From: Jimmybald1 <122436263+Jimmybald1@users.noreply.github.com> Date: Sun, 17 Aug 2025 23:22:04 +0200 Subject: [PATCH 10/11] [Beta][Bug] Fix ribbon pre-evolution award not using prevoid (#6283) Fix ribbon pre-evolution award not using prevoid Co-authored-by: Jimmybald1 <147992650+IBBCalc@users.noreply.github.com> --- src/system/ribbons/ribbon-methods.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/system/ribbons/ribbon-methods.ts b/src/system/ribbons/ribbon-methods.ts index a465357ab8c..138c0be7b51 100644 --- a/src/system/ribbons/ribbon-methods.ts +++ b/src/system/ribbons/ribbon-methods.ts @@ -15,6 +15,6 @@ export function awardRibbonsToSpeciesLine(id: SpeciesId, ribbons: RibbonFlag): v dexData[id].ribbons.award(ribbons); // Mark all pre-evolutions of the Pokémon with the same ribbon flags. for (let prevoId = pokemonPrevolutions[id]; !isNullOrUndefined(prevoId); prevoId = pokemonPrevolutions[prevoId]) { - dexData[id].ribbons.award(ribbons); + dexData[prevoId].ribbons.award(ribbons); } } From 2ff9bd46526b200ea0e870f316e089c5dc9533db Mon Sep 17 00:00:00 2001 From: Madmadness65 Date: Sun, 17 Aug 2025 17:57:24 -0500 Subject: [PATCH 11/11] Add missing short party slots to Legacy UI No longer will output an error to the console due to a missing image. --- .../ui/legacy/party_slot_main_short.json | 146 ++++++++++++++++++ .../ui/legacy/party_slot_main_short.png | Bin 0 -> 753 bytes 2 files changed, 146 insertions(+) create mode 100644 public/images/ui/legacy/party_slot_main_short.json create mode 100644 public/images/ui/legacy/party_slot_main_short.png diff --git a/public/images/ui/legacy/party_slot_main_short.json b/public/images/ui/legacy/party_slot_main_short.json new file mode 100644 index 00000000000..d738d524a5b --- /dev/null +++ b/public/images/ui/legacy/party_slot_main_short.json @@ -0,0 +1,146 @@ +{ + "textures": [ + { + "image": "party_slot_main_short.png", + "format": "RGBA8888", + "size": { + "w": 110, + "h": 294 + }, + "scale": 1, + "frames": [ + { + "filename": "party_slot_main_short", + "rotated": false, + "trimmed": false, + "sourceSize": { + "w": 110, + "h": 41 + }, + "spriteSourceSize": { + "x": 0, + "y": 0, + "w": 110, + "h": 41 + }, + "frame": { + "x": 0, + "y": 0, + "w": 110, + "h": 41 + } + }, + { + "filename": "party_slot_main_short_sel", + "rotated": false, + "trimmed": false, + "sourceSize": { + "w": 110, + "h": 41 + }, + "spriteSourceSize": { + "x": 0, + "y": 0, + "w": 110, + "h": 41 + }, + "frame": { + "x": 0, + "y": 41, + "w": 110, + "h": 41 + } + }, + { + "filename": "party_slot_main_short_fnt", + "rotated": false, + "trimmed": false, + "sourceSize": { + "w": 110, + "h": 41 + }, + "spriteSourceSize": { + "x": 0, + "y": 0, + "w": 110, + "h": 41 + }, + "frame": { + "x": 0, + "y": 82, + "w": 110, + "h": 41 + } + }, + { + "filename": "party_slot_main_short_fnt_sel", + "rotated": false, + "trimmed": false, + "sourceSize": { + "w": 110, + "h": 41 + }, + "spriteSourceSize": { + "x": 0, + "y": 0, + "w": 110, + "h": 41 + }, + "frame": { + "x": 0, + "y": 123, + "w": 110, + "h": 41 + } + }, + { + "filename": "party_slot_main_short_swap", + "rotated": false, + "trimmed": false, + "sourceSize": { + "w": 110, + "h": 41 + }, + "spriteSourceSize": { + "x": 0, + "y": 0, + "w": 110, + "h": 41 + }, + "frame": { + "x": 0, + "y": 164, + "w": 110, + "h": 41 + } + }, + { + "filename": "party_slot_main_short_swap_sel", + "rotated": false, + "trimmed": false, + "sourceSize": { + "w": 110, + "h": 41 + }, + "spriteSourceSize": { + "x": 0, + "y": 0, + "w": 110, + "h": 41 + }, + "frame": { + "x": 0, + "y": 205, + "w": 110, + "h": 41 + } + } + ] + } + ], + "meta": { + "app": "https://www.codeandweb.com/texturepacker", + "version": "3.0", + "smartupdate": "$TexturePacker:SmartUpdate:29685f2f538901cf5bf7f0ed2ea867c3:a080ea6c8cccd1e03244214053e79796:565f7afc5ca419b6ba8dbce51ea30818$" + } +} diff --git a/public/images/ui/legacy/party_slot_main_short.png b/public/images/ui/legacy/party_slot_main_short.png new file mode 100644 index 0000000000000000000000000000000000000000..0b1e52917bad22385d734228d3da063eca0d3472 GIT binary patch literal 753 zcmeAS@N?(olHy`uVBq!ia0vp^c|iP)gBeINY;bxGBpHi?+?^QKos)S9n+5oUxO#XbG#t2LG2wlB zSEK+1B}!Z)N`mv#O3D+9QW*jgGxJLH{9Hp6O!W-)%>G%FBlnwH&1|u_AoC(M_WMpCx0Mb!FoY~F-7S95*K_CH$LHc1dnxzcD z@S4ERzyefZU}S8-xBy}*NC)czh)Gj`Y!F}qn!^NE8DwbzWI=Tq8W@0N4{_9AyQ&)H z3$)F_)5S5QBJS-iZ@4(pt#S^dUsnv&|Knp=KKre^a@ zCRb0JbGqfT79GucZQSEGO>`|M~v9MgFXld%f2^wSXD+)ImGl@<_?Fq6H9mGS;-(@2V-^ z^NGJN_`C})(mt-qt_6irmZue$ZJxqB6%2jfExTE)_E+k;_m;WWnx9Pkea+{cdyzgK z_3MD@tJi+hhG>dTs>X=T-G@yGywoiwF-Cu literal 0 HcmV?d00001