Merge remote-tracking branch 'upstream/main' into offline_continue

pull/911/head
Nexllon 2024-05-15 18:04:29 -03:00
commit 1d53be9c65
62 changed files with 3933 additions and 3280 deletions

File diff suppressed because it is too large Load Diff

Binary file not shown.

Before

Width:  |  Height:  |  Size: 50 KiB

After

Width:  |  Height:  |  Size: 50 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 217 B

View File

@ -20,6 +20,15 @@ export function updateUserInfo(): Promise<[boolean, integer]> {
lastSessionSlot = slotId; lastSessionSlot = slotId;
} }
loggedInUser.lastSessionSlot = lastSessionSlot; loggedInUser.lastSessionSlot = lastSessionSlot;
// Migrate old data from before the username was appended
[ 'data', 'sessionData', 'sessionData1', 'sessionData2', 'sessionData3', 'sessionData4' ].map(d => {
if (localStorage.hasOwnProperty(d)) {
if (localStorage.hasOwnProperty(`${d}_${loggedInUser.username}`))
localStorage.setItem(`${d}_${loggedInUser.username}_bak`, localStorage.getItem(`${d}_${loggedInUser.username}`));
localStorage.setItem(`${d}_${loggedInUser.username}`, localStorage.getItem(d));
localStorage.removeItem(d);
}
});
return resolve([ true, 200 ]); return resolve([ true, 200 ]);
} }
Utils.apiFetch('account/info', true).then(response => { Utils.apiFetch('account/info', true).then(response => {

View File

@ -1755,7 +1755,7 @@ export class StatusEffectImmunityAbAttr extends PreSetStatusAbAttr {
} }
getTriggerMessage(pokemon: Pokemon, abilityName: string, ...args: any[]): string { getTriggerMessage(pokemon: Pokemon, abilityName: string, ...args: any[]): string {
return getPokemonMessage(pokemon, `'s ${abilityName}\nprevents ${this.immuneEffects.length ? getStatusEffectDescriptor(this.immuneEffects[0]) : 'status problems'}!`); return getPokemonMessage(pokemon, `'s ${abilityName}\nprevents ${this.immuneEffects.length ? getStatusEffectDescriptor(args[0] as StatusEffect) : 'status problems'}!`);
} }
} }
@ -2825,7 +2825,7 @@ export function applyPostStatChangeAbAttrs(attrType: { new(...args: any[]): Post
export function applyPreSetStatusAbAttrs(attrType: { new(...args: any[]): PreSetStatusAbAttr }, export function applyPreSetStatusAbAttrs(attrType: { new(...args: any[]): PreSetStatusAbAttr },
pokemon: Pokemon, effect: StatusEffect, cancelled: Utils.BooleanHolder, ...args: any[]): Promise<void> { pokemon: Pokemon, effect: StatusEffect, cancelled: Utils.BooleanHolder, ...args: any[]): Promise<void> {
const simulated = args.length > 1 && args[1]; const simulated = args.length > 1 && args[1];
return applyAbAttrsInternal<PreSetStatusAbAttr>(attrType, pokemon, (attr, passive) => attr.applyPreSetStatus(pokemon, passive, effect, cancelled, args), args, false, false, simulated); return applyAbAttrsInternal<PreSetStatusAbAttr>(attrType, pokemon, (attr, passive) => attr.applyPreSetStatus(pokemon, passive, effect, cancelled, args), args, false, false, !simulated);
} }
export function applyPreApplyBattlerTagAbAttrs(attrType: { new(...args: any[]): PreApplyBattlerTagAbAttr }, export function applyPreApplyBattlerTagAbAttrs(attrType: { new(...args: any[]): PreApplyBattlerTagAbAttr },
@ -3456,7 +3456,7 @@ export function initAbilities() {
.attr(MovePowerBoostAbAttr, (user, target, move) => user.scene.currentBattle.turnCommands[target.getBattlerIndex()].command === Command.POKEMON, 2), .attr(MovePowerBoostAbAttr, (user, target, move) => user.scene.currentBattle.turnCommands[target.getBattlerIndex()].command === Command.POKEMON, 2),
new Ability(Abilities.WATER_BUBBLE, 7) new Ability(Abilities.WATER_BUBBLE, 7)
.attr(ReceivedTypeDamageMultiplierAbAttr, Type.FIRE, 0.5) .attr(ReceivedTypeDamageMultiplierAbAttr, Type.FIRE, 0.5)
.attr(MoveTypePowerBoostAbAttr, Type.WATER, 1) .attr(MoveTypePowerBoostAbAttr, Type.WATER, 2)
.attr(StatusEffectImmunityAbAttr, StatusEffect.BURN) .attr(StatusEffectImmunityAbAttr, StatusEffect.BURN)
.ignorable(), .ignorable(),
new Ability(Abilities.STEELWORKER, 7) new Ability(Abilities.STEELWORKER, 7)

View File

@ -544,6 +544,33 @@ export class AquaRingTag extends BattlerTag {
} }
} }
/** Tag used to allow moves that interact with {@link Moves.MINIMIZE} to function */
export class MinimizeTag extends BattlerTag {
constructor() {
super(BattlerTagType.MINIMIZED, BattlerTagLapseType.TURN_END, 1, Moves.MINIMIZE, undefined);
}
canAdd(pokemon: Pokemon): boolean {
return !pokemon.isMax();
}
onAdd(pokemon: Pokemon): void {
super.onAdd(pokemon);
}
lapse(pokemon: Pokemon, lapseType: BattlerTagLapseType): boolean {
//If a pokemon dynamaxes they lose minimized status
if(pokemon.isMax()){
return false
}
return lapseType !== BattlerTagLapseType.CUSTOM || super.lapse(pokemon, lapseType);
}
onRemove(pokemon: Pokemon): void {
super.onRemove(pokemon);
}
}
export class DrowsyTag extends BattlerTag { export class DrowsyTag extends BattlerTag {
constructor() { constructor() {
super(BattlerTagType.DROWSY, BattlerTagLapseType.TURN_END, 2, Moves.YAWN); super(BattlerTagType.DROWSY, BattlerTagLapseType.TURN_END, 2, Moves.YAWN);
@ -1358,6 +1385,8 @@ export function getBattlerTag(tagType: BattlerTagType, turnCount: integer, sourc
return new TypeBoostTag(tagType, sourceMove, Type.ELECTRIC, 2, true); return new TypeBoostTag(tagType, sourceMove, Type.ELECTRIC, 2, true);
case BattlerTagType.MAGNET_RISEN: case BattlerTagType.MAGNET_RISEN:
return new MagnetRisenTag(tagType, sourceMove); return new MagnetRisenTag(tagType, sourceMove);
case BattlerTagType.MINIMIZED:
return new MinimizeTag();
case BattlerTagType.NONE: case BattlerTagType.NONE:
default: default:
return new BattlerTag(tagType, BattlerTagLapseType.CUSTOM, turnCount, sourceMove, sourceId); return new BattlerTag(tagType, BattlerTagLapseType.CUSTOM, turnCount, sourceMove, sourceId);

View File

@ -55,5 +55,6 @@ export enum BattlerTagType {
CURSED = "CURSED", CURSED = "CURSED",
CHARGED = "CHARGED", CHARGED = "CHARGED",
GROUNDED = "GROUNDED", GROUNDED = "GROUNDED",
MAGNET_RISEN = "MAGNET_RISEN" MAGNET_RISEN = "MAGNET_RISEN",
MINIMIZED = "MINIMIZED"
} }

View File

@ -2480,6 +2480,30 @@ export class ThunderAccuracyAttr extends VariableAccuracyAttr {
} }
} }
/**
* Attribute used for moves which never miss
* against Pokemon with the {@link BattlerTagType.MINIMIZED}
* @see {@link apply}
* @param user N/A
* @param target Target of the move
* @param move N/A
* @param args [0] Accuracy of the move to be modified
* @returns true if the function succeeds
*/
export class MinimizeAccuracyAttr extends VariableAccuracyAttr{
apply(user: Pokemon, target: Pokemon, move: Move, args: any[]): boolean {
if (target.getTag(BattlerTagType.MINIMIZED)){
const accuracy = args[0] as Utils.NumberHolder
accuracy.value = -1;
return true;
}
return false;
}
}
export class ToxicAccuracyAttr extends VariableAccuracyAttr { export class ToxicAccuracyAttr extends VariableAccuracyAttr {
apply(user: Pokemon, target: Pokemon, move: Move, args: any[]): boolean { apply(user: Pokemon, target: Pokemon, move: Move, args: any[]): boolean {
if (user.isOfType(Type.POISON)) { if (user.isOfType(Type.POISON)) {
@ -3235,8 +3259,11 @@ export class FaintCountdownAttr extends AddBattlerTagAttr {
} }
} }
/** Attribute used when a move hits a {@link BattlerTagType} for double damage */
export class HitsTagAttr extends MoveAttr { export class HitsTagAttr extends MoveAttr {
/** The {@link BattlerTagType} this move hits */
public tagType: BattlerTagType; public tagType: BattlerTagType;
/** Should this move deal double damage against {@link HitsTagAttr.tagType}? */
public doubleDamage: boolean; public doubleDamage: boolean;
constructor(tagType: BattlerTagType, doubleDamage?: boolean) { constructor(tagType: BattlerTagType, doubleDamage?: boolean) {
@ -4403,6 +4430,8 @@ export function initMoves() {
new AttackMove(Moves.SLAM, Type.NORMAL, MoveCategory.PHYSICAL, 80, 75, 20, -1, 0, 1), new AttackMove(Moves.SLAM, Type.NORMAL, MoveCategory.PHYSICAL, 80, 75, 20, -1, 0, 1),
new AttackMove(Moves.VINE_WHIP, Type.GRASS, MoveCategory.PHYSICAL, 45, 100, 25, -1, 0, 1), new AttackMove(Moves.VINE_WHIP, Type.GRASS, MoveCategory.PHYSICAL, 45, 100, 25, -1, 0, 1),
new AttackMove(Moves.STOMP, Type.NORMAL, MoveCategory.PHYSICAL, 65, 100, 20, 30, 0, 1) new AttackMove(Moves.STOMP, Type.NORMAL, MoveCategory.PHYSICAL, 65, 100, 20, 30, 0, 1)
.attr(MinimizeAccuracyAttr)
.attr(HitsTagAttr, BattlerTagType.MINIMIZED, true)
.attr(FlinchAttr), .attr(FlinchAttr),
new AttackMove(Moves.DOUBLE_KICK, Type.FIGHTING, MoveCategory.PHYSICAL, 30, 100, 30, -1, 0, 1) new AttackMove(Moves.DOUBLE_KICK, Type.FIGHTING, MoveCategory.PHYSICAL, 30, 100, 30, -1, 0, 1)
.attr(MultiHitAttr, MultiHitType._2), .attr(MultiHitAttr, MultiHitType._2),
@ -4426,6 +4455,8 @@ export function initMoves() {
.attr(OneHitKOAccuracyAttr), .attr(OneHitKOAccuracyAttr),
new AttackMove(Moves.TACKLE, Type.NORMAL, MoveCategory.PHYSICAL, 40, 100, 35, -1, 0, 1), new AttackMove(Moves.TACKLE, Type.NORMAL, MoveCategory.PHYSICAL, 40, 100, 35, -1, 0, 1),
new AttackMove(Moves.BODY_SLAM, Type.NORMAL, MoveCategory.PHYSICAL, 85, 100, 15, 30, 0, 1) new AttackMove(Moves.BODY_SLAM, Type.NORMAL, MoveCategory.PHYSICAL, 85, 100, 15, 30, 0, 1)
.attr(MinimizeAccuracyAttr)
.attr(HitsTagAttr, BattlerTagType.MINIMIZED, true)
.attr(StatusEffectAttr, StatusEffect.PARALYSIS), .attr(StatusEffectAttr, StatusEffect.PARALYSIS),
new AttackMove(Moves.WRAP, Type.NORMAL, MoveCategory.PHYSICAL, 15, 90, 20, 100, 0, 1) new AttackMove(Moves.WRAP, Type.NORMAL, MoveCategory.PHYSICAL, 15, 90, 20, 100, 0, 1)
.attr(TrapAttr, BattlerTagType.WRAP), .attr(TrapAttr, BattlerTagType.WRAP),
@ -4623,6 +4654,7 @@ export function initMoves() {
new SelfStatusMove(Moves.HARDEN, Type.NORMAL, -1, 30, -1, 0, 1) new SelfStatusMove(Moves.HARDEN, Type.NORMAL, -1, 30, -1, 0, 1)
.attr(StatChangeAttr, BattleStat.DEF, 1, true), .attr(StatChangeAttr, BattleStat.DEF, 1, true),
new SelfStatusMove(Moves.MINIMIZE, Type.NORMAL, -1, 10, -1, 0, 1) new SelfStatusMove(Moves.MINIMIZE, Type.NORMAL, -1, 10, -1, 0, 1)
.attr(AddBattlerTagAttr, BattlerTagType.MINIMIZED, true, false)
.attr(StatChangeAttr, BattleStat.EVA, 2, true), .attr(StatChangeAttr, BattleStat.EVA, 2, true),
new StatusMove(Moves.SMOKESCREEN, Type.NORMAL, 100, 20, -1, 0, 1) new StatusMove(Moves.SMOKESCREEN, Type.NORMAL, 100, 20, -1, 0, 1)
.attr(StatChangeAttr, BattleStat.ACC, -1), .attr(StatChangeAttr, BattleStat.ACC, -1),
@ -5462,6 +5494,8 @@ export function initMoves() {
new AttackMove(Moves.DRAGON_PULSE, Type.DRAGON, MoveCategory.SPECIAL, 85, 100, 10, -1, 0, 4) new AttackMove(Moves.DRAGON_PULSE, Type.DRAGON, MoveCategory.SPECIAL, 85, 100, 10, -1, 0, 4)
.pulseMove(), .pulseMove(),
new AttackMove(Moves.DRAGON_RUSH, Type.DRAGON, MoveCategory.PHYSICAL, 100, 75, 10, 20, 0, 4) new AttackMove(Moves.DRAGON_RUSH, Type.DRAGON, MoveCategory.PHYSICAL, 100, 75, 10, 20, 0, 4)
.attr(MinimizeAccuracyAttr)
.attr(HitsTagAttr, BattlerTagType.MINIMIZED, true)
.attr(FlinchAttr), .attr(FlinchAttr),
new AttackMove(Moves.POWER_GEM, Type.ROCK, MoveCategory.SPECIAL, 80, 100, 20, -1, 0, 4), new AttackMove(Moves.POWER_GEM, Type.ROCK, MoveCategory.SPECIAL, 80, 100, 20, -1, 0, 4),
new AttackMove(Moves.DRAIN_PUNCH, Type.FIGHTING, MoveCategory.PHYSICAL, 75, 100, 10, -1, 0, 4) new AttackMove(Moves.DRAIN_PUNCH, Type.FIGHTING, MoveCategory.PHYSICAL, 75, 100, 10, -1, 0, 4)
@ -5671,7 +5705,9 @@ export function initMoves() {
.attr(StatChangeAttr, [ BattleStat.SPATK, BattleStat.SPDEF, BattleStat.SPD ], 1, true) .attr(StatChangeAttr, [ BattleStat.SPATK, BattleStat.SPDEF, BattleStat.SPD ], 1, true)
.danceMove(), .danceMove(),
new AttackMove(Moves.HEAVY_SLAM, Type.STEEL, MoveCategory.PHYSICAL, -1, 100, 10, -1, 0, 5) new AttackMove(Moves.HEAVY_SLAM, Type.STEEL, MoveCategory.PHYSICAL, -1, 100, 10, -1, 0, 5)
.attr(MinimizeAccuracyAttr)
.attr(CompareWeightPowerAttr) .attr(CompareWeightPowerAttr)
.attr(HitsTagAttr, BattlerTagType.MINIMIZED, true)
.condition(failOnMaxCondition), .condition(failOnMaxCondition),
new AttackMove(Moves.SYNCHRONOISE, Type.PSYCHIC, MoveCategory.SPECIAL, 120, 100, 10, -1, 0, 5) new AttackMove(Moves.SYNCHRONOISE, Type.PSYCHIC, MoveCategory.SPECIAL, 120, 100, 10, -1, 0, 5)
.target(MoveTarget.ALL_NEAR_OTHERS) .target(MoveTarget.ALL_NEAR_OTHERS)
@ -5802,7 +5838,9 @@ export function initMoves() {
.attr(StatChangeAttr, BattleStat.DEF, -1) .attr(StatChangeAttr, BattleStat.DEF, -1)
.slicingMove(), .slicingMove(),
new AttackMove(Moves.HEAT_CRASH, Type.FIRE, MoveCategory.PHYSICAL, -1, 100, 10, -1, 0, 5) new AttackMove(Moves.HEAT_CRASH, Type.FIRE, MoveCategory.PHYSICAL, -1, 100, 10, -1, 0, 5)
.attr(MinimizeAccuracyAttr)
.attr(CompareWeightPowerAttr) .attr(CompareWeightPowerAttr)
.attr(HitsTagAttr, BattlerTagType.MINIMIZED, true)
.condition(failOnMaxCondition), .condition(failOnMaxCondition),
new AttackMove(Moves.LEAF_TORNADO, Type.GRASS, MoveCategory.SPECIAL, 65, 90, 10, 50, 0, 5) new AttackMove(Moves.LEAF_TORNADO, Type.GRASS, MoveCategory.SPECIAL, 65, 90, 10, 50, 0, 5)
.attr(StatChangeAttr, BattleStat.ACC, -1), .attr(StatChangeAttr, BattleStat.ACC, -1),
@ -5873,7 +5911,9 @@ export function initMoves() {
.makesContact(false) .makesContact(false)
.partial(), .partial(),
new AttackMove(Moves.FLYING_PRESS, Type.FIGHTING, MoveCategory.PHYSICAL, 100, 95, 10, -1, 0, 6) new AttackMove(Moves.FLYING_PRESS, Type.FIGHTING, MoveCategory.PHYSICAL, 100, 95, 10, -1, 0, 6)
.attr(MinimizeAccuracyAttr)
.attr(FlyingTypeMultiplierAttr) .attr(FlyingTypeMultiplierAttr)
.attr(HitsTagAttr, BattlerTagType.MINIMIZED, true)
.condition(failOnGravityCondition), .condition(failOnGravityCondition),
new StatusMove(Moves.MAT_BLOCK, Type.FIGHTING, -1, 10, -1, 0, 6) new StatusMove(Moves.MAT_BLOCK, Type.FIGHTING, -1, 10, -1, 0, 6)
.unimplemented(), .unimplemented(),

View File

@ -855,14 +855,20 @@ export const trainerConfigs: TrainerConfigs = {
}), }),
[TrainerType.RIVAL_6]: new TrainerConfig(++t).setName('Finn').setHasGenders('Ivy').setHasCharSprite().setTitle('Rival').setBoss().setStaticParty().setMoneyMultiplier(3).setEncounterBgm('final').setBattleBgm('battle_rival_3').setPartyTemplates(trainerPartyTemplates.RIVAL_6) [TrainerType.RIVAL_6]: new TrainerConfig(++t).setName('Finn').setHasGenders('Ivy').setHasCharSprite().setTitle('Rival').setBoss().setStaticParty().setMoneyMultiplier(3).setEncounterBgm('final').setBattleBgm('battle_rival_3').setPartyTemplates(trainerPartyTemplates.RIVAL_6)
.setPartyMemberFunc(0, getRandomPartyMemberFunc([ Species.VENUSAUR, Species.CHARIZARD, Species.BLASTOISE, Species.MEGANIUM, Species.TYPHLOSION, Species.FERALIGATR, Species.SCEPTILE, Species.BLAZIKEN, Species.SWAMPERT, Species.TORTERRA, Species.INFERNAPE, Species.EMPOLEON, Species.SERPERIOR, Species.EMBOAR, Species.SAMUROTT, Species.CHESNAUGHT, Species.DELPHOX, Species.GRENINJA, Species.DECIDUEYE, Species.INCINEROAR, Species.PRIMARINA, Species.RILLABOOM, Species.CINDERACE, Species.INTELEON, Species.MEOWSCARADA, Species.SKELEDIRGE, Species.QUAQUAVAL ], TrainerSlot.TRAINER, true, .setPartyMemberFunc(0, getRandomPartyMemberFunc([ Species.VENUSAUR, Species.CHARIZARD, Species.BLASTOISE, Species.MEGANIUM, Species.TYPHLOSION, Species.FERALIGATR, Species.SCEPTILE, Species.BLAZIKEN, Species.SWAMPERT, Species.TORTERRA, Species.INFERNAPE, Species.EMPOLEON, Species.SERPERIOR, Species.EMBOAR, Species.SAMUROTT, Species.CHESNAUGHT, Species.DELPHOX, Species.GRENINJA, Species.DECIDUEYE, Species.INCINEROAR, Species.PRIMARINA, Species.RILLABOOM, Species.CINDERACE, Species.INTELEON, Species.MEOWSCARADA, Species.SKELEDIRGE, Species.QUAQUAVAL ], TrainerSlot.TRAINER, true,
p => p.setBoss(true, 3)) p => {
) p.setBoss(true, 3);
p.generateAndPopulateMoveset();
}))
.setPartyMemberFunc(1, getRandomPartyMemberFunc([ Species.PIDGEOT, Species.NOCTOWL, Species.SWELLOW, Species.STARAPTOR, Species.UNFEZANT, Species.TALONFLAME, Species.TOUCANNON, Species.CORVIKNIGHT, Species.KILOWATTREL ], TrainerSlot.TRAINER, true, .setPartyMemberFunc(1, getRandomPartyMemberFunc([ Species.PIDGEOT, Species.NOCTOWL, Species.SWELLOW, Species.STARAPTOR, Species.UNFEZANT, Species.TALONFLAME, Species.TOUCANNON, Species.CORVIKNIGHT, Species.KILOWATTREL ], TrainerSlot.TRAINER, true,
p => p.setBoss(true, 2))) p => {
p.setBoss(true, 2);
p.generateAndPopulateMoveset();
}))
.setPartyMemberFunc(2, getSpeciesFilterRandomPartyMemberFunc((species: PokemonSpecies) => !pokemonEvolutions.hasOwnProperty(species.speciesId) && !pokemonPrevolutions.hasOwnProperty(species.speciesId) && species.baseTotal >= 450)) .setPartyMemberFunc(2, getSpeciesFilterRandomPartyMemberFunc((species: PokemonSpecies) => !pokemonEvolutions.hasOwnProperty(species.speciesId) && !pokemonPrevolutions.hasOwnProperty(species.speciesId) && species.baseTotal >= 450))
.setSpeciesFilter(species => species.baseTotal >= 540) .setSpeciesFilter(species => species.baseTotal >= 540)
.setPartyMemberFunc(5, getRandomPartyMemberFunc([ Species.RAYQUAZA ], TrainerSlot.TRAINER, true, p => { .setPartyMemberFunc(5, getRandomPartyMemberFunc([ Species.RAYQUAZA ], TrainerSlot.TRAINER, true, p => {
p.setBoss(); p.setBoss();
p.generateAndPopulateMoveset();
p.pokeball = PokeballType.MASTER_BALL; p.pokeball = PokeballType.MASTER_BALL;
p.shiny = true; p.shiny = true;
p.variant = 1; p.variant = 1;

View File

@ -7,6 +7,7 @@ import * as Utils from "../utils";
import BattleScene from "../battle-scene"; import BattleScene from "../battle-scene";
import { SuppressWeatherEffectAbAttr } from "./ability"; import { SuppressWeatherEffectAbAttr } from "./ability";
import { TerrainType } from "./terrain"; import { TerrainType } from "./terrain";
import i18next from "i18next";
export enum WeatherType { export enum WeatherType {
NONE, NONE,
@ -121,23 +122,23 @@ export class Weather {
export function getWeatherStartMessage(weatherType: WeatherType): string { export function getWeatherStartMessage(weatherType: WeatherType): string {
switch (weatherType) { switch (weatherType) {
case WeatherType.SUNNY: case WeatherType.SUNNY:
return 'The sunlight got bright!'; return i18next.t('weather:sunnyStartMessage');
case WeatherType.RAIN: case WeatherType.RAIN:
return 'A downpour started!'; return i18next.t('weather:rainStartMessage');
case WeatherType.SANDSTORM: case WeatherType.SANDSTORM:
return 'A sandstorm brewed!'; return i18next.t('weather:sandstormStartMessage');
case WeatherType.HAIL: case WeatherType.HAIL:
return 'It started to hail!'; return i18next.t('weather:hailStartMessage');
case WeatherType.SNOW: case WeatherType.SNOW:
return 'It started to snow!'; return i18next.t('weather:snowStartMessage');
case WeatherType.FOG: case WeatherType.FOG:
return 'A thick fog emerged!' return i18next.t('weather:fogStartMessage');
case WeatherType.HEAVY_RAIN: case WeatherType.HEAVY_RAIN:
return 'A heavy downpour started!' return i18next.t('weather:heavyRainStartMessage');
case WeatherType.HARSH_SUN: case WeatherType.HARSH_SUN:
return 'The sunlight got hot!' return i18next.t('weather:harshSunStartMessage');
case WeatherType.STRONG_WINDS: case WeatherType.STRONG_WINDS:
return 'A heavy wind began!'; return i18next.t('weather:strongWindsStartMessage');
} }
return null; return null;
@ -146,23 +147,23 @@ export function getWeatherStartMessage(weatherType: WeatherType): string {
export function getWeatherLapseMessage(weatherType: WeatherType): string { export function getWeatherLapseMessage(weatherType: WeatherType): string {
switch (weatherType) { switch (weatherType) {
case WeatherType.SUNNY: case WeatherType.SUNNY:
return 'The sunlight is strong.'; return i18next.t('weather:sunnyLapseMessage');
case WeatherType.RAIN: case WeatherType.RAIN:
return 'The downpour continues.'; return i18next.t('weather:rainLapseMessage');
case WeatherType.SANDSTORM: case WeatherType.SANDSTORM:
return 'The sandstorm rages.'; return i18next.t('weather:sandstormLapseMessage');
case WeatherType.HAIL: case WeatherType.HAIL:
return 'Hail continues to fall.'; return i18next.t('weather:hailLapseMessage');
case WeatherType.SNOW: case WeatherType.SNOW:
return 'The snow is falling down.'; return i18next.t('weather:snowLapseMessage');
case WeatherType.FOG: case WeatherType.FOG:
return 'The fog continues.'; return i18next.t('weather:fogLapseMessage');
case WeatherType.HEAVY_RAIN: case WeatherType.HEAVY_RAIN:
return 'The heavy downpour continues.' return i18next.t('weather:heavyRainLapseMessage');
case WeatherType.HARSH_SUN: case WeatherType.HARSH_SUN:
return 'The sun is scorching hot.' return i18next.t('weather:harshSunLapseMessage');
case WeatherType.STRONG_WINDS: case WeatherType.STRONG_WINDS:
return 'The wind blows intensely.'; return i18next.t('weather:strongWindsLapseMessage');
} }
return null; return null;
@ -182,23 +183,23 @@ export function getWeatherDamageMessage(weatherType: WeatherType, pokemon: Pokem
export function getWeatherClearMessage(weatherType: WeatherType): string { export function getWeatherClearMessage(weatherType: WeatherType): string {
switch (weatherType) { switch (weatherType) {
case WeatherType.SUNNY: case WeatherType.SUNNY:
return 'The sunlight faded.'; return i18next.t('weather:sunnyClearMessage');
case WeatherType.RAIN: case WeatherType.RAIN:
return 'The rain stopped.'; return i18next.t('weather:rainClearMessage');
case WeatherType.SANDSTORM: case WeatherType.SANDSTORM:
return 'The sandstorm subsided.'; return i18next.t('weather:sandstormClearMessage');
case WeatherType.HAIL: case WeatherType.HAIL:
return 'The hail stopped.'; return i18next.t('weather:hailClearMessage');
case WeatherType.SNOW: case WeatherType.SNOW:
return 'The snow stopped.'; return i18next.t('weather:snowClearMessage');
case WeatherType.FOG: case WeatherType.FOG:
return 'The fog disappeared.' return i18next.t('weather:fogClearMessage');
case WeatherType.HEAVY_RAIN: case WeatherType.HEAVY_RAIN:
return 'The heavy rain stopped.' return i18next.t('weather:heavyRainClearMessage');
case WeatherType.HARSH_SUN: case WeatherType.HARSH_SUN:
return 'The harsh sunlight faded.' return i18next.t('weather:harshSunClearMessage');
case WeatherType.STRONG_WINDS: case WeatherType.STRONG_WINDS:
return 'The heavy wind stopped.'; return i18next.t('weather:strongWindsClearMessage');
} }
return null; return null;

View File

@ -9,6 +9,7 @@ import { LearnMovePhase } from "./phases";
import { cos, sin } from "./field/anims"; import { cos, sin } from "./field/anims";
import { PlayerPokemon } from "./field/pokemon"; import { PlayerPokemon } from "./field/pokemon";
import { getTypeRgb } from "./data/type"; import { getTypeRgb } from "./data/type";
import i18next from "i18next";
export class EvolutionPhase extends Phase { export class EvolutionPhase extends Phase {
protected pokemon: PlayerPokemon; protected pokemon: PlayerPokemon;
@ -115,7 +116,7 @@ export class EvolutionPhase extends Phase {
const evolutionHandler = this.scene.ui.getHandler() as EvolutionSceneHandler; const evolutionHandler = this.scene.ui.getHandler() as EvolutionSceneHandler;
const preName = this.pokemon.name; const preName = this.pokemon.name;
this.scene.ui.showText(`What?\n${preName} is evolving!`, null, () => { this.scene.ui.showText(i18next.t('menu:evolving', { pokemonName: preName }), null, () => {
this.pokemon.cry(); this.pokemon.cry();
this.pokemon.getPossibleEvolution(this.evolution).then(evolvedPokemon => { this.pokemon.getPossibleEvolution(this.evolution).then(evolvedPokemon => {
@ -187,8 +188,8 @@ export class EvolutionPhase extends Phase {
this.scene.unshiftPhase(new EndEvolutionPhase(this.scene)); this.scene.unshiftPhase(new EndEvolutionPhase(this.scene));
this.scene.ui.showText(`${preName} stopped evolving.`, null, () => { this.scene.ui.showText(i18next.t('menu:stoppedEvolving', { pokemonName: preName }), null, () => {
this.scene.ui.showText(`Would you like to pause evolutions for ${preName}?\nEvolutions can be re-enabled from the party screen.`, null, () => { this.scene.ui.showText(i18next.t('menu:pauseEvolutionsQuestion', { pokemonName: preName }), null, () => {
const end = () => { const end = () => {
this.scene.ui.showText(null, 0); this.scene.ui.showText(null, 0);
this.scene.playBgm(); this.scene.playBgm();
@ -198,7 +199,7 @@ export class EvolutionPhase extends Phase {
this.scene.ui.setOverlayMode(Mode.CONFIRM, () => { this.scene.ui.setOverlayMode(Mode.CONFIRM, () => {
this.scene.ui.revertMode(); this.scene.ui.revertMode();
this.pokemon.pauseEvolutions = true; this.pokemon.pauseEvolutions = true;
this.scene.ui.showText(`Evolutions have been paused for ${preName}.`, null, end, 3000); this.scene.ui.showText(i18next.t('menu:evolutionsPaused', { pokemonName: preName }), null, end, 3000);
}, () => { }, () => {
this.scene.ui.revertMode(); this.scene.ui.revertMode();
this.scene.time.delayedCall(3000, end); this.scene.time.delayedCall(3000, end);
@ -249,7 +250,7 @@ export class EvolutionPhase extends Phase {
this.scene.playSoundWithoutBgm('evolution_fanfare'); this.scene.playSoundWithoutBgm('evolution_fanfare');
evolvedPokemon.destroy(); evolvedPokemon.destroy();
this.scene.ui.showText(`Congratulations!\nYour ${preName} evolved into ${this.pokemon.name}!`, null, () => this.end(), null, true, Utils.fixedInt(4000)); this.scene.ui.showText(i18next.t('menu:evolutionDone', { pokemonName: preName, evolvedPokemonName: this.pokemon.name }), null, () => this.end(), null, true, Utils.fixedInt(4000));
this.scene.time.delayedCall(Utils.fixedInt(4250), () => this.scene.playBgm()); this.scene.time.delayedCall(Utils.fixedInt(4250), () => this.scene.playBgm());
}); });
}); });

View File

@ -206,6 +206,7 @@ export class Arena {
case Biome.TALL_GRASS: case Biome.TALL_GRASS:
return Type.GRASS; return Type.GRASS;
case Biome.FOREST: case Biome.FOREST:
case Biome.JUNGLE:
return Type.BUG; return Type.BUG;
case Biome.SLUM: case Biome.SLUM:
case Biome.SWAMP: case Biome.SWAMP:
@ -237,8 +238,10 @@ export class Arena {
case Biome.TEMPLE: case Biome.TEMPLE:
return Type.GHOST; return Type.GHOST;
case Biome.DOJO: case Biome.DOJO:
case Biome.CONSTRUCTION_SITE:
return Type.FIGHTING; return Type.FIGHTING;
case Biome.FACTORY: case Biome.FACTORY:
case Biome.LABORATORY:
return Type.STEEL; return Type.STEEL;
case Biome.RUINS: case Biome.RUINS:
case Biome.SPACE: case Biome.SPACE:
@ -248,6 +251,8 @@ export class Arena {
return Type.DRAGON; return Type.DRAGON;
case Biome.ABYSS: case Biome.ABYSS:
return Type.DARK; return Type.DARK;
default:
return Type.UNKNOWN;
} }
} }

View File

@ -1229,14 +1229,20 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container {
for (let i = 0; i < 3; i++) { for (let i = 0; i < 3; i++) {
const moveId = speciesEggMoves[this.species.getRootSpeciesId()][i]; const moveId = speciesEggMoves[this.species.getRootSpeciesId()][i];
if (!movePool.some(m => m[0] === moveId) && !allMoves[moveId].name.endsWith(' (N)')) if (!movePool.some(m => m[0] === moveId) && !allMoves[moveId].name.endsWith(' (N)'))
movePool.push([moveId, Math.min(this.level * 0.5, 40)]); movePool.push([moveId, 40]);
} }
const moveId = speciesEggMoves[this.species.getRootSpeciesId()][3];
if (this.level >= 170 && !movePool.some(m => m[0] === moveId) && !allMoves[moveId].name.endsWith(' (N)') && !this.isBoss()) // No rare egg moves before e4
movePool.push([moveId, 30]);
if (this.fusionSpecies) { if (this.fusionSpecies) {
for (let i = 0; i < 3; i++) { for (let i = 0; i < 3; i++) {
const moveId = speciesEggMoves[this.fusionSpecies.getRootSpeciesId()][i]; const moveId = speciesEggMoves[this.fusionSpecies.getRootSpeciesId()][i];
if (!movePool.some(m => m[0] === moveId) && !allMoves[moveId].name.endsWith(' (N)')) if (!movePool.some(m => m[0] === moveId) && !allMoves[moveId].name.endsWith(' (N)'))
movePool.push([moveId, Math.min(this.level * 0.5, 30)]); movePool.push([moveId, 40]);
} }
const moveId = speciesEggMoves[this.fusionSpecies.getRootSpeciesId()][3];
if (this.level >= 170 && !movePool.some(m => m[0] === moveId) && !allMoves[moveId].name.endsWith(' (N)') && !this.isBoss()) // No rare egg moves before e4
movePool.push([moveId, 30]);
} }
} }
} }
@ -1544,6 +1550,12 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container {
applyPreAttackAbAttrs(DamageBoostAbAttr, source, this, battlerMove, damage); applyPreAttackAbAttrs(DamageBoostAbAttr, source, this, battlerMove, damage);
/**
* For each {@link HitsTagAttr} the move has, doubles the damage of the move if:
* The target has a {@link BattlerTagType} that this move interacts with
* AND
* The move doubles damage when used against that tag
* */
move.getAttrs(HitsTagAttr).map(hta => hta as HitsTagAttr).filter(hta => hta.doubleDamage).forEach(hta => { move.getAttrs(HitsTagAttr).map(hta => hta as HitsTagAttr).filter(hta => hta.doubleDamage).forEach(hta => {
if (this.getTag(hta.tagType)) if (this.getTag(hta.tagType))
damage.value *= 2; damage.value *= 2;

View File

@ -31,6 +31,8 @@ export const battle: SimpleTranslationEntries = {
"learnMoveNotLearned": "{{pokemonName}} hat\n{{moveName}} nicht erlernt.", "learnMoveNotLearned": "{{pokemonName}} hat\n{{moveName}} nicht erlernt.",
"learnMoveForgetQuestion": "Welche Attacke soll vergessen werden?", "learnMoveForgetQuestion": "Welche Attacke soll vergessen werden?",
"learnMoveForgetSuccess": "{{pokemonName}} hat\n{{moveName}} vergessen.", "learnMoveForgetSuccess": "{{pokemonName}} hat\n{{moveName}} vergessen.",
"countdownPoof": "@d{32}Eins, @d{15}zwei @d{15}und@d{15}… @d{15}… @d{15}… @d{15}@s{pb_bounce_1}schwupp!",
"learnMoveAnd": "Und…",
"levelCapUp": "Das Levellimit\nhat sich zu {{levelCap}} erhöht!", "levelCapUp": "Das Levellimit\nhat sich zu {{levelCap}} erhöht!",
"moveNotImplemented": "{{moveName}} ist noch nicht implementiert und kann nicht ausgewählt werden.", "moveNotImplemented": "{{moveName}} ist noch nicht implementiert und kann nicht ausgewählt werden.",
"moveNoPP": "Es sind keine AP für\ndiese Attacke mehr übrig!", "moveNoPP": "Es sind keine AP für\ndiese Attacke mehr übrig!",
@ -43,7 +45,7 @@ export const battle: SimpleTranslationEntries = {
"noEscapeTrainer": "Du kannst nicht\naus einem Trainerkampf fliehen!", "noEscapeTrainer": "Du kannst nicht\naus einem Trainerkampf fliehen!",
"noEscapePokemon": "{{pokemonName}}'s {{moveName}}\nverhindert {{escapeVerb}}!", "noEscapePokemon": "{{pokemonName}}'s {{moveName}}\nverhindert {{escapeVerb}}!",
"runAwaySuccess": "Du bist entkommen!", "runAwaySuccess": "Du bist entkommen!",
"runAwayCannotEscape": 'Flucht unmöglich!', "runAwayCannotEscape": 'Flucht gescheitert!',
"escapeVerbSwitch": "auswechseln", "escapeVerbSwitch": "auswechseln",
"escapeVerbFlee": "flucht", "escapeVerbFlee": "flucht",
"skipItemQuestion": "Bist du sicher, dass du kein Item nehmen willst?", "skipItemQuestion": "Bist du sicher, dass du kein Item nehmen willst?",

View File

@ -9,7 +9,7 @@ export const menuUiHandler: SimpleTranslationEntries = {
"EGG_GACHA": "Eier-Gacha", "EGG_GACHA": "Eier-Gacha",
"MANAGE_DATA": "Daten verwalten", "MANAGE_DATA": "Daten verwalten",
"COMMUNITY": "Community", "COMMUNITY": "Community",
"RETURN_TO_TITLE": "Zurück zum Titelbildschirm", "SAVE_AND_QUIT": "Save and Quit",
"LOG_OUT": "Ausloggen", "LOG_OUT": "Ausloggen",
"slot": "Slot {{slotNumber}}", "slot": "Slot {{slotNumber}}",
"importSession": "Sitzung importieren", "importSession": "Sitzung importieren",

View File

@ -35,6 +35,11 @@ export const menu: SimpleTranslationEntries = {
"boyOrGirl": "Bist du ein Junge oder ein Mädchen?", "boyOrGirl": "Bist du ein Junge oder ein Mädchen?",
"boy": "Junge", "boy": "Junge",
"girl": "Mädchen", "girl": "Mädchen",
"evolving": "What?\n{{pokemonName}} is evolving!",
"stoppedEvolving": "{{pokemonName}} stopped evolving.",
"pauseEvolutionsQuestion": "Would you like to pause evolutions for {{pokemonName}}?\nEvolutions can be re-enabled from the party screen.",
"evolutionsPaused": "Evolutions have been paused for {{pokemonName}}.",
"evolutionDone": "Congratulations!\nYour {{pokemonName}} evolved into {{evolvedPokemonName}}!",
"dailyRankings": "Tägliche Rangliste", "dailyRankings": "Tägliche Rangliste",
"weeklyRankings": "Wöchentliche Rangliste", "weeklyRankings": "Wöchentliche Rangliste",
"noRankings": "Keine Rangliste", "noRankings": "Keine Rangliste",

View File

@ -7,6 +7,15 @@ import { SimpleTranslationEntries } from "#app/plugins/i18n";
*/ */
export const starterSelectUiHandler: SimpleTranslationEntries = { export const starterSelectUiHandler: SimpleTranslationEntries = {
"confirmStartTeam": "Mit diesen Pokémon losziehen?", "confirmStartTeam": "Mit diesen Pokémon losziehen?",
"gen1": "I",
"gen2": "II",
"gen3": "III",
"gen4": "IV",
"gen5": "V",
"gen6": "VI",
"gen7": "VII",
"gen8": "VIII",
"gen9": "IX",
"growthRate": "Wachstum:", "growthRate": "Wachstum:",
"ability": "Fhgkeit:", "ability": "Fhgkeit:",
"passive": "Passiv:", "passive": "Passiv:",

44
src/locales/de/weather.ts Normal file
View File

@ -0,0 +1,44 @@
import { SimpleTranslationEntries } from "#app/plugins/i18n";
/**
* The weather namespace holds text displayed when weather is active during a battle
*/
export const weather: SimpleTranslationEntries = {
"sunnyStartMessage": "The sunlight got bright!",
"sunnyLapseMessage": "The sunlight is strong.",
"sunnyClearMessage": "The sunlight faded.",
"rainStartMessage": "A downpour started!",
"rainLapseMessage": "The downpour continues.",
"rainClearMessage": "The rain stopped.",
"sandstormStartMessage": "A sandstorm brewed!",
"sandstormLapseMessage": "The sandstorm rages.",
"sandstormClearMessage": "The sandstorm subsided.",
"sandstormDamageMessage": "{{pokemonPrefix}}{{pokemonName}} is buffeted\nby the sandstorm!",
"hailStartMessage": "It started to hail!",
"hailLapseMessage": "Hail continues to fall.",
"hailClearMessage": "The hail stopped.",
"hailDamageMessage": "{{pokemonPrefix}}{{pokemonName}} is pelted\nby the hail!",
"snowStartMessage": "It started to snow!",
"snowLapseMessage": "The snow is falling down.",
"snowClearMessage": "The snow stopped.",
"fogStartMessage": "A thick fog emerged!",
"fogLapseMessage": "The fog continues.",
"fogClearMessage": "The fog disappeared.",
"heavyRainStartMessage": "A heavy downpour started!",
"heavyRainLapseMessage": "The heavy downpour continues.",
"heavyRainClearMessage": "The heavy rain stopped.",
"harshSunStartMessage": "The sunlight got hot!",
"harshSunLapseMessage": "The sun is scorching hot.",
"harshSunClearMessage": "The harsh sunlight faded.",
"strongWindsStartMessage": "A heavy wind began!",
"strongWindsLapseMessage": "The wind blows intensely.",
"strongWindsClearMessage": "The heavy wind stopped."
}

View File

@ -31,6 +31,8 @@ export const battle: SimpleTranslationEntries = {
"learnMoveNotLearned": "{{pokemonName}} did not learn the\nmove {{moveName}}.", "learnMoveNotLearned": "{{pokemonName}} did not learn the\nmove {{moveName}}.",
"learnMoveForgetQuestion": "Which move should be forgotten?", "learnMoveForgetQuestion": "Which move should be forgotten?",
"learnMoveForgetSuccess": "{{pokemonName}} forgot how to\nuse {{moveName}}.", "learnMoveForgetSuccess": "{{pokemonName}} forgot how to\nuse {{moveName}}.",
"countdownPoof": "@d{32}1, @d{15}2, and@d{15}… @d{15}… @d{15}… @d{15}@s{pb_bounce_1}Poof!",
"learnMoveAnd": "And…",
"levelCapUp": "The level cap\nhas increased to {{levelCap}}!", "levelCapUp": "The level cap\nhas increased to {{levelCap}}!",
"moveNotImplemented": "{{moveName}} is not yet implemented and cannot be selected.", "moveNotImplemented": "{{moveName}} is not yet implemented and cannot be selected.",
"moveNoPP": "There's no PP left for\nthis move!", "moveNoPP": "There's no PP left for\nthis move!",

View File

@ -13,6 +13,7 @@ import { pokemon } from "./pokemon";
import { pokemonStat } from "./pokemon-stat"; import { pokemonStat } from "./pokemon-stat";
import { starterSelectUiHandler } from "./starter-select-ui-handler"; import { starterSelectUiHandler } from "./starter-select-ui-handler";
import { tutorial } from "./tutorial"; import { tutorial } from "./tutorial";
import { weather } from "./weather";
export const enConfig = { export const enConfig = {
@ -30,5 +31,6 @@ export const enConfig = {
starterSelectUiHandler: starterSelectUiHandler, starterSelectUiHandler: starterSelectUiHandler,
tutorial: tutorial, tutorial: tutorial,
nature: nature, nature: nature,
growth: growth growth: growth,
weather: weather
} }

View File

@ -9,7 +9,7 @@ export const menuUiHandler: SimpleTranslationEntries = {
"EGG_GACHA": "Egg Gacha", "EGG_GACHA": "Egg Gacha",
"MANAGE_DATA": "Manage Data", "MANAGE_DATA": "Manage Data",
"COMMUNITY": "Community", "COMMUNITY": "Community",
"RETURN_TO_TITLE": "Return To Title", "SAVE_AND_QUIT": "Save and Quit",
"LOG_OUT": "Log Out", "LOG_OUT": "Log Out",
"slot": "Slot {{slotNumber}}", "slot": "Slot {{slotNumber}}",
"importSession": "Import Session", "importSession": "Import Session",

View File

@ -35,6 +35,11 @@ export const menu: SimpleTranslationEntries = {
"boyOrGirl": "Are you a boy or a girl?", "boyOrGirl": "Are you a boy or a girl?",
"boy": "Boy", "boy": "Boy",
"girl": "Girl", "girl": "Girl",
"evolving": "What?\n{{pokemonName}} is evolving!",
"stoppedEvolving": "{{pokemonName}} stopped evolving.",
"pauseEvolutionsQuestion": "Would you like to pause evolutions for {{pokemonName}}?\nEvolutions can be re-enabled from the party screen.",
"evolutionsPaused": "Evolutions have been paused for {{pokemonName}}.",
"evolutionDone": "Congratulations!\nYour {{pokemonName}} evolved into {{evolvedPokemonName}}!",
"dailyRankings": "Daily Rankings", "dailyRankings": "Daily Rankings",
"weeklyRankings": "Weekly Rankings", "weeklyRankings": "Weekly Rankings",
"noRankings": "No Rankings", "noRankings": "No Rankings",

View File

@ -7,6 +7,15 @@ import { SimpleTranslationEntries } from "#app/plugins/i18n";
*/ */
export const starterSelectUiHandler: SimpleTranslationEntries = { export const starterSelectUiHandler: SimpleTranslationEntries = {
"confirmStartTeam":'Begin with these Pokémon?', "confirmStartTeam":'Begin with these Pokémon?',
"gen1": "I",
"gen2": "II",
"gen3": "III",
"gen4": "IV",
"gen5": "V",
"gen6": "VI",
"gen7": "VII",
"gen8": "VIII",
"gen9": "IX",
"growthRate": "Growth Rate:", "growthRate": "Growth Rate:",
"ability": "Ability:", "ability": "Ability:",
"passive": "Passive:", "passive": "Passive:",

44
src/locales/en/weather.ts Normal file
View File

@ -0,0 +1,44 @@
import { SimpleTranslationEntries } from "#app/plugins/i18n";
/**
* The weather namespace holds text displayed when weather is active during a battle
*/
export const weather: SimpleTranslationEntries = {
"sunnyStartMessage": "The sunlight got bright!",
"sunnyLapseMessage": "The sunlight is strong.",
"sunnyClearMessage": "The sunlight faded.",
"rainStartMessage": "A downpour started!",
"rainLapseMessage": "The downpour continues.",
"rainClearMessage": "The rain stopped.",
"sandstormStartMessage": "A sandstorm brewed!",
"sandstormLapseMessage": "The sandstorm rages.",
"sandstormClearMessage": "The sandstorm subsided.",
"sandstormDamageMessage": "{{pokemonPrefix}}{{pokemonName}} is buffeted\nby the sandstorm!",
"hailStartMessage": "It started to hail!",
"hailLapseMessage": "Hail continues to fall.",
"hailClearMessage": "The hail stopped.",
"hailDamageMessage": "{{pokemonPrefix}}{{pokemonName}} is pelted\nby the hail!",
"snowStartMessage": "It started to snow!",
"snowLapseMessage": "The snow is falling down.",
"snowClearMessage": "The snow stopped.",
"fogStartMessage": "A thick fog emerged!",
"fogLapseMessage": "The fog continues.",
"fogClearMessage": "The fog disappeared.",
"heavyRainStartMessage": "A heavy downpour started!",
"heavyRainLapseMessage": "The heavy downpour continues.",
"heavyRainClearMessage": "The heavy rain stopped.",
"harshSunStartMessage": "The sunlight got hot!",
"harshSunLapseMessage": "The sun is scorching hot.",
"harshSunClearMessage": "The harsh sunlight faded.",
"strongWindsStartMessage": "A heavy wind began!",
"strongWindsLapseMessage": "The wind blows intensely.",
"strongWindsClearMessage": "The heavy wind stopped."
}

View File

@ -31,6 +31,8 @@ export const battle: SimpleTranslationEntries = {
"learnMoveNotLearned": "{{pokemonName}} no ha aprendido {{moveName}}.", "learnMoveNotLearned": "{{pokemonName}} no ha aprendido {{moveName}}.",
"learnMoveForgetQuestion": "¿Qué movimiento quieres que olvide?", "learnMoveForgetQuestion": "¿Qué movimiento quieres que olvide?",
"learnMoveForgetSuccess": "{{pokemonName}} ha olvidado cómo utilizar {{moveName}}.", "learnMoveForgetSuccess": "{{pokemonName}} ha olvidado cómo utilizar {{moveName}}.",
"countdownPoof": "@d{32}1, @d{15}2, @d{15}y@d{15}… @d{15}… @d{15}… @d{15}@s{pb_bounce_1}¡Puf!",
"learnMoveAnd": "Y…",
"levelCapUp": "¡Se ha incrementado el\nnivel máximo a {{levelCap}}!", "levelCapUp": "¡Se ha incrementado el\nnivel máximo a {{levelCap}}!",
"moveNotImplemented": "{{moveName}} aún no está implementado y no se puede seleccionar.", "moveNotImplemented": "{{moveName}} aún no está implementado y no se puede seleccionar.",
"moveNoPP": "There's no PP left for\nthis move!", "moveNoPP": "There's no PP left for\nthis move!",

View File

@ -13,6 +13,7 @@ import { pokemon } from "./pokemon";
import { pokemonStat } from "./pokemon-stat"; import { pokemonStat } from "./pokemon-stat";
import { starterSelectUiHandler } from "./starter-select-ui-handler"; import { starterSelectUiHandler } from "./starter-select-ui-handler";
import { tutorial } from "./tutorial"; import { tutorial } from "./tutorial";
import { weather } from "./weather";
export const esConfig = { export const esConfig = {
@ -30,5 +31,6 @@ export const esConfig = {
starterSelectUiHandler: starterSelectUiHandler, starterSelectUiHandler: starterSelectUiHandler,
tutorial: tutorial, tutorial: tutorial,
nature: nature, nature: nature,
growth: growth growth: growth,
weather: weather
} }

View File

@ -9,7 +9,7 @@ export const menuUiHandler: SimpleTranslationEntries = {
"EGG_GACHA": "Gacha de Huevos", "EGG_GACHA": "Gacha de Huevos",
"MANAGE_DATA": "Gestionar Datos", "MANAGE_DATA": "Gestionar Datos",
"COMMUNITY": "Comunidad", "COMMUNITY": "Comunidad",
"RETURN_TO_TITLE": "Volver al Título", "SAVE_AND_QUIT": "Save and Quit",
"LOG_OUT": "Cerrar Sesión", "LOG_OUT": "Cerrar Sesión",
"slot": "Ranura {{slotNumber}}", "slot": "Ranura {{slotNumber}}",
"importSession": "Importar Sesión", "importSession": "Importar Sesión",

View File

@ -35,6 +35,11 @@ export const menu: SimpleTranslationEntries = {
"boyOrGirl": "¿Eres un chico o una chica?", "boyOrGirl": "¿Eres un chico o una chica?",
"boy": "Chico", "boy": "Chico",
"girl": "Chica", "girl": "Chica",
"evolving": "What?\n{{pokemonName}} is evolving!",
"stoppedEvolving": "{{pokemonName}} stopped evolving.",
"pauseEvolutionsQuestion": "Would you like to pause evolutions for {{pokemonName}}?\nEvolutions can be re-enabled from the party screen.",
"evolutionsPaused": "Evolutions have been paused for {{pokemonName}}.",
"evolutionDone": "Congratulations!\nYour {{pokemonName}} evolved into {{evolvedPokemonName}}!",
"dailyRankings": "Rankings Diarios", "dailyRankings": "Rankings Diarios",
"weeklyRankings": "Rankings Semanales", "weeklyRankings": "Rankings Semanales",
"noRankings": "Sin Rankings", "noRankings": "Sin Rankings",

View File

@ -7,6 +7,15 @@ import { SimpleTranslationEntries } from "#app/plugins/i18n";
*/ */
export const starterSelectUiHandler: SimpleTranslationEntries = { export const starterSelectUiHandler: SimpleTranslationEntries = {
"confirmStartTeam":'¿Comenzar con estos Pokémon?', "confirmStartTeam":'¿Comenzar con estos Pokémon?',
"gen1": "I",
"gen2": "II",
"gen3": "III",
"gen4": "IV",
"gen5": "V",
"gen6": "VI",
"gen7": "VII",
"gen8": "VIII",
"gen9": "IX",
"growthRate": "Crecimiento:", "growthRate": "Crecimiento:",
"ability": "Habilid:", "ability": "Habilid:",
"passive": "Pasiva:", "passive": "Pasiva:",

44
src/locales/es/weather.ts Normal file
View File

@ -0,0 +1,44 @@
import { SimpleTranslationEntries } from "#app/plugins/i18n";
/**
* The weather namespace holds text displayed when weather is active during a battle
*/
export const weather: SimpleTranslationEntries = {
"sunnyStartMessage": "The sunlight got bright!",
"sunnyLapseMessage": "The sunlight is strong.",
"sunnyClearMessage": "The sunlight faded.",
"rainStartMessage": "A downpour started!",
"rainLapseMessage": "The downpour continues.",
"rainClearMessage": "The rain stopped.",
"sandstormStartMessage": "A sandstorm brewed!",
"sandstormLapseMessage": "The sandstorm rages.",
"sandstormClearMessage": "The sandstorm subsided.",
"sandstormDamageMessage": "{{pokemonPrefix}}{{pokemonName}} is buffeted\nby the sandstorm!",
"hailStartMessage": "It started to hail!",
"hailLapseMessage": "Hail continues to fall.",
"hailClearMessage": "The hail stopped.",
"hailDamageMessage": "{{pokemonPrefix}}{{pokemonName}} is pelted\nby the hail!",
"snowStartMessage": "It started to snow!",
"snowLapseMessage": "The snow is falling down.",
"snowClearMessage": "The snow stopped.",
"fogStartMessage": "A thick fog emerged!",
"fogLapseMessage": "The fog continues.",
"fogClearMessage": "The fog disappeared.",
"heavyRainStartMessage": "A heavy downpour started!",
"heavyRainLapseMessage": "The heavy downpour continues.",
"heavyRainClearMessage": "The heavy rain stopped.",
"harshSunStartMessage": "The sunlight got hot!",
"harshSunLapseMessage": "The sun is scorching hot.",
"harshSunClearMessage": "The harsh sunlight faded.",
"strongWindsStartMessage": "A heavy wind began!",
"strongWindsLapseMessage": "The wind blows intensely.",
"strongWindsClearMessage": "The heavy wind stopped."
}

View File

@ -31,6 +31,8 @@ export const battle: SimpleTranslationEntries = {
"learnMoveNotLearned": "{{pokemonName}} na pas appris\n{{moveName}}.", "learnMoveNotLearned": "{{pokemonName}} na pas appris\n{{moveName}}.",
"learnMoveForgetQuestion": "Quelle capacité doit être oubliée ?", "learnMoveForgetQuestion": "Quelle capacité doit être oubliée ?",
"learnMoveForgetSuccess": "{{pokemonName}} oublie comment\nutiliser {{moveName}}.", "learnMoveForgetSuccess": "{{pokemonName}} oublie comment\nutiliser {{moveName}}.",
"countdownPoof": "@d{32}1, @d{15}2, @d{15}et@d{15}… @d{15}… @d{15}… @d{15}@s{pb_bounce_1}Tadaaa !",
"learnMoveAnd": "Et…",
"levelCapUp": "La limite de niveau\na été augmentée à {{levelCap}} !", "levelCapUp": "La limite de niveau\na été augmentée à {{levelCap}} !",
"moveNotImplemented": "{{moveName}} nest pas encore implémenté et ne peut pas être sélectionné.", "moveNotImplemented": "{{moveName}} nest pas encore implémenté et ne peut pas être sélectionné.",
"moveNoPP": "Il ny a plus de PP pour\ncette capacité !", "moveNoPP": "Il ny a plus de PP pour\ncette capacité !",

View File

@ -13,6 +13,7 @@ import { pokemon } from "./pokemon";
import { pokemonStat } from "./pokemon-stat"; import { pokemonStat } from "./pokemon-stat";
import { starterSelectUiHandler } from "./starter-select-ui-handler"; import { starterSelectUiHandler } from "./starter-select-ui-handler";
import { tutorial } from "./tutorial"; import { tutorial } from "./tutorial";
import { weather } from "./weather";
export const frConfig = { export const frConfig = {
@ -30,5 +31,6 @@ export const frConfig = {
starterSelectUiHandler: starterSelectUiHandler, starterSelectUiHandler: starterSelectUiHandler,
tutorial: tutorial, tutorial: tutorial,
nature: nature, nature: nature,
growth: growth growth: growth,
weather: weather
} }

View File

@ -9,7 +9,7 @@ export const menuUiHandler: SimpleTranslationEntries = {
"EGG_GACHA": "Gacha-Œufs", "EGG_GACHA": "Gacha-Œufs",
"MANAGE_DATA": "Mes données", "MANAGE_DATA": "Mes données",
"COMMUNITY": "Communauté", "COMMUNITY": "Communauté",
"RETURN_TO_TITLE": "Écran titre", "SAVE_AND_QUIT": "Sauver & quitter",
"LOG_OUT": "Déconnexion", "LOG_OUT": "Déconnexion",
"slot": "Emplacement {{slotNumber}}", "slot": "Emplacement {{slotNumber}}",
"importSession": "Importer session", "importSession": "Importer session",

View File

@ -30,6 +30,11 @@ export const menu: SimpleTranslationEntries = {
"boyOrGirl": "Es-tu un garçon ou une fille ?", "boyOrGirl": "Es-tu un garçon ou une fille ?",
"boy": "Garçon", "boy": "Garçon",
"girl": "Fille", "girl": "Fille",
"evolving": "Hein ?\n{{pokemonName}} évolue !",
"stoppedEvolving": "{{pokemonName}} a stoppé son évolution.",
"pauseEvolutionsQuestion": "Voulez-vous pauser les évolutions pour {{pokemonName}} ?\nLes évolutions peuvent être réactivées depuis l'écran d'équipe.",
"evolutionsPaused": "Les évolutions ont été mises en pause pour {{pokemonName}}.",
"evolutionDone": "Félicitations !\nVotre {{pokemonName}} a évolué en {{evolvedPokemonName}} !",
"dailyRankings": "Classement du Jour", "dailyRankings": "Classement du Jour",
"weeklyRankings": "Classement de la Semaine", "weeklyRankings": "Classement de la Semaine",
"noRankings": "Pas de Classement", "noRankings": "Pas de Classement",

View File

@ -7,6 +7,15 @@ import { SimpleTranslationEntries } from "#app/plugins/i18n";
*/ */
export const starterSelectUiHandler: SimpleTranslationEntries = { export const starterSelectUiHandler: SimpleTranslationEntries = {
"confirmStartTeam":'Commencer avec ces Pokémon ?', "confirmStartTeam":'Commencer avec ces Pokémon ?',
"gen1": "1G",
"gen2": "2G",
"gen3": "3G",
"gen4": "4G",
"gen5": "5G",
"gen6": "6G",
"gen7": "7G",
"gen8": "8G",
"gen9": "9G",
"growthRate": "Croissance :", "growthRate": "Croissance :",
"ability": "Talent :", "ability": "Talent :",
"passive": "Passif :", "passive": "Passif :",
@ -31,5 +40,5 @@ export const starterSelectUiHandler: SimpleTranslationEntries = {
"disablePassive": "Désactiver Passif", "disablePassive": "Désactiver Passif",
"locked": "Verrouillé", "locked": "Verrouillé",
"disabled": "Désactivé", "disabled": "Désactivé",
"uncaught": "Uncaught" "uncaught": "Non-capturé"
} }

44
src/locales/fr/weather.ts Normal file
View File

@ -0,0 +1,44 @@
import { SimpleTranslationEntries } from "#app/plugins/i18n";
/**
* The weather namespace holds text displayed when weather is active during a battle
*/
export const weather: SimpleTranslationEntries = {
"sunnyStartMessage": "Les rayons du soleil brillent !",
"sunnyLapseMessage": "Les rayons du soleil brillent fort !",
"sunnyClearMessage": "Les rayons du soleil saffaiblissent !",
"rainStartMessage": "Il commence à pleuvoir !",
"rainLapseMessage": "La pluie continue de tomber !",
"rainClearMessage": "La pluie sest arrêtée !",
"sandstormStartMessage": "Une tempête de sable se prépare !",
"sandstormLapseMessage": "La tempête de sable fait rage !",
"sandstormClearMessage": "La tempête de sable se calme !",
"sandstormDamageMessage": "La tempête de sable inflige des dégâts\nà {{pokemonPrefix}}{{pokemonName}} !",
"hailStartMessage": "Il commence à grêler !",
"hailLapseMessage": "La grêle continue de tomber !",
"hailClearMessage": "La grêle sest arrêtée !",
"hailDamageMessage": "La grêle inflige des dégâts\nà {{pokemonPrefix}}{{pokemonName}} !",
"snowStartMessage": "Il commence à neiger !",
"snowLapseMessage": "Il y a une tempête de neige !",
"snowClearMessage": "La neige sest arrêtée !",
"fogStartMessage": "Le brouillard devient épais…",
"fogLapseMessage": "Le brouillard continue !",
"fogClearMessage": "Le brouillard sest dissipé !",
"heavyRainStartMessage": "Une pluie battante sabat soudainement !",
"heavyRainLapseMessage": "La pluie battante continue.",
"heavyRainClearMessage": "La pluie battante sest arrêtée…",
"harshSunStartMessage": "Les rayons du soleil sintensifient !",
"harshSunLapseMessage": "Les rayons du soleil sont brulants !",
"harshSunClearMessage": "Les rayons du soleil saffaiblissent !",
"strongWindsStartMessage": "Un vent mystérieux se lève !",
"strongWindsLapseMessage": "Le vent mystérieux violemment !",
"strongWindsClearMessage": "Le vent mystérieux sest dissipé…"
}

View File

@ -31,6 +31,8 @@ export const battle: SimpleTranslationEntries = {
"learnMoveNotLearned": "{{pokemonName}} non ha imparato\n{{moveName}}.", "learnMoveNotLearned": "{{pokemonName}} non ha imparato\n{{moveName}}.",
"learnMoveForgetQuestion": "Quale mossa deve dimenticare?", "learnMoveForgetQuestion": "Quale mossa deve dimenticare?",
"learnMoveForgetSuccess": "{{pokemonName}} ha dimenticato la mossa\n{{moveName}}.", "learnMoveForgetSuccess": "{{pokemonName}} ha dimenticato la mossa\n{{moveName}}.",
"countdownPoof": "@d{32}1, @d{15}2, @d{15}e@d{15}… @d{15}… @d{15}… @d{15}@s{pb_bounce_1}Puff!",
"learnMoveAnd": "E…",
"levelCapUp": "Il livello massimo\nè aumentato a {{levelCap}}!", "levelCapUp": "Il livello massimo\nè aumentato a {{levelCap}}!",
"moveNotImplemented": "{{moveName}} non è ancora implementata e non può essere selezionata.", "moveNotImplemented": "{{moveName}} non è ancora implementata e non può essere selezionata.",
"moveNoPP": "Non ci sono PP rimanenti\nper questa mossa!", "moveNoPP": "Non ci sono PP rimanenti\nper questa mossa!",

View File

@ -13,6 +13,7 @@ import { pokemon } from "./pokemon";
import { pokemonStat } from "./pokemon-stat"; import { pokemonStat } from "./pokemon-stat";
import { starterSelectUiHandler } from "./starter-select-ui-handler"; import { starterSelectUiHandler } from "./starter-select-ui-handler";
import { tutorial } from "./tutorial"; import { tutorial } from "./tutorial";
import { weather } from "./weather";
export const itConfig = { export const itConfig = {
@ -30,5 +31,6 @@ export const itConfig = {
starterSelectUiHandler: starterSelectUiHandler, starterSelectUiHandler: starterSelectUiHandler,
tutorial: tutorial, tutorial: tutorial,
nature: nature, nature: nature,
growth: growth growth: growth,
weather: weather
} }

View File

@ -9,7 +9,7 @@ export const menuUiHandler: SimpleTranslationEntries = {
"EGG_GACHA": "Gacha Uova", "EGG_GACHA": "Gacha Uova",
"MANAGE_DATA": "Gestisci Dati", "MANAGE_DATA": "Gestisci Dati",
"COMMUNITY": "Community", "COMMUNITY": "Community",
"RETURN_TO_TITLE": "Ritorna al Titolo", "SAVE_AND_QUIT": "Save and Quit",
"LOG_OUT": "Disconnettiti", "LOG_OUT": "Disconnettiti",
"slot": "Slot {{slotNumber}}", "slot": "Slot {{slotNumber}}",
"importSession": "Importa Sessione", "importSession": "Importa Sessione",

View File

@ -40,6 +40,11 @@ export const menu: SimpleTranslationEntries = {
"noRankings": "Nessuna Classifica", "noRankings": "Nessuna Classifica",
"loading": "Caricamento…", "loading": "Caricamento…",
"playersOnline": "Giocatori Online", "playersOnline": "Giocatori Online",
"evolving": "What?\n{{pokemonName}} is evolving!",
"stoppedEvolving": "{{pokemonName}} stopped evolving.",
"pauseEvolutionsQuestion": "Would you like to pause evolutions for {{pokemonName}}?\nEvolutions can be re-enabled from the party screen.",
"evolutionsPaused": "Evolutions have been paused for {{pokemonName}}.",
"evolutionDone": "Congratulations!\nYour {{pokemonName}} evolved into {{evolvedPokemonName}}!",
"empty":"Vuoto", "empty":"Vuoto",
"yes":"Si", "yes":"Si",
"no":"No", "no":"No",

View File

@ -7,6 +7,15 @@ import { SimpleTranslationEntries } from "#app/plugins/i18n";
*/ */
export const starterSelectUiHandler: SimpleTranslationEntries = { export const starterSelectUiHandler: SimpleTranslationEntries = {
"confirmStartTeam":'Vuoi iniziare con questi Pokémon?', "confirmStartTeam":'Vuoi iniziare con questi Pokémon?',
"gen1": "I",
"gen2": "II",
"gen3": "III",
"gen4": "IV",
"gen5": "V",
"gen6": "VI",
"gen7": "VII",
"gen8": "VIII",
"gen9": "IX",
"growthRate": "Vel. Crescita:", "growthRate": "Vel. Crescita:",
"ability": "Abilità:", "ability": "Abilità:",
"passive": "Passiva:", "passive": "Passiva:",
@ -29,7 +38,7 @@ export const starterSelectUiHandler: SimpleTranslationEntries = {
"cycleVariant": 'V: Alterna Variante', "cycleVariant": 'V: Alterna Variante',
"enablePassive": "Attiva Passiva", "enablePassive": "Attiva Passiva",
"disablePassive": "Disattiva Passiva", "disablePassive": "Disattiva Passiva",
"locked": "Locked", "locked": "Bloccato",
"disabled": "Disabled", "disabled": "Disabilitato",
"uncaught": "Uncaught" "uncaught": "Non Catturato"
} }

44
src/locales/it/weather.ts Normal file
View File

@ -0,0 +1,44 @@
import { SimpleTranslationEntries } from "#app/plugins/i18n";
/**
* The weather namespace holds text displayed when weather is active during a battle
*/
export const weather: SimpleTranslationEntries = {
"sunnyStartMessage": "The sunlight got bright!",
"sunnyLapseMessage": "The sunlight is strong.",
"sunnyClearMessage": "The sunlight faded.",
"rainStartMessage": "A downpour started!",
"rainLapseMessage": "The downpour continues.",
"rainClearMessage": "The rain stopped.",
"sandstormStartMessage": "A sandstorm brewed!",
"sandstormLapseMessage": "The sandstorm rages.",
"sandstormClearMessage": "The sandstorm subsided.",
"sandstormDamageMessage": "{{pokemonPrefix}}{{pokemonName}} is buffeted\nby the sandstorm!",
"hailStartMessage": "It started to hail!",
"hailLapseMessage": "Hail continues to fall.",
"hailClearMessage": "The hail stopped.",
"hailDamageMessage": "{{pokemonPrefix}}{{pokemonName}} is pelted\nby the hail!",
"snowStartMessage": "It started to snow!",
"snowLapseMessage": "The snow is falling down.",
"snowClearMessage": "The snow stopped.",
"fogStartMessage": "A thick fog emerged!",
"fogLapseMessage": "The fog continues.",
"fogClearMessage": "The fog disappeared.",
"heavyRainStartMessage": "A heavy downpour started!",
"heavyRainLapseMessage": "The heavy downpour continues.",
"heavyRainClearMessage": "The heavy rain stopped.",
"harshSunStartMessage": "The sunlight got hot!",
"harshSunLapseMessage": "The sun is scorching hot.",
"harshSunClearMessage": "The harsh sunlight faded.",
"strongWindsStartMessage": "A heavy wind began!",
"strongWindsLapseMessage": "The wind blows intensely.",
"strongWindsClearMessage": "The heavy wind stopped."
}

View File

@ -31,6 +31,8 @@ export const battle: SimpleTranslationEntries = {
"learnMoveNotLearned": "{{pokemonName}} não aprendeu {{moveName}}.", "learnMoveNotLearned": "{{pokemonName}} não aprendeu {{moveName}}.",
"learnMoveForgetQuestion": "Qual movimento quer esquecer?", "learnMoveForgetQuestion": "Qual movimento quer esquecer?",
"learnMoveForgetSuccess": "{{pokemonName}} esqueceu como usar {{moveName}}.", "learnMoveForgetSuccess": "{{pokemonName}} esqueceu como usar {{moveName}}.",
"countdownPoof": "@d{32}1, @d{15}2, @d{15}e@d{15}… @d{15}… @d{15}… @d{15}@s{pb_bounce_1}Puf!",
"learnMoveAnd": "E…",
"levelCapUp": "O nível máximo aumentou\npara {{levelCap}}!", "levelCapUp": "O nível máximo aumentou\npara {{levelCap}}!",
"moveNotImplemented": "{{moveName}} ainda não foi implementado e não pode ser usado.", "moveNotImplemented": "{{moveName}} ainda não foi implementado e não pode ser usado.",
"moveNoPP": "Não há mais PP\npara esse movimento!", "moveNoPP": "Não há mais PP\npara esse movimento!",

View File

@ -12,6 +12,7 @@ import { pokemon } from "./pokemon";
import { pokemonStat } from "./pokemon-stat"; import { pokemonStat } from "./pokemon-stat";
import { starterSelectUiHandler } from "./starter-select-ui-handler"; import { starterSelectUiHandler } from "./starter-select-ui-handler";
import { tutorial } from "./tutorial"; import { tutorial } from "./tutorial";
import { weather } from "./weather";
export const ptBrConfig = { export const ptBrConfig = {
@ -28,5 +29,6 @@ export const ptBrConfig = {
starterSelectUiHandler: starterSelectUiHandler, starterSelectUiHandler: starterSelectUiHandler,
tutorial: tutorial, tutorial: tutorial,
nature: nature, nature: nature,
growth: growth growth: growth,
weather: weather
} }

View File

@ -1,23 +1,23 @@
import { SimpleTranslationEntries } from "#app/plugins/i18n"; import { SimpleTranslationEntries } from "#app/plugins/i18n";
export const menuUiHandler: SimpleTranslationEntries = { export const menuUiHandler: SimpleTranslationEntries = {
"GAME_SETTINGS": 'Configurações', "GAME_SETTINGS": "Configurações",
"ACHIEVEMENTS": "Conquistas", "ACHIEVEMENTS": "Conquistas",
"STATS": "Estatísticas", "STATS": "Estatísticas",
"VOUCHERS": "Vouchers", "VOUCHERS": "Vouchers",
"EGG_LIST": "Incubadora", "EGG_LIST": "Incubadora",
"EGG_GACHA": "Gacha de Ovos", "EGG_GACHA": "Gacha de ovos",
"MANAGE_DATA": "Gerenciar Dados", "MANAGE_DATA": "Gerenciar dados",
"COMMUNITY": "Comunidade", "COMMUNITY": "Comunidade",
"RETURN_TO_TITLE": "Voltar ao Início", "SAVE_AND_QUIT": "Salvar e sair",
"LOG_OUT": "Logout", "LOG_OUT": "Logout",
"slot": "Slot {{slotNumber}}", "slot": "Slot {{slotNumber}}",
"importSession": "Importar Sessão", "importSession": "Importar sessão",
"importSlotSelect": "Selecione um slot para importar.", "importSlotSelect": "Selecione um slot para importar.",
"exportSession": "Exportar Sessão", "exportSession": "Exportar sessão",
"exportSlotSelect": "Selecione um slot para exportar.", "exportSlotSelect": "Selecione um slot para exportar.",
"importData": "Importar Dados", "importData": "Importar dados",
"exportData": "Exportar Dados", "exportData": "Exportar dados",
"cancel": "Cancelar", "cancel": "Cancelar",
"losingProgressionWarning": "Você vai perder todo o progresso desde o início da batalha. Confirmar?" "losingProgressionWarning": "Você vai perder todo o progresso desde o início da batalha. Confirmar?"
} as const; } as const;

View File

@ -8,7 +8,7 @@ import { SimpleTranslationEntries } from "#app/plugins/i18n";
export const menu: SimpleTranslationEntries = { export const menu: SimpleTranslationEntries = {
"cancel": "Cancelar", "cancel": "Cancelar",
"continue": "Continuar", "continue": "Continuar",
"dailyRun": "Desafio diário (Beta)", "dailyRun": "Desafio Diário (Beta)",
"loadGame": "Carregar Jogo", "loadGame": "Carregar Jogo",
"newGame": "Novo Jogo", "newGame": "Novo Jogo",
"selectGameMode": "Escolha um modo de jogo.", "selectGameMode": "Escolha um modo de jogo.",
@ -35,6 +35,11 @@ export const menu: SimpleTranslationEntries = {
"boyOrGirl": "Você é um menino ou uma menina?", "boyOrGirl": "Você é um menino ou uma menina?",
"boy": "Menino", "boy": "Menino",
"girl": "Menina", "girl": "Menina",
"evolving": "Que?\n{{pokemonName}} tá evoluindo!",
"stoppedEvolving": "{{pokemonName}} parou de evoluir.",
"pauseEvolutionsQuestion": "Gostaria de pausar evoluções para {{pokemonName}}?\nEvoluções podem ser religadas na tela de equipe.",
"evolutionsPaused": "Evoluções foram paradas para {{pokemonName}}.",
"evolutionDone": "Parabéns!\nSeu {{pokemonName}} evolui para {{evolvedPokemonName}}!",
"dailyRankings": "Classificação Diária", "dailyRankings": "Classificação Diária",
"weeklyRankings": "Classificação Semanal", "weeklyRankings": "Classificação Semanal",
"noRankings": "Sem Classificação", "noRankings": "Sem Classificação",

View File

@ -8,7 +8,7 @@ export const nature: SimpleTranslationEntries = {
"Naughty": "Teimosa", "Naughty": "Teimosa",
"Bold": "Corajosa", "Bold": "Corajosa",
"Docile": "Dócil", "Docile": "Dócil",
"Relaxed": "Descontraída", "Relaxed": "Relaxada",
"Impish": "Inquieta", "Impish": "Inquieta",
"Lax": "Relaxada", "Lax": "Relaxada",
"Timid": "Tímida", "Timid": "Tímida",
@ -20,7 +20,7 @@ export const nature: SimpleTranslationEntries = {
"Mild": "Mansa", "Mild": "Mansa",
"Quiet": "Quieta", "Quiet": "Quieta",
"Bashful": "Atrapalhada", "Bashful": "Atrapalhada",
"Rash": "Imprudente", "Rash": "Rabugenta",
"Calm": "Calma", "Calm": "Calma",
"Gentle": "Gentil", "Gentle": "Gentil",
"Sassy": "Atrevida", "Sassy": "Atrevida",

View File

@ -7,10 +7,19 @@ import { SimpleTranslationEntries } from "#app/plugins/i18n";
*/ */
export const starterSelectUiHandler: SimpleTranslationEntries = { export const starterSelectUiHandler: SimpleTranslationEntries = {
"confirmStartTeam": 'Começar com esses Pokémon?', "confirmStartTeam": 'Começar com esses Pokémon?',
"gen1": "I",
"gen2": "II",
"gen3": "III",
"gen4": "IV",
"gen5": "V",
"gen6": "VI",
"gen7": "VII",
"gen8": "VIII",
"gen9": "IX",
"growthRate": "Crescimento:", "growthRate": "Crescimento:",
"ability": "Hab.:", "ability": "Habilidade:",
"passive": "Passiva:", "passive": "Passiva:",
"nature": "Nature:", "nature": "Natureza:",
"eggMoves": "Mov. de Ovo", "eggMoves": "Mov. de Ovo",
"start": "Iniciar", "start": "Iniciar",
"addToParty": "Adicionar à equipe", "addToParty": "Adicionar à equipe",
@ -25,11 +34,11 @@ export const starterSelectUiHandler: SimpleTranslationEntries = {
"cycleForm": 'F: Mudar Forma', "cycleForm": 'F: Mudar Forma',
"cycleGender": 'G: Mudar Gênero', "cycleGender": 'G: Mudar Gênero',
"cycleAbility": 'E: Mudar Habilidade', "cycleAbility": 'E: Mudar Habilidade',
"cycleNature": 'N: Mudar Nature', "cycleNature": 'N: Mudar Natureza',
"cycleVariant": 'V: Mudar Variante', "cycleVariant": 'V: Mudar Variante',
"enablePassive": "Ativar Passiva", "enablePassive": "Ativar Passiva",
"disablePassive": "Desativar Passiva", "disablePassive": "Desativar Passiva",
"locked": "Bloqueado", "locked": "Bloqueada",
"disabled": "Desativado", "disabled": "Desativada",
"uncaught": "Não capturado" "uncaught": "Não capturado"
} }

View File

@ -0,0 +1,44 @@
import { SimpleTranslationEntries } from "#app/plugins/i18n";
/**
* The weather namespace holds text displayed when weather is active during a battle
*/
export const weather: SimpleTranslationEntries = {
"sunnyStartMessage": "A luz do sol ficou clara!",
"sunnyLapseMessage": "A luz do sol está forte.",
"sunnyClearMessage": "A luz do sol sumiu.",
"rainStartMessage": "Começou a chover!",
"rainLapseMessage": "A chuva continua forte.",
"rainClearMessage": "A chuva parou.",
"sandstormStartMessage": "Uma tempestade de areia se formou!",
"sandstormLapseMessage": "A tempestade de areia é violenta.",
"sandstormClearMessage": "A tempestade de areia diminuiu.",
"sandstormDamageMessage": "{{pokemonPrefix}}{{pokemonName}} é atingido\npela tempestade de areia!",
"hailStartMessage": "Começou a chover granizo!",
"hailLapseMessage": "Granizo cai do céu.",
"hailClearMessage": "O granizo parou.",
"hailDamageMessage": "{{pokemonPrefix}}{{pokemonName}} é atingido\npelo granizo!",
"snowStartMessage": "Começou a nevar!",
"snowLapseMessage": "A neve continua caindo.",
"snowClearMessage": "Parou de nevar.",
"fogStartMessage": "Uma névoa densa se formou!",
"fogLapseMessage": "A névoa continua forte.",
"fogClearMessage": "A névoa sumiu.",
"heavyRainStartMessage": "Um temporal começou!",
"heavyRainLapseMessage": "O temporal continua forte.",
"heavyRainClearMessage": "O temporal parou.",
"harshSunStartMessage": "A luz do sol está escaldante!",
"harshSunLapseMessage": "A luz do sol é intensa.",
"harshSunClearMessage": "A luz do sol enfraqueceu.",
"strongWindsStartMessage": "Ventos fortes apareceram!",
"strongWindsLapseMessage": "Os ventos fortes continuam.",
"strongWindsClearMessage": "Os ventos fortes diminuíram.",
}

View File

@ -31,6 +31,8 @@ export const battle: SimpleTranslationEntries = {
"learnMoveNotLearned": "{{pokemonName}} 没有学会 {{moveName}}。", "learnMoveNotLearned": "{{pokemonName}} 没有学会 {{moveName}}。",
"learnMoveForgetQuestion": "要忘记哪个技能?", "learnMoveForgetQuestion": "要忘记哪个技能?",
"learnMoveForgetSuccess": "{{pokemonName}} 忘记了\n如何使用 {{moveName}}。", "learnMoveForgetSuccess": "{{pokemonName}} 忘记了\n如何使用 {{moveName}}。",
"countdownPoof": "@d{32}1, @d{15}2, @d{15}和@d{15}… @d{15}… @d{15}… @d{15}@s{pb_bounce_1}噗!",
"learnMoveAnd": "和…",
"levelCapUp": "等级上限提升到 {{levelCap}}", "levelCapUp": "等级上限提升到 {{levelCap}}",
"moveNotImplemented": "{{moveName}} 尚未实装,无法选择。", "moveNotImplemented": "{{moveName}} 尚未实装,无法选择。",
"moveNoPP": "这个技能的 PP 用完了", "moveNoPP": "这个技能的 PP 用完了",

View File

@ -12,6 +12,7 @@ import { pokemonStat } from "./pokemon-stat";
import { starterSelectUiHandler } from "./starter-select-ui-handler"; import { starterSelectUiHandler } from "./starter-select-ui-handler";
import { tutorial } from "./tutorial"; import { tutorial } from "./tutorial";
import { nature } from "./nature"; import { nature } from "./nature";
import { weather } from "./weather";
export const zhCnConfig = { export const zhCnConfig = {
@ -29,5 +30,6 @@ export const zhCnConfig = {
starterSelectUiHandler: starterSelectUiHandler, starterSelectUiHandler: starterSelectUiHandler,
tutorial: tutorial, tutorial: tutorial,
nature: nature nature: nature,
weather: weather
} }

View File

@ -9,7 +9,7 @@ export const menuUiHandler: SimpleTranslationEntries = {
"EGG_GACHA": "扭蛋机", "EGG_GACHA": "扭蛋机",
"MANAGE_DATA": "管理数据", "MANAGE_DATA": "管理数据",
"COMMUNITY": "社区", "COMMUNITY": "社区",
"RETURN_TO_TITLE": "返回标题画面", "SAVE_AND_QUIT": "Save and Quit",
"LOG_OUT": "登出", "LOG_OUT": "登出",
"slot": "存档位 {{slotNumber}}", "slot": "存档位 {{slotNumber}}",
"importSession": "导入存档", "importSession": "导入存档",

View File

@ -35,6 +35,11 @@ export const menu: SimpleTranslationEntries = {
"boyOrGirl": "你是男孩还是女孩?", "boyOrGirl": "你是男孩还是女孩?",
"boy": "男孩", "boy": "男孩",
"girl": "女孩", "girl": "女孩",
"evolving": "What?\n{{pokemonName}} is evolving!",
"stoppedEvolving": "{{pokemonName}} stopped evolving.",
"pauseEvolutionsQuestion": "Would you like to pause evolutions for {{pokemonName}}?\nEvolutions can be re-enabled from the party screen.",
"evolutionsPaused": "Evolutions have been paused for {{pokemonName}}.",
"evolutionDone": "Congratulations!\nYour {{pokemonName}} evolved into {{evolvedPokemonName}}!",
"dailyRankings": "每日排名", "dailyRankings": "每日排名",
"weeklyRankings": "每周排名", "weeklyRankings": "每周排名",
"noRankings": "无排名", "noRankings": "无排名",

View File

@ -7,6 +7,15 @@ import { SimpleTranslationEntries } from "#app/plugins/i18n";
*/ */
export const starterSelectUiHandler: SimpleTranslationEntries = { export const starterSelectUiHandler: SimpleTranslationEntries = {
"confirmStartTeam":'使用这些宝可梦开始游戏吗?', "confirmStartTeam":'使用这些宝可梦开始游戏吗?',
"gen1": "I",
"gen2": "II",
"gen3": "III",
"gen4": "IV",
"gen5": "V",
"gen6": "VI",
"gen7": "VII",
"gen8": "VIII",
"gen9": "IX",
"growthRate": "成长速度:", "growthRate": "成长速度:",
"ability": "特性:", "ability": "特性:",
"passive": "被动:", "passive": "被动:",

View File

@ -0,0 +1,44 @@
import { SimpleTranslationEntries } from "#app/plugins/i18n";
/**
* The weather namespace holds text displayed when weather is active during a battle
*/
export const weather: SimpleTranslationEntries = {
"sunnyStartMessage": "The sunlight got bright!",
"sunnyLapseMessage": "The sunlight is strong.",
"sunnyClearMessage": "The sunlight faded.",
"rainStartMessage": "A downpour started!",
"rainLapseMessage": "The downpour continues.",
"rainClearMessage": "The rain stopped.",
"sandstormStartMessage": "A sandstorm brewed!",
"sandstormLapseMessage": "The sandstorm rages.",
"sandstormClearMessage": "The sandstorm subsided.",
"sandstormDamageMessage": "{{pokemonPrefix}}{{pokemonName}} is buffeted\nby the sandstorm!",
"hailStartMessage": "It started to hail!",
"hailLapseMessage": "Hail continues to fall.",
"hailClearMessage": "The hail stopped.",
"hailDamageMessage": "{{pokemonPrefix}}{{pokemonName}} is pelted\nby the hail!",
"snowStartMessage": "It started to snow!",
"snowLapseMessage": "The snow is falling down.",
"snowClearMessage": "The snow stopped.",
"fogStartMessage": "A thick fog emerged!",
"fogLapseMessage": "The fog continues.",
"fogClearMessage": "The fog disappeared.",
"heavyRainStartMessage": "A heavy downpour started!",
"heavyRainLapseMessage": "The heavy downpour continues.",
"heavyRainClearMessage": "The heavy rain stopped.",
"harshSunStartMessage": "The sunlight got hot!",
"harshSunLapseMessage": "The sun is scorching hot.",
"harshSunClearMessage": "The harsh sunlight faded.",
"strongWindsStartMessage": "A heavy wind began!",
"strongWindsLapseMessage": "The wind blows intensely.",
"strongWindsClearMessage": "The heavy wind stopped."
}

View File

@ -925,6 +925,9 @@ export const modifierTypes = {
FOCUS_BAND: () => new PokemonHeldItemModifierType('Focus Band', 'Adds a 10% chance to survive with 1 HP after being damaged enough to faint', FOCUS_BAND: () => new PokemonHeldItemModifierType('Focus Band', 'Adds a 10% chance to survive with 1 HP after being damaged enough to faint',
(type, args) => new Modifiers.SurviveDamageModifier(type, (args[0] as Pokemon).id)), (type, args) => new Modifiers.SurviveDamageModifier(type, (args[0] as Pokemon).id)),
QUICK_CLAW: () => new PokemonHeldItemModifierType('Quick Claw', 'Adds a 10% chance to move first regardless of speed (after priority)',
(type, args) => new Modifiers.BypassSpeedChanceModifier(type, (args[0] as Pokemon).id)),
KINGS_ROCK: () => new PokemonHeldItemModifierType('King\'s Rock', 'Adds a 10% chance an attack move will cause the opponent to flinch', KINGS_ROCK: () => new PokemonHeldItemModifierType('King\'s Rock', 'Adds a 10% chance an attack move will cause the opponent to flinch',
(type, args) => new Modifiers.FlinchChanceModifier(type, (args[0] as Pokemon).id)), (type, args) => new Modifiers.FlinchChanceModifier(type, (args[0] as Pokemon).id)),
@ -1087,6 +1090,7 @@ const modifierPool: ModifierPool = {
new WeightedModifierType(modifierTypes.SOOTHE_BELL, 4), new WeightedModifierType(modifierTypes.SOOTHE_BELL, 4),
new WeightedModifierType(modifierTypes.ABILITY_CHARM, 6), new WeightedModifierType(modifierTypes.ABILITY_CHARM, 6),
new WeightedModifierType(modifierTypes.FOCUS_BAND, 5), new WeightedModifierType(modifierTypes.FOCUS_BAND, 5),
new WeightedModifierType(modifierTypes.QUICK_CLAW, 3),
new WeightedModifierType(modifierTypes.KINGS_ROCK, 3), new WeightedModifierType(modifierTypes.KINGS_ROCK, 3),
new WeightedModifierType(modifierTypes.LOCK_CAPSULE, 3), new WeightedModifierType(modifierTypes.LOCK_CAPSULE, 3),
new WeightedModifierType(modifierTypes.SUPER_EXP_CHARM, 10), new WeightedModifierType(modifierTypes.SUPER_EXP_CHARM, 10),
@ -1138,6 +1142,7 @@ const trainerModifierPool: ModifierPool = {
new WeightedModifierType(modifierTypes.REVIVER_SEED, 2), new WeightedModifierType(modifierTypes.REVIVER_SEED, 2),
new WeightedModifierType(modifierTypes.FOCUS_BAND, 2), new WeightedModifierType(modifierTypes.FOCUS_BAND, 2),
new WeightedModifierType(modifierTypes.LUCKY_EGG, 4), new WeightedModifierType(modifierTypes.LUCKY_EGG, 4),
new WeightedModifierType(modifierTypes.QUICK_CLAW, 1),
new WeightedModifierType(modifierTypes.GRIP_CLAW, 1), new WeightedModifierType(modifierTypes.GRIP_CLAW, 1),
new WeightedModifierType(modifierTypes.WIDE_LENS, 1), new WeightedModifierType(modifierTypes.WIDE_LENS, 1),
].map(m => { m.setTier(ModifierTier.ROGUE); return m; }), ].map(m => { m.setTier(ModifierTier.ROGUE); return m; }),
@ -1198,6 +1203,7 @@ const dailyStarterModifierPool: ModifierPool = {
new WeightedModifierType(modifierTypes.GRIP_CLAW, 5), new WeightedModifierType(modifierTypes.GRIP_CLAW, 5),
new WeightedModifierType(modifierTypes.BATON, 2), new WeightedModifierType(modifierTypes.BATON, 2),
new WeightedModifierType(modifierTypes.FOCUS_BAND, 5), new WeightedModifierType(modifierTypes.FOCUS_BAND, 5),
new WeightedModifierType(modifierTypes.QUICK_CLAW, 3),
new WeightedModifierType(modifierTypes.KINGS_ROCK, 3), new WeightedModifierType(modifierTypes.KINGS_ROCK, 3),
].map(m => { m.setTier(ModifierTier.ROGUE); return m; }), ].map(m => { m.setTier(ModifierTier.ROGUE); return m; }),
[ModifierTier.MASTER]: [ [ModifierTier.MASTER]: [

View File

@ -731,6 +731,40 @@ export class SurviveDamageModifier extends PokemonHeldItemModifier {
} }
} }
export class BypassSpeedChanceModifier extends PokemonHeldItemModifier {
constructor(type: ModifierType, pokemonId: integer, stackCount?: integer) {
super(type, pokemonId, stackCount);
}
matchType(modifier: Modifier) {
return modifier instanceof BypassSpeedChanceModifier;
}
clone() {
return new BypassSpeedChanceModifier(this.type, this.pokemonId, this.stackCount);
}
shouldApply(args: any[]): boolean {
return super.shouldApply(args) && args.length === 2 && args[1] instanceof Utils.BooleanHolder;
}
apply(args: any[]): boolean {
const pokemon = args[0] as Pokemon;
const bypassSpeed = args[1] as Utils.BooleanHolder;
if (!bypassSpeed.value && pokemon.randSeedInt(10) < this.getStackCount()) {
bypassSpeed.value = true;
return true;
}
return false;
}
getMaxHeldItemCount(pokemon: Pokemon): integer {
return 3;
}
}
export class FlinchChanceModifier extends PokemonHeldItemModifier { export class FlinchChanceModifier extends PokemonHeldItemModifier {
constructor(type: ModifierType, pokemonId: integer, stackCount?: integer) { constructor(type: ModifierType, pokemonId: integer, stackCount?: integer) {
super(type, pokemonId, stackCount); super(type, pokemonId, stackCount);

View File

@ -6,7 +6,7 @@ import { allMoves, applyMoveAttrs, BypassSleepAttr, ChargeAttr, applyFilteredMov
import { Mode } from './ui/ui'; import { Mode } from './ui/ui';
import { Command } from "./ui/command-ui-handler"; import { Command } from "./ui/command-ui-handler";
import { Stat } from "./data/pokemon-stat"; import { Stat } from "./data/pokemon-stat";
import { BerryModifier, ContactHeldItemTransferChanceModifier, EnemyAttackStatusEffectChanceModifier, EnemyPersistentModifier, EnemyStatusEffectHealChanceModifier, EnemyTurnHealModifier, ExpBalanceModifier, ExpBoosterModifier, ExpShareModifier, ExtraModifierModifier, FlinchChanceModifier, FusePokemonModifier, HealingBoosterModifier, HitHealModifier, LapsingPersistentModifier, MapModifier, Modifier, MultipleParticipantExpBonusModifier, PersistentModifier, PokemonExpBoosterModifier, PokemonHeldItemModifier, PokemonInstantReviveModifier, SwitchEffectTransferModifier, TempBattleStatBoosterModifier, TurnHealModifier, TurnHeldItemTransferModifier, MoneyMultiplierModifier, MoneyInterestModifier, IvScannerModifier, LapsingPokemonHeldItemModifier, PokemonMultiHitModifier, PokemonMoveAccuracyBoosterModifier, overrideModifiers, overrideHeldItems } from "./modifier/modifier"; import { BerryModifier, ContactHeldItemTransferChanceModifier, EnemyAttackStatusEffectChanceModifier, EnemyPersistentModifier, EnemyStatusEffectHealChanceModifier, EnemyTurnHealModifier, ExpBalanceModifier, ExpBoosterModifier, ExpShareModifier, ExtraModifierModifier, FlinchChanceModifier, FusePokemonModifier, HealingBoosterModifier, HitHealModifier, LapsingPersistentModifier, MapModifier, Modifier, MultipleParticipantExpBonusModifier, PersistentModifier, PokemonExpBoosterModifier, PokemonHeldItemModifier, PokemonInstantReviveModifier, SwitchEffectTransferModifier, TempBattleStatBoosterModifier, TurnHealModifier, TurnHeldItemTransferModifier, MoneyMultiplierModifier, MoneyInterestModifier, IvScannerModifier, LapsingPokemonHeldItemModifier, PokemonMultiHitModifier, PokemonMoveAccuracyBoosterModifier, overrideModifiers, overrideHeldItems, BypassSpeedChanceModifier } from "./modifier/modifier";
import PartyUiHandler, { PartyOption, PartyUiMode } from "./ui/party-ui-handler"; import PartyUiHandler, { PartyOption, PartyUiMode } from "./ui/party-ui-handler";
import { doPokeballBounceAnim, getPokeballAtlasKey, getPokeballCatchMultiplier, getPokeballTintColor, PokeballType } from "./data/pokeball"; import { doPokeballBounceAnim, getPokeballAtlasKey, getPokeballCatchMultiplier, getPokeballTintColor, PokeballType } from "./data/pokeball";
import { CommonAnim, CommonBattleAnim, MoveAnim, initMoveAnim, loadMoveAnimAssets } from "./data/battle-anims"; import { CommonAnim, CommonBattleAnim, MoveAnim, initMoveAnim, loadMoveAnimAssets } from "./data/battle-anims";
@ -1970,6 +1970,14 @@ export class TurnStartPhase extends FieldPhase {
const field = this.scene.getField(); const field = this.scene.getField();
const order = this.getOrder(); const order = this.getOrder();
const battlerBypassSpeed = {};
this.scene.getField(true).filter(p => p.summonData).map(p => {
const bypassSpeed = new Utils.BooleanHolder(false);
this.scene.applyModifiers(BypassSpeedChanceModifier, p.isPlayer(), p, bypassSpeed);
battlerBypassSpeed[p.getBattlerIndex()] = bypassSpeed;
});
const moveOrder = order.slice(0); const moveOrder = order.slice(0);
moveOrder.sort((a, b) => { moveOrder.sort((a, b) => {
@ -1995,6 +2003,9 @@ export class TurnStartPhase extends FieldPhase {
return aPriority.value < bPriority.value ? 1 : -1; return aPriority.value < bPriority.value ? 1 : -1;
} }
if (battlerBypassSpeed[a].value !== battlerBypassSpeed[b].value)
return battlerBypassSpeed[a].value ? -1 : 1;
const aIndex = order.indexOf(a); const aIndex = order.indexOf(a);
const bIndex = order.indexOf(b); const bIndex = order.indexOf(b);
@ -3956,9 +3967,9 @@ export class LearnMovePhase extends PlayerPartyMemberPokemonPhase {
return; return;
} }
this.scene.ui.setMode(messageMode).then(() => { this.scene.ui.setMode(messageMode).then(() => {
this.scene.ui.showText('@d{32}1, @d{15}2, and@d{15}… @d{15}… @d{15}… @d{15}@s{pb_bounce_1}Poof!', null, () => { this.scene.ui.showText(i18next.t('battle:countdownPoof'), null, () => {
this.scene.ui.showText(i18next.t('battle:learnMoveForgetSuccess', { pokemonName: pokemon.name, moveName: pokemon.moveset[moveIndex].getName() }), null, () => { this.scene.ui.showText(i18next.t('battle:learnMoveForgetSuccess', { pokemonName: pokemon.name, moveName: pokemon.moveset[moveIndex].getName() }), null, () => {
this.scene.ui.showText('And', null, () => { this.scene.ui.showText(i18next.t('battle:learnMoveAnd'), null, () => {
pokemon.setMove(moveIndex, Moves.NONE); pokemon.setMove(moveIndex, Moves.NONE);
this.scene.unshiftPhase(new LearnMovePhase(this.scene, this.partyMemberIndex, this.moveId)); this.scene.unshiftPhase(new LearnMovePhase(this.scene, this.partyMemberIndex, this.moveId));
this.end(); this.end();

View File

@ -110,6 +110,7 @@ declare module 'i18next' {
starterSelectUiHandler: SimpleTranslationEntries; starterSelectUiHandler: SimpleTranslationEntries;
nature: SimpleTranslationEntries; nature: SimpleTranslationEntries;
growth: SimpleTranslationEntries; growth: SimpleTranslationEntries;
weather: SimpleTranslationEntries;
}; };
} }
} }

View File

@ -355,16 +355,18 @@ export class GameData {
if (cachedSystemDataStr) { if (cachedSystemDataStr) {
let cachedSystemData = this.parseSystemData(cachedSystemDataStr); let cachedSystemData = this.parseSystemData(cachedSystemDataStr);
console.log(cachedSystemData.timestamp, systemData.timestamp)
if (cachedSystemData.timestamp > systemData.timestamp) { if (cachedSystemData.timestamp > systemData.timestamp) {
console.debug('Use cached system'); console.debug('Use cached system');
systemData = cachedSystemData; systemData = cachedSystemData;
systemDataStr = cachedSystemDataStr;
} else } else
this.clearLocalData(); this.clearLocalData();
} }
console.debug(systemData); console.debug(systemData);
localStorage.setItem(`data_${loggedInUser.username}`, encrypt(systemDataStr, bypassLogin));
/*const versions = [ this.scene.game.config.gameVersion, data.gameVersion || '0.0.0' ]; /*const versions = [ this.scene.game.config.gameVersion, data.gameVersion || '0.0.0' ];
if (versions[0] !== versions[1]) { if (versions[0] !== versions[1]) {
@ -879,7 +881,7 @@ export class GameData {
}) as SessionSaveData; }) as SessionSaveData;
} }
saveAll(scene: BattleScene, skipVerification: boolean = false, sync: boolean = false, useCachedSession: boolean = false): Promise<boolean> { saveAll(scene: BattleScene, skipVerification: boolean = false, sync: boolean = false, useCachedSession: boolean = false, useCachedSystem: boolean = false): Promise<boolean> {
return new Promise<boolean>(resolve => { return new Promise<boolean>(resolve => {
Utils.executeIf(!skipVerification, updateUserInfo).then(success => { Utils.executeIf(!skipVerification, updateUserInfo).then(success => {
if (success !== null && !success) if (success !== null && !success)
@ -889,7 +891,7 @@ export class GameData {
const sessionData = useCachedSession ? this.parseSessionData(decrypt(localStorage.getItem(`sessionData${scene.sessionSlotId ? scene.sessionSlotId : ''}_${loggedInUser.username}`), bypassLogin)) : this.getSessionSaveData(scene); const sessionData = useCachedSession ? this.parseSessionData(decrypt(localStorage.getItem(`sessionData${scene.sessionSlotId ? scene.sessionSlotId : ''}_${loggedInUser.username}`), bypassLogin)) : this.getSessionSaveData(scene);
const maxIntAttrValue = Math.pow(2, 31); const maxIntAttrValue = Math.pow(2, 31);
const systemData = this.getSystemSaveData(); const systemData = useCachedSystem ? this.parseSystemData(decrypt(localStorage.getItem(`data_${loggedInUser.username}`), bypassLogin)) : this.getSystemSaveData();
const request = { const request = {
system: systemData, system: systemData,

View File

@ -20,7 +20,7 @@ export enum MenuOptions {
EGG_GACHA, EGG_GACHA,
MANAGE_DATA, MANAGE_DATA,
COMMUNITY, COMMUNITY,
RETURN_TO_TITLE, SAVE_AND_QUIT,
LOG_OUT LOG_OUT
} }
@ -297,15 +297,18 @@ export default class MenuUiHandler extends MessageUiHandler {
ui.setOverlayMode(Mode.MENU_OPTION_SELECT, this.communityConfig); ui.setOverlayMode(Mode.MENU_OPTION_SELECT, this.communityConfig);
success = true; success = true;
break; break;
case MenuOptions.RETURN_TO_TITLE: case MenuOptions.SAVE_AND_QUIT:
if (this.scene.currentBattle) { if (this.scene.currentBattle) {
success = true; success = true;
if (this.scene.currentBattle.turn > 1) {
ui.showText(i18next.t("menuUiHandler:losingProgressionWarning"), null, () => { ui.showText(i18next.t("menuUiHandler:losingProgressionWarning"), null, () => {
ui.setOverlayMode(Mode.CONFIRM, () => this.scene.reset(true), () => { ui.setOverlayMode(Mode.CONFIRM, () => this.scene.gameData.saveAll(this.scene, true, true, true, true).then(() => this.scene.reset(true)), () => {
ui.revertMode(); ui.revertMode();
ui.showText(null, 0); ui.showText(null, 0);
}, false, -98); }, false, -98);
}); });
} else
this.scene.gameData.saveAll(this.scene, true, true, true, true).then(() => this.scene.reset(true));
} else } else
error = true; error = true;
break; break;

View File

@ -86,7 +86,17 @@ function getValueReductionCandyCounts(baseValue: integer): [integer, integer] {
} }
} }
const gens = [ 'I', 'II', 'III', 'IV', 'V', 'VI', 'VII', 'VIII', 'IX' ]; const gens = [
i18next.t("starterSelectUiHandler:gen1"),
i18next.t("starterSelectUiHandler:gen2"),
i18next.t("starterSelectUiHandler:gen3"),
i18next.t("starterSelectUiHandler:gen4"),
i18next.t("starterSelectUiHandler:gen5"),
i18next.t("starterSelectUiHandler:gen6"),
i18next.t("starterSelectUiHandler:gen7"),
i18next.t("starterSelectUiHandler:gen8"),
i18next.t("starterSelectUiHandler:gen9")
];
export default class StarterSelectUiHandler extends MessageUiHandler { export default class StarterSelectUiHandler extends MessageUiHandler {
private starterSelectContainer: Phaser.GameObjects.Container; private starterSelectContainer: Phaser.GameObjects.Container;
@ -245,30 +255,54 @@ export default class StarterSelectUiHandler extends MessageUiHandler {
this.pokemonUncaughtText.setOrigin(0, 0); this.pokemonUncaughtText.setOrigin(0, 0);
this.starterSelectContainer.add(this.pokemonUncaughtText); this.starterSelectContainer.add(this.pokemonUncaughtText);
this.pokemonAbilityLabelText = addTextObject(this.scene, 6, 127, i18next.t("starterSelectUiHandler:ability"), TextStyle.SUMMARY_ALT, { fontSize: '56px' }); let starterInfoXPosition = 31; // Only text
// The position should be set per language
const currentLanguage = i18next.language;
switch (currentLanguage) {
case 'pt_BR':
starterInfoXPosition = 32;
break;
default:
starterInfoXPosition = 31;
break
}
let starterInfoTextSize = '56px'; // Labels and text
// The font size should be set per language
// currentLanguage is already defined
switch (currentLanguage) {
case 'pt_BR':
starterInfoTextSize = '47px';
break;
default:
starterInfoTextSize = '56px';
break
}
this.pokemonAbilityLabelText = addTextObject(this.scene, 6, 127, i18next.t("starterSelectUiHandler:ability"), TextStyle.SUMMARY_ALT, { fontSize: starterInfoTextSize });
this.pokemonAbilityLabelText.setOrigin(0, 0); this.pokemonAbilityLabelText.setOrigin(0, 0);
this.pokemonAbilityLabelText.setVisible(false); this.pokemonAbilityLabelText.setVisible(false);
this.starterSelectContainer.add(this.pokemonAbilityLabelText); this.starterSelectContainer.add(this.pokemonAbilityLabelText);
this.pokemonAbilityText = addTextObject(this.scene, 31, 127, '', TextStyle.SUMMARY_ALT, { fontSize: '56px' }); this.pokemonAbilityText = addTextObject(this.scene, starterInfoXPosition, 127, '', TextStyle.SUMMARY_ALT, { fontSize: starterInfoTextSize });
this.pokemonAbilityText.setOrigin(0, 0); this.pokemonAbilityText.setOrigin(0, 0);
this.starterSelectContainer.add(this.pokemonAbilityText); this.starterSelectContainer.add(this.pokemonAbilityText);
this.pokemonPassiveLabelText = addTextObject(this.scene, 6, 136, i18next.t("starterSelectUiHandler:passive"), TextStyle.SUMMARY_ALT, { fontSize: '56px' }); this.pokemonPassiveLabelText = addTextObject(this.scene, 6, 136, i18next.t("starterSelectUiHandler:passive"), TextStyle.SUMMARY_ALT, { fontSize: starterInfoTextSize });
this.pokemonPassiveLabelText.setOrigin(0, 0); this.pokemonPassiveLabelText.setOrigin(0, 0);
this.pokemonPassiveLabelText.setVisible(false); this.pokemonPassiveLabelText.setVisible(false);
this.starterSelectContainer.add(this.pokemonPassiveLabelText); this.starterSelectContainer.add(this.pokemonPassiveLabelText);
this.pokemonPassiveText = addTextObject(this.scene, 31, 136, '', TextStyle.SUMMARY_ALT, { fontSize: '56px' }); this.pokemonPassiveText = addTextObject(this.scene, starterInfoXPosition, 136, '', TextStyle.SUMMARY_ALT, { fontSize: starterInfoTextSize });
this.pokemonPassiveText.setOrigin(0, 0); this.pokemonPassiveText.setOrigin(0, 0);
this.starterSelectContainer.add(this.pokemonPassiveText); this.starterSelectContainer.add(this.pokemonPassiveText);
this.pokemonNatureLabelText = addTextObject(this.scene, 6, 145, i18next.t("starterSelectUiHandler:nature"), TextStyle.SUMMARY_ALT, { fontSize: '56px' }); this.pokemonNatureLabelText = addTextObject(this.scene, 6, 145, i18next.t("starterSelectUiHandler:nature"), TextStyle.SUMMARY_ALT, { fontSize: starterInfoTextSize });
this.pokemonNatureLabelText.setOrigin(0, 0); this.pokemonNatureLabelText.setOrigin(0, 0);
this.pokemonNatureLabelText.setVisible(false); this.pokemonNatureLabelText.setVisible(false);
this.starterSelectContainer.add(this.pokemonNatureLabelText); this.starterSelectContainer.add(this.pokemonNatureLabelText);
this.pokemonNatureText = addBBCodeTextObject(this.scene, 31, 145, '', TextStyle.SUMMARY_ALT, { fontSize: '56px' }); this.pokemonNatureText = addBBCodeTextObject(this.scene, starterInfoXPosition, 145, '', TextStyle.SUMMARY_ALT, { fontSize: starterInfoTextSize });
this.pokemonNatureText.setOrigin(0, 0); this.pokemonNatureText.setOrigin(0, 0);
this.starterSelectContainer.add(this.pokemonNatureText); this.starterSelectContainer.add(this.pokemonNatureText);
@ -556,8 +590,11 @@ export default class StarterSelectUiHandler extends MessageUiHandler {
let instructionTextSize = '42px'; let instructionTextSize = '42px';
// The font size should be set per language // The font size should be set per language
const currentLanguage = i18next.language; // currentLanguage is already defined in the previous code block
switch (currentLanguage) { switch (currentLanguage) {
case 'de':
instructionTextSize = '35px';
break;
case 'en': case 'en':
instructionTextSize = '42px'; instructionTextSize = '42px';
break; break;
@ -567,12 +604,12 @@ export default class StarterSelectUiHandler extends MessageUiHandler {
case 'fr': case 'fr':
instructionTextSize = '42px'; instructionTextSize = '42px';
break; break;
case 'de':
instructionTextSize = '35px';
break;
case 'it': case 'it':
instructionTextSize = '38px'; instructionTextSize = '38px';
break; break;
case 'pt_BR':
instructionTextSize = '38px';
break;
case 'zh_CN': case 'zh_CN':
instructionTextSize = '42px'; instructionTextSize = '42px';
break; break;
@ -1260,11 +1297,13 @@ export default class StarterSelectUiHandler extends MessageUiHandler {
updateGenOptions(): void { updateGenOptions(): void {
let text = ''; let text = '';
for (let g = this.genScrollCursor; g <= this.genScrollCursor + 2; g++) { for (let g = this.genScrollCursor; g <= this.genScrollCursor + 2; g++) {
let optionText = gens[g]; let optionText = '';
if (g === this.genScrollCursor && this.genScrollCursor) if (g === this.genScrollCursor && this.genScrollCursor)
optionText = '↑'; optionText = '↑';
else if (g === this.genScrollCursor + 2 && this.genScrollCursor < gens.length - 3) else if (g === this.genScrollCursor + 2 && this.genScrollCursor < gens.length - 3)
optionText = '↓' optionText = '↓'
else
optionText = i18next.t(`starterSelectUiHandler:gen${g + 1}`);
text += `${text ? '\n' : ''}${optionText}`; text += `${text ? '\n' : ''}${optionText}`;
} }
this.genOptionsText.setText(text); this.genOptionsText.setText(text);