Revert "[QoL] Reorganize Enum Locations (#2142)"

This reverts commit cf06ff3b8d.
This commit is contained in:
Matthew Olker 2024-06-13 11:30:47 -04:00
parent 35eb4c36a2
commit e6c24dceab
150 changed files with 327 additions and 214 deletions

View File

@ -53,8 +53,6 @@
"node": ">=20.0.0" "node": ">=20.0.0"
}, },
"imports": { "imports": {
"#enums": "./enums",
"#enums/*": "./enums/*",
"#app": "./src/main.js", "#app": "./src/main.js",
"#app/*": "./src/*", "#app/*": "./src/*",
"#test/*": "./src/test/*" "#test/*": "./src/test/*"

View File

@ -1,6 +1,6 @@
import re import re
filenames = [['src/enums/moves.ts', 'move'], ['src/enums/abilities.ts', 'ability'], ['src/enums/species.ts', 'Pokémon']] filenames = [['src/data/enums/moves.ts', 'move'], ['src/data/enums/abilities.ts', 'ability'], ['src/data/enums/species.ts', 'Pokémon']]
commentBlockStart = re.compile('\/\*[^\*].*') # Regex for the start of a comment block commentBlockStart = re.compile('\/\*[^\*].*') # Regex for the start of a comment block
commentBlockEnd = re.compile('.*,\*\/') # Regex for the end of a comment block commentBlockEnd = re.compile('.*,\*\/') # Regex for the end of a comment block

View File

@ -9,9 +9,12 @@ import { PokeballType } from "./data/pokeball";
import { initCommonAnims, initMoveAnim, loadCommonAnimAssets, loadMoveAnimAssets, populateAnims } from "./data/battle-anims"; import { initCommonAnims, initMoveAnim, loadCommonAnimAssets, loadMoveAnimAssets, populateAnims } from "./data/battle-anims";
import { Phase } from "./phase"; import { Phase } from "./phase";
import { initGameSpeed } from "./system/game-speed"; import { initGameSpeed } from "./system/game-speed";
import { Biome } from "./data/enums/biome";
import { Arena, ArenaBase } from "./field/arena"; import { Arena, ArenaBase } from "./field/arena";
import { GameData } from "./system/game-data"; import { GameData } from "./system/game-data";
import { PlayerGender } from "./data/enums/player-gender";
import { TextStyle, addTextObject, getTextColor } from "./ui/text"; import { TextStyle, addTextObject, getTextColor } from "./ui/text";
import { Moves } from "./data/enums/moves";
import { allMoves } from "./data/move"; import { allMoves } from "./data/move";
import { ModifierPoolType, getDefaultModifierTypeForTier, getEnemyModifierTypesForWave, getLuckString, getLuckTextTint, getModifierPoolForType, getPartyLuckValue } from "./modifier/modifier-type"; import { ModifierPoolType, getDefaultModifierTypeForTier, getEnemyModifierTypesForWave, getLuckString, getLuckTextTint, getModifierPoolForType, getPartyLuckValue } from "./modifier/modifier-type";
import AbilityBar from "./ui/ability-bar"; import AbilityBar from "./ui/ability-bar";
@ -28,6 +31,7 @@ import TrainerData from "./system/trainer-data";
import SoundFade from "phaser3-rex-plugins/plugins/soundfade"; import SoundFade from "phaser3-rex-plugins/plugins/soundfade";
import { pokemonPrevolutions } from "./data/pokemon-evolutions"; import { pokemonPrevolutions } from "./data/pokemon-evolutions";
import PokeballTray from "./ui/pokeball-tray"; import PokeballTray from "./ui/pokeball-tray";
import { Species } from "./data/enums/species";
import InvertPostFX from "./pipelines/invert"; import InvertPostFX from "./pipelines/invert";
import { Achv, ModifierAchv, MoneyAchv, achvs } from "./system/achv"; import { Achv, ModifierAchv, MoneyAchv, achvs } from "./system/achv";
import { Voucher, vouchers } from "./system/voucher"; import { Voucher, vouchers } from "./system/voucher";
@ -38,12 +42,14 @@ import PokemonData from "./system/pokemon-data";
import { Nature } from "./data/nature"; import { Nature } from "./data/nature";
import { SpeciesFormChangeTimeOfDayTrigger, SpeciesFormChangeTrigger, pokemonFormChanges } from "./data/pokemon-forms"; import { SpeciesFormChangeTimeOfDayTrigger, SpeciesFormChangeTrigger, pokemonFormChanges } from "./data/pokemon-forms";
import { FormChangePhase, QuietFormChangePhase } from "./form-change-phase"; import { FormChangePhase, QuietFormChangePhase } from "./form-change-phase";
import { BattleSpec } from "./enums/battle-spec";
import { getTypeRgb } from "./data/type"; import { getTypeRgb } from "./data/type";
import PokemonSpriteSparkleHandler from "./field/pokemon-sprite-sparkle-handler"; import PokemonSpriteSparkleHandler from "./field/pokemon-sprite-sparkle-handler";
import CharSprite from "./ui/char-sprite"; import CharSprite from "./ui/char-sprite";
import DamageNumberHandler from "./field/damage-number-handler"; import DamageNumberHandler from "./field/damage-number-handler";
import PokemonInfoContainer from "./ui/pokemon-info-container"; import PokemonInfoContainer from "./ui/pokemon-info-container";
import { biomeDepths, getBiomeName } from "./data/biomes"; import { biomeDepths, getBiomeName } from "./data/biomes";
import { UiTheme } from "./enums/ui-theme";
import { SceneBase } from "./scene-base"; import { SceneBase } from "./scene-base";
import CandyBar from "./ui/candy-bar"; import CandyBar from "./ui/candy-bar";
import { Variant, variantData } from "./data/variant"; import { Variant, variantData } from "./data/variant";
@ -51,9 +57,13 @@ import { Localizable } from "./plugins/i18n";
import * as Overrides from "./overrides"; import * as Overrides from "./overrides";
import {InputsController} from "./inputs-controller"; import {InputsController} from "./inputs-controller";
import {UiInputs} from "./ui-inputs"; import {UiInputs} from "./ui-inputs";
import { MoneyFormat } from "./enums/money-format";
import { NewArenaEvent } from "./events/battle-scene"; import { NewArenaEvent } from "./events/battle-scene";
import { Abilities, BattleSpec, BattleStyle, Biome, EaseType, ExpNotification, MoneyFormat, Moves, PlayerGender, UiTheme, Species} from "#enums"; import { Abilities } from "./data/enums/abilities";
import ArenaFlyout from "./ui/arena-flyout"; import ArenaFlyout from "./ui/arena-flyout";
import { EaseType } from "./ui/enums/ease-type";
import { ExpNotification } from "./enums/exp-notification";
import { BattleStyle } from "./enums/battle-style";
export const bypassLogin = import.meta.env.VITE_BYPASS_LOGIN === "1"; export const bypassLogin = import.meta.env.VITE_BYPASS_LOGIN === "1";

View File

@ -3,8 +3,12 @@ import { EnemyPokemon, PlayerPokemon, QueuedMove } from "./field/pokemon";
import { Command } from "./ui/command-ui-handler"; import { Command } from "./ui/command-ui-handler";
import * as Utils from "./utils"; import * as Utils from "./utils";
import Trainer, { TrainerVariant } from "./field/trainer"; import Trainer, { TrainerVariant } from "./field/trainer";
import { Species } from "./data/enums/species";
import { Moves } from "./data/enums/moves";
import { TrainerType } from "./data/enums/trainer-type";
import { GameMode } from "./game-mode"; import { GameMode } from "./game-mode";
import { BattleSpec, Moves, PlayerGender, Species, TrainerType } from "#enums"; import { BattleSpec } from "./enums/battle-spec";
import { PlayerGender } from "./data/enums/player-gender";
import { MoneyMultiplierModifier, PokemonHeldItemModifier } from "./modifier/modifier"; import { MoneyMultiplierModifier, PokemonHeldItemModifier } from "./modifier/modifier";
import { PokeballType } from "./data/pokeball"; import { PokeballType } from "./data/pokeball";
import {trainerConfigs} from "#app/data/trainer-config"; import {trainerConfigs} from "#app/data/trainer-config";

View File

@ -1,4 +1,4 @@
import {Button} from "#enums"; import {Button} from "#app/enums/buttons";
import {SettingKeyboard} from "#app/system/settings/settings-keyboard"; import {SettingKeyboard} from "#app/system/settings/settings-keyboard";
const cfg_keyboard_qwerty = { const cfg_keyboard_qwerty = {

View File

@ -1,4 +1,4 @@
import {Device} from "#enums"; import {Device} from "#app/enums/devices";
/** /**
* Retrieves the key associated with the specified keycode from the mapping. * Retrieves the key associated with the specified keycode from the mapping.

View File

@ -1,5 +1,5 @@
import {SettingGamepad} from "../../system/settings/settings-gamepad"; import {SettingGamepad} from "../../system/settings/settings-gamepad";
import {Button} from "#enums"; import {Button} from "../../enums/buttons";
/** /**
* Dualshock mapping * Dualshock mapping

View File

@ -1,5 +1,5 @@
import {SettingGamepad} from "../../system/settings/settings-gamepad"; import {SettingGamepad} from "../../system/settings/settings-gamepad";
import {Button} from "#enums"; import {Button} from "../../enums/buttons";
/** /**
* Generic pad mapping * Generic pad mapping

View File

@ -1,5 +1,5 @@
import {SettingGamepad} from "#app/system/settings/settings-gamepad.js"; import {SettingGamepad} from "#app/system/settings/settings-gamepad.js";
import {Button} from "#enums"; import {Button} from "#app/enums/buttons";
/** /**
* Nintendo Pro Controller mapping * Nintendo Pro Controller mapping

View File

@ -1,5 +1,5 @@
import {SettingGamepad} from "../../system/settings/settings-gamepad"; import {SettingGamepad} from "../../system/settings/settings-gamepad";
import {Button} from "#enums"; import {Button} from "../../enums/buttons";
/** /**
* 081f-e401 - UnlicensedSNES * 081f-e401 - UnlicensedSNES

View File

@ -1,5 +1,5 @@
import {SettingGamepad} from "../../system/settings/settings-gamepad"; import {SettingGamepad} from "../../system/settings/settings-gamepad";
import {Button} from "#enums"; import {Button} from "#app/enums/buttons";
/** /**
* Generic pad mapping * Generic pad mapping

View File

@ -6,19 +6,23 @@ import { MovePhase, PokemonHealPhase, ShowAbilityPhase, StatChangePhase } from "
import { getPokemonMessage, getPokemonNameWithAffix } from "../messages"; import { getPokemonMessage, getPokemonNameWithAffix } from "../messages";
import { Weather, WeatherType } from "./weather"; import { Weather, WeatherType } from "./weather";
import { BattlerTag } from "./battler-tags"; import { BattlerTag } from "./battler-tags";
import { ArenaTagType, Abilities, BattlerTagType, Moves, Species } from "#enums"; import { BattlerTagType } from "./enums/battler-tag-type";
import { StatusEffect, getNonVolatileStatusEffects, getStatusEffectDescriptor, getStatusEffectHealText } from "./status-effect"; import { StatusEffect, getNonVolatileStatusEffects, getStatusEffectDescriptor, getStatusEffectHealText } from "./status-effect";
import { Gender } from "./gender"; import { Gender } from "./gender";
import Move, { AttackMove, MoveCategory, MoveFlags, MoveTarget, FlinchAttr, OneHitKOAttr, HitHealAttr, allMoves, StatusMove, SelfStatusMove, VariablePowerAttr, applyMoveAttrs, IncrementMovePriorityAttr, VariableMoveTypeAttr, RandomMovesetMoveAttr, RandomMoveAttr, NaturePowerAttr, CopyMoveAttr } from "./move"; import Move, { AttackMove, MoveCategory, MoveFlags, MoveTarget, FlinchAttr, OneHitKOAttr, HitHealAttr, allMoves, StatusMove, SelfStatusMove, VariablePowerAttr, applyMoveAttrs, IncrementMovePriorityAttr, VariableMoveTypeAttr, RandomMovesetMoveAttr, RandomMoveAttr, NaturePowerAttr, CopyMoveAttr } from "./move";
import { ArenaTagSide, ArenaTrapTag } from "./arena-tag"; import { ArenaTagSide, ArenaTrapTag } from "./arena-tag";
import { ArenaTagType } from "./enums/arena-tag-type";
import { Stat, getStatName } from "./pokemon-stat"; import { Stat, getStatName } from "./pokemon-stat";
import { BerryModifier, PokemonHeldItemModifier } from "../modifier/modifier"; import { BerryModifier, PokemonHeldItemModifier } from "../modifier/modifier";
import { Moves } from "./enums/moves";
import { TerrainType } from "./terrain"; import { TerrainType } from "./terrain";
import { SpeciesFormChangeManualTrigger } from "./pokemon-forms"; import { SpeciesFormChangeManualTrigger } from "./pokemon-forms";
import { Abilities } from "./enums/abilities";
import i18next, { Localizable } from "#app/plugins/i18n.js"; import i18next, { Localizable } from "#app/plugins/i18n.js";
import { Command } from "../ui/command-ui-handler"; import { Command } from "../ui/command-ui-handler";
import { BerryModifierType } from "#app/modifier/modifier-type"; import { BerryModifierType } from "#app/modifier/modifier-type";
import { getPokeballName } from "./pokeball"; import { getPokeballName } from "./pokeball";
import { Species } from "./enums/species";
import { BattlerIndex } from "#app/battle"; import { BattlerIndex } from "#app/battle";
export class Ability implements Localizable { export class Ability implements Localizable {

View File

@ -6,9 +6,11 @@ import PokemonSpecies, { PokemonForm, SpeciesFormKey, allSpecies } from "./pokem
import { GrowthRate } from "./exp"; import { GrowthRate } from "./exp";
import { Type } from "./type"; import { Type } from "./type";
import { allAbilities } from "./ability"; import { allAbilities } from "./ability";
import { Abilities, Moves, Species } from "#enums"; import { Abilities } from "./enums/abilities";
import { Species } from "./enums/species";
import { pokemonFormLevelMoves } from "./pokemon-level-moves"; import { pokemonFormLevelMoves } from "./pokemon-level-moves";
import { tmSpecies } from "./tms"; import { tmSpecies } from "./tms";
import { Moves } from "./enums/moves";
const targetMap = { const targetMap = {
"specific-move": MoveTarget.ATTACKER, "specific-move": MoveTarget.ATTACKER,

View File

@ -7,10 +7,13 @@ import Pokemon, { HitResult, PokemonMove } from "../field/pokemon";
import { MoveEffectPhase, PokemonHealPhase, ShowAbilityPhase, StatChangePhase} from "../phases"; import { MoveEffectPhase, PokemonHealPhase, ShowAbilityPhase, StatChangePhase} from "../phases";
import { StatusEffect } from "./status-effect"; import { StatusEffect } from "./status-effect";
import { BattlerIndex } from "../battle"; import { BattlerIndex } from "../battle";
import { Abilities, ArenaTagType, BattlerTagType, Moves } from "#enums"; import { Moves } from "./enums/moves";
import { ArenaTagType } from "./enums/arena-tag-type";
import { BlockNonDirectDamageAbAttr, ProtectStatAbAttr, applyAbAttrs } from "./ability"; import { BlockNonDirectDamageAbAttr, ProtectStatAbAttr, applyAbAttrs } from "./ability";
import { BattleStat } from "./battle-stat"; import { BattleStat } from "./battle-stat";
import { CommonAnim, CommonBattleAnim } from "./battle-anims"; import { CommonAnim, CommonBattleAnim } from "./battle-anims";
import { Abilities } from "./enums/abilities";
import { BattlerTagType } from "./enums/battler-tag-type";
import i18next from "i18next"; import i18next from "i18next";
export enum ArenaTagSide { export enum ArenaTagSide {

View File

@ -5,7 +5,7 @@ import Pokemon from "../field/pokemon";
import * as Utils from "../utils"; import * as Utils from "../utils";
import { BattlerIndex } from "../battle"; import { BattlerIndex } from "../battle";
import { Element } from "json-stable-stringify"; import { Element } from "json-stable-stringify";
import { Moves } from "#enums"; import { Moves } from "./enums/moves";
//import fs from 'vite-plugin-fs/browser'; //import fs from 'vite-plugin-fs/browser';
export enum AnimFrameTarget { export enum AnimFrameTarget {

View File

@ -5,15 +5,18 @@ import Pokemon, { MoveResult, HitResult } from "../field/pokemon";
import { Stat, getStatName } from "./pokemon-stat"; import { Stat, getStatName } from "./pokemon-stat";
import { StatusEffect } from "./status-effect"; import { StatusEffect } from "./status-effect";
import * as Utils from "../utils"; import * as Utils from "../utils";
import { Moves } from "./enums/moves";
import { ChargeAttr, MoveFlags, allMoves } from "./move"; import { ChargeAttr, MoveFlags, allMoves } from "./move";
import { Type } from "./type"; import { Type } from "./type";
import { BlockNonDirectDamageAbAttr, FlinchEffectAbAttr, ReverseDrainAbAttr, applyAbAttrs } from "./ability"; import { BlockNonDirectDamageAbAttr, FlinchEffectAbAttr, ReverseDrainAbAttr, applyAbAttrs } from "./ability";
import { Abilities, BattlerTagType, Moves, Species } from "#enums"; import { Abilities } from "./enums/abilities";
import { BattlerTagType } from "./enums/battler-tag-type";
import { TerrainType } from "./terrain"; import { TerrainType } from "./terrain";
import { WeatherType } from "./weather"; import { WeatherType } from "./weather";
import { BattleStat } from "./battle-stat"; import { BattleStat } from "./battle-stat";
import { allAbilities } from "./ability"; import { allAbilities } from "./ability";
import { SpeciesFormChangeManualTrigger } from "./pokemon-forms"; import { SpeciesFormChangeManualTrigger } from "./pokemon-forms";
import { Species } from "./enums/species";
export enum BattlerTagLapseType { export enum BattlerTagLapseType {
FAINT, FAINT,

View File

@ -2,11 +2,12 @@ import { PokemonHealPhase, StatChangePhase } from "../phases";
import { getPokemonMessage } from "../messages"; import { getPokemonMessage } from "../messages";
import Pokemon, { HitResult } from "../field/pokemon"; import Pokemon, { HitResult } from "../field/pokemon";
import { BattleStat } from "./battle-stat"; import { BattleStat } from "./battle-stat";
import { BattlerTagType, BerryType } from "#enums"; import { BattlerTagType } from "./enums/battler-tag-type";
import { getStatusEffectHealText } from "./status-effect"; import { getStatusEffectHealText } from "./status-effect";
import * as Utils from "../utils"; import * as Utils from "../utils";
import { DoubleBerryEffectAbAttr, ReduceBerryUseThresholdAbAttr, applyAbAttrs } from "./ability"; import { DoubleBerryEffectAbAttr, ReduceBerryUseThresholdAbAttr, applyAbAttrs } from "./ability";
import i18next from "../plugins/i18n"; import i18next from "../plugins/i18n";
import { BerryType } from "./enums/berry-type";
export function getBerryName(berryType: BerryType): string { export function getBerryName(berryType: BerryType): string {
return i18next.t(`berry:${BerryType[berryType]}.name`); return i18next.t(`berry:${BerryType[berryType]}.name`);

View File

@ -1,7 +1,10 @@
import { Species } from "./enums/species";
import { Type } from "./type"; import { Type } from "./type";
import * as Utils from "../utils"; import * as Utils from "../utils";
import beautify from "json-beautify"; import beautify from "json-beautify";
import { Biome, Species, TimeOfDay, TrainerType } from "#enums"; import { TrainerType } from "./enums/trainer-type";
import { TimeOfDay } from "./enums/time-of-day";
import { Biome } from "./enums/biome";
import {pokemonEvolutions, SpeciesFormEvolution} from "./pokemon-evolutions"; import {pokemonEvolutions, SpeciesFormEvolution} from "./pokemon-evolutions";
import i18next from "i18next"; import i18next from "i18next";

View File

@ -1,12 +1,14 @@
import * as Utils from "../utils"; import * as Utils from "../utils";
import { Challenges, TrainerType, Species } from "#enums"; import { Challenges } from "./enums/challenges";
import i18next from "#app/plugins/i18n.js"; import i18next from "#app/plugins/i18n.js";
import { GameData } from "#app/system/game-data.js"; import { GameData } from "#app/system/game-data.js";
import PokemonSpecies, { getPokemonSpecies, speciesStarters } from "./pokemon-species"; import PokemonSpecies, { getPokemonSpecies, speciesStarters } from "./pokemon-species";
import Pokemon from "#app/field/pokemon.js"; import Pokemon from "#app/field/pokemon.js";
import { BattleType, FixedBattleConfig } from "#app/battle.js"; import { BattleType, FixedBattleConfig } from "#app/battle.js";
import { TrainerType } from "./enums/trainer-type";
import Trainer, { TrainerVariant } from "#app/field/trainer.js"; import Trainer, { TrainerVariant } from "#app/field/trainer.js";
import { GameMode } from "#app/game-mode.js"; import { GameMode } from "#app/game-mode.js";
import { Species } from "./enums/species";
import { Type } from "./type"; import { Type } from "./type";
/** /**

View File

@ -2,8 +2,9 @@ import BattleScene from "../battle-scene";
import { PlayerPokemon } from "../field/pokemon"; import { PlayerPokemon } from "../field/pokemon";
import { Starter } from "../ui/starter-select-ui-handler"; import { Starter } from "../ui/starter-select-ui-handler";
import * as Utils from "../utils"; import * as Utils from "../utils";
import { Species } from "./enums/species";
import PokemonSpecies, { PokemonSpeciesForm, getPokemonSpecies, getPokemonSpeciesForm, speciesStarters } from "./pokemon-species"; import PokemonSpecies, { PokemonSpeciesForm, getPokemonSpecies, getPokemonSpeciesForm, speciesStarters } from "./pokemon-species";
import { PartyMemberStrength, Species } from "#enums"; import { PartyMemberStrength } from "./enums/party-member-strength";
export interface DailyRunConfig { export interface DailyRunConfig {
seed: integer; seed: integer;

View File

@ -1,5 +1,6 @@
import {trainerConfigs} from "./trainer-config"; import {trainerConfigs} from "./trainer-config";
import {BattleSpec, TrainerType} from "#enums"; import {TrainerType} from "./enums/trainer-type";
import {BattleSpec} from "../enums/battle-spec";
export interface TrainerTypeMessages { export interface TrainerTypeMessages {
encounter?: string | string[], encounter?: string | string[],

View File

@ -1,4 +1,5 @@
import { Moves, Species } from "#enums"; import { Moves } from "./enums/moves";
import { Species } from "./enums/species";
import { allMoves } from "./move"; import { allMoves } from "./move";
import * as Utils from "../utils"; import * as Utils from "../utils";

View File

@ -1,6 +1,7 @@
import BattleScene from "../battle-scene"; import BattleScene from "../battle-scene";
import { Species } from "./enums/species";
import PokemonSpecies, { getPokemonSpecies, speciesStarters } from "./pokemon-species"; import PokemonSpecies, { getPokemonSpecies, speciesStarters } from "./pokemon-species";
import { EggTier, Species } from "#enums"; import { EggTier } from "./enums/egg-type";
import i18next from "../plugins/i18n"; import i18next from "../plugins/i18n";
export const EGG_SEED = 1073741824; export const EGG_SEED = 1073741824;

View File

@ -1,7 +1,9 @@
import { Moves } from "./enums/moves";
import { ChargeAnim, MoveChargeAnim, initMoveAnim, loadMoveAnimAssets } from "./battle-anims"; import { ChargeAnim, MoveChargeAnim, initMoveAnim, loadMoveAnimAssets } from "./battle-anims";
import { BattleEndPhase, MovePhase, NewBattlePhase, PartyStatusCurePhase, PokemonHealPhase, StatChangePhase, SwitchSummonPhase } from "../phases"; import { BattleEndPhase, MovePhase, NewBattlePhase, PartyStatusCurePhase, PokemonHealPhase, StatChangePhase, SwitchSummonPhase } from "../phases";
import { BattleStat, getBattleStatName } from "./battle-stat"; import { BattleStat, getBattleStatName } from "./battle-stat";
import { EncoreTag } from "./battler-tags"; import { EncoreTag } from "./battler-tags";
import { BattlerTagType } from "./enums/battler-tag-type";
import { getPokemonMessage } from "../messages"; import { getPokemonMessage } from "../messages";
import Pokemon, { AttackMoveResult, EnemyPokemon, HitResult, MoveResult, PlayerPokemon, PokemonMove, TurnMove } from "../field/pokemon"; import Pokemon, { AttackMoveResult, EnemyPokemon, HitResult, MoveResult, PlayerPokemon, PokemonMove, TurnMove } from "../field/pokemon";
import { StatusEffect, getStatusEffectHealText, isNonVolatileStatusEffect, getNonVolatileStatusEffects} from "./status-effect"; import { StatusEffect, getStatusEffectHealText, isNonVolatileStatusEffect, getNonVolatileStatusEffects} from "./status-effect";
@ -9,16 +11,19 @@ import { Type } from "./type";
import * as Utils from "../utils"; import * as Utils from "../utils";
import { WeatherType } from "./weather"; import { WeatherType } from "./weather";
import { ArenaTagSide, ArenaTrapTag } from "./arena-tag"; import { ArenaTagSide, ArenaTrapTag } from "./arena-tag";
import { ArenaTagType } from "./enums/arena-tag-type";
import { UnswappableAbilityAbAttr, UncopiableAbilityAbAttr, UnsuppressableAbilityAbAttr, BlockRecoilDamageAttr, BlockOneHitKOAbAttr, IgnoreContactAbAttr, MaxMultiHitAbAttr, applyAbAttrs, BlockNonDirectDamageAbAttr, applyPreSwitchOutAbAttrs, PreSwitchOutAbAttr, applyPostDefendAbAttrs, PostDefendContactApplyStatusEffectAbAttr, MoveAbilityBypassAbAttr, ReverseDrainAbAttr, FieldPreventExplosiveMovesAbAttr, ForceSwitchOutImmunityAbAttr, BlockItemTheftAbAttr, applyPostAttackAbAttrs, ConfusionOnStatusEffectAbAttr, HealFromBerryUseAbAttr } from "./ability"; import { UnswappableAbilityAbAttr, UncopiableAbilityAbAttr, UnsuppressableAbilityAbAttr, BlockRecoilDamageAttr, BlockOneHitKOAbAttr, IgnoreContactAbAttr, MaxMultiHitAbAttr, applyAbAttrs, BlockNonDirectDamageAbAttr, applyPreSwitchOutAbAttrs, PreSwitchOutAbAttr, applyPostDefendAbAttrs, PostDefendContactApplyStatusEffectAbAttr, MoveAbilityBypassAbAttr, ReverseDrainAbAttr, FieldPreventExplosiveMovesAbAttr, ForceSwitchOutImmunityAbAttr, BlockItemTheftAbAttr, applyPostAttackAbAttrs, ConfusionOnStatusEffectAbAttr, HealFromBerryUseAbAttr } from "./ability";
import { Abilities, ArenaTagType, BattlerTagType, Biome, Moves, Species } from "#enums"; import { Abilities } from "./enums/abilities";
import { allAbilities } from "./ability"; import { allAbilities } from "./ability";
import { PokemonHeldItemModifier, BerryModifier, PreserveBerryModifier } from "../modifier/modifier"; import { PokemonHeldItemModifier, BerryModifier, PreserveBerryModifier } from "../modifier/modifier";
import { BattlerIndex } from "../battle"; import { BattlerIndex } from "../battle";
import { Stat } from "./pokemon-stat"; import { Stat } from "./pokemon-stat";
import { TerrainType } from "./terrain"; import { TerrainType } from "./terrain";
import { SpeciesFormChangeActiveTrigger } from "./pokemon-forms"; import { SpeciesFormChangeActiveTrigger } from "./pokemon-forms";
import { Species } from "./enums/species";
import { ModifierPoolType } from "#app/modifier/modifier-type"; import { ModifierPoolType } from "#app/modifier/modifier-type";
import { Command } from "../ui/command-ui-handler"; import { Command } from "../ui/command-ui-handler";
import { Biome } from "./enums/biome";
import i18next, { Localizable } from "../plugins/i18n"; import i18next, { Localizable } from "../plugins/i18n";
import { getBerryEffectFunc } from "./berry"; import { getBerryEffectFunc } from "./berry";
@ -1792,7 +1797,7 @@ export class RemoveHeldItemAttr extends MoveEffectAttr {
} }
/** /**
* Attribute that causes targets of the move to eat a berry. If chosenBerry is not overridden, a random berry will be picked from the target's inventory. * Attribute that causes targets of the move to eat a berry. If chosenBerry is not overriden, a random berry will be picked from the target's inventory.
*/ */
export class EatBerryAttr extends MoveEffectAttr { export class EatBerryAttr extends MoveEffectAttr {
protected chosenBerry: BerryModifier; protected chosenBerry: BerryModifier;

View File

@ -1,7 +1,7 @@
import { Stat, getStatName } from "./pokemon-stat"; import { Stat, getStatName } from "./pokemon-stat";
import * as Utils from "../utils"; import * as Utils from "../utils";
import { TextStyle, getBBCodeFrag } from "../ui/text"; import { TextStyle, getBBCodeFrag } from "../ui/text";
import { UiTheme } from "#enums"; import { UiTheme } from "#app/enums/ui-theme";
import i18next from "i18next"; import i18next from "i18next";
export enum Nature { export enum Nature {

View File

@ -1,12 +1,15 @@
import { Gender } from "./gender"; import { Gender } from "./gender";
import { Moves } from "./enums/moves";
import { PokeballType } from "./pokeball"; import { PokeballType } from "./pokeball";
import Pokemon from "../field/pokemon"; import Pokemon from "../field/pokemon";
import { Stat } from "./pokemon-stat"; import { Stat } from "./pokemon-stat";
import { Species } from "./enums/species";
import { Type } from "./type"; import { Type } from "./type";
import * as Utils from "../utils"; import * as Utils from "../utils";
import { SpeciesFormKey } from "./pokemon-species"; import { SpeciesFormKey } from "./pokemon-species";
import { WeatherType } from "./weather"; import { WeatherType } from "./weather";
import { Biome, Moves, Species, TimeOfDay } from "#enums"; import { Biome } from "./enums/biome";
import { TimeOfDay } from "./enums/time-of-day";
import { Nature } from "./nature"; import { Nature } from "./nature";
export enum SpeciesWildEvolutionDelay { export enum SpeciesWildEvolutionDelay {

View File

@ -1,9 +1,12 @@
import { TimeOfDay } from "./enums/time-of-day";
import { PokemonFormChangeItemModifier } from "../modifier/modifier"; import { PokemonFormChangeItemModifier } from "../modifier/modifier";
import Pokemon from "../field/pokemon"; import Pokemon from "../field/pokemon";
import { Moves } from "./enums/moves";
import { SpeciesFormKey } from "./pokemon-species"; import { SpeciesFormKey } from "./pokemon-species";
import { Species } from "./enums/species";
import { StatusEffect } from "./status-effect"; import { StatusEffect } from "./status-effect";
import { MoveCategory, allMoves } from "./move"; import { MoveCategory, allMoves } from "./move";
import { Abilities, Moves, Species, TimeOfDay } from "#enums"; import { Abilities } from "./enums/abilities";
export enum FormChangeItem { export enum FormChangeItem {
NONE, NONE,

View File

@ -1,4 +1,5 @@
import { Moves, Species } from "#enums"; import { Moves } from "./enums/moves";
import { Species } from "./enums/species";
export type LevelMoves = ([integer, Moves])[]; export type LevelMoves = ([integer, Moves])[];

View File

@ -1,15 +1,17 @@
import { Abilities, PartyMemberStrength, Species } from "#enums"; import { Abilities } from "./enums/abilities";
import BattleScene, { AnySound } from "../battle-scene"; import BattleScene, { AnySound } from "../battle-scene";
import { Variant, variantColorCache } from "./variant"; import { Variant, variantColorCache } from "./variant";
import { variantData } from "./variant"; import { variantData } from "./variant";
import { GrowthRate } from "./exp"; import { GrowthRate } from "./exp";
import { SpeciesWildEvolutionDelay, pokemonEvolutions, pokemonPrevolutions } from "./pokemon-evolutions"; import { SpeciesWildEvolutionDelay, pokemonEvolutions, pokemonPrevolutions } from "./pokemon-evolutions";
import { Species } from "./enums/species";
import { Type } from "./type"; import { Type } from "./type";
import { LevelMoves, pokemonFormLevelMoves, pokemonFormLevelMoves as pokemonSpeciesFormLevelMoves, pokemonSpeciesLevelMoves } from "./pokemon-level-moves"; import { LevelMoves, pokemonFormLevelMoves, pokemonFormLevelMoves as pokemonSpeciesFormLevelMoves, pokemonSpeciesLevelMoves } from "./pokemon-level-moves";
import { uncatchableSpecies } from "./biomes"; import { uncatchableSpecies } from "./biomes";
import * as Utils from "../utils"; import * as Utils from "../utils";
import { StarterMoveset } from "../system/game-data"; import { StarterMoveset } from "../system/game-data";
import { speciesEggMoves } from "./egg-moves"; import { speciesEggMoves } from "./egg-moves";
import { PartyMemberStrength } from "./enums/party-member-strength";
import { GameMode } from "../game-mode"; import { GameMode } from "../game-mode";
import { QuantizerCelebi, argbFromRgba, rgbaFromArgb } from "@material/material-color-utilities"; import { QuantizerCelebi, argbFromRgba, rgbaFromArgb } from "@material/material-color-utilities";
import { VariantSet } from "./variant"; import { VariantSet } from "./variant";

View File

@ -1,5 +1,6 @@
import { ModifierTier } from "../modifier/modifier-tier"; import { ModifierTier } from "../modifier/modifier-tier";
import { Moves, Species } from "#enums"; import { Moves } from "./enums/moves";
import { Species } from "./enums/species";
interface TmSpecies { interface TmSpecies {
[key: integer]: Array<Species | Array<Species | string>> [key: integer]: Array<Species | Array<Species | string>>

View File

@ -2,15 +2,18 @@ import BattleScene, {startingWave} from "../battle-scene";
import {ModifierTypeFunc, modifierTypes} from "../modifier/modifier-type"; import {ModifierTypeFunc, modifierTypes} from "../modifier/modifier-type";
import {EnemyPokemon} from "../field/pokemon"; import {EnemyPokemon} from "../field/pokemon";
import * as Utils from "../utils"; import * as Utils from "../utils";
import {TrainerType} from "./enums/trainer-type";
import {Moves} from "./enums/moves";
import {PokeballType} from "./pokeball"; import {PokeballType} from "./pokeball";
import {pokemonEvolutions, pokemonPrevolutions} from "./pokemon-evolutions"; import {pokemonEvolutions, pokemonPrevolutions} from "./pokemon-evolutions";
import PokemonSpecies, {getPokemonSpecies, PokemonSpeciesFilter} from "./pokemon-species"; import PokemonSpecies, {getPokemonSpecies, PokemonSpeciesFilter} from "./pokemon-species";
import {Species} from "./enums/species";
import {tmSpecies} from "./tms"; import {tmSpecies} from "./tms";
import {Type} from "./type"; import {Type} from "./type";
import {doubleBattleDialogue} from "./dialogue"; import {doubleBattleDialogue} from "./dialogue";
import {PersistentModifier} from "../modifier/modifier"; import {PersistentModifier} from "../modifier/modifier";
import {TrainerVariant} from "../field/trainer"; import {TrainerVariant} from "../field/trainer";
import {Moves, PartyMemberStrength, Species, TrainerType} from "#enums"; import {PartyMemberStrength} from "./enums/party-member-strength";
import {getIsInitialized, initI18n} from "#app/plugins/i18n"; import {getIsInitialized, initI18n} from "#app/plugins/i18n";
import i18next from "i18next"; import i18next from "i18next";

View File

@ -1,4 +1,4 @@
import { TrainerType } from "#enums"; import { TrainerType } from "./enums/trainer-type";
import * as Utils from "../utils"; import * as Utils from "../utils";
class TrainerNameConfig { class TrainerNameConfig {

View File

@ -1,4 +1,4 @@
import { Biome } from "#enums"; import { Biome } from "./enums/biome";
import { getPokemonMessage, getPokemonNameWithAffix } from "../messages"; import { getPokemonMessage, getPokemonNameWithAffix } from "../messages";
import Pokemon from "../field/pokemon"; import Pokemon from "../field/pokemon";
import { Type } from "./type"; import { Type } from "./type";

View File

@ -5,11 +5,12 @@ import * as Utils from "./utils";
import { Mode } from "./ui/ui"; import { Mode } from "./ui/ui";
import { EGG_SEED, Egg, GachaType, getLegendaryGachaSpeciesForTimestamp } from "./data/egg"; import { EGG_SEED, Egg, GachaType, getLegendaryGachaSpeciesForTimestamp } from "./data/egg";
import EggHatchSceneHandler from "./ui/egg-hatch-scene-handler"; import EggHatchSceneHandler from "./ui/egg-hatch-scene-handler";
import { Species } from "./data/enums/species";
import { PlayerPokemon } from "./field/pokemon"; import { PlayerPokemon } from "./field/pokemon";
import { getPokemonSpecies, speciesStarters } from "./data/pokemon-species"; import { getPokemonSpecies, speciesStarters } from "./data/pokemon-species";
import { achvs } from "./system/achv"; import { achvs } from "./system/achv";
import { pokemonPrevolutions } from "./data/pokemon-evolutions"; import { pokemonPrevolutions } from "./data/pokemon-evolutions";
import { EggTier, Species } from "#enums"; import { EggTier } from "./data/enums/egg-type";
import PokemonInfoContainer from "./ui/pokemon-info-container"; import PokemonInfoContainer from "./ui/pokemon-info-container";
import EggCounterContainer from "./ui/egg-counter-container"; import EggCounterContainer from "./ui/egg-counter-container";
import { EggCountChangedEvent } from "./events/egg"; import { EggCountChangedEvent } from "./events/egg";

View File

@ -1,25 +0,0 @@
export * from "./abilities";
export * from "./arena-tag-type";
export * from "./battle-spec";
export * from "./battle-style";
export * from "./battler-tag-type";
export * from "./berry-type";
export * from "./biome";
export * from "./buttons";
export * from "./challenges";
export * from "./devices";
export * from "./ease-type";
export * from "./egg-type";
export * from "./exp-notification";
export * from "./game-data-type";
export * from "./money-format";
export * from "./moves";
export * from "./money-format";
export * from "./party-member-strength";
export * from "./passive";
export * from "./player-gender";
export * from "./species";
export * from "./time-of-day";
export * from "./trainer-type";
export * from "./ui-theme";

View File

@ -1,20 +1,25 @@
import BattleScene from "../battle-scene"; import BattleScene from "../battle-scene";
import { BiomePoolTier, PokemonPools, BiomeTierTrainerPools, biomePokemonPools, biomeTrainerPools } from "../data/biomes"; import { BiomePoolTier, PokemonPools, BiomeTierTrainerPools, biomePokemonPools, biomeTrainerPools } from "../data/biomes";
import { ArenaTagType, Biome, Moves, Species, TimeOfDay, TrainerType } from "#enums"; import { Biome } from "../data/enums/biome";
import * as Utils from "../utils"; import * as Utils from "../utils";
import PokemonSpecies, { getPokemonSpecies } from "../data/pokemon-species"; import PokemonSpecies, { getPokemonSpecies } from "../data/pokemon-species";
import { Species } from "../data/enums/species";
import { Weather, WeatherType, getTerrainClearMessage, getTerrainStartMessage, getWeatherClearMessage, getWeatherStartMessage } from "../data/weather"; import { Weather, WeatherType, getTerrainClearMessage, getTerrainStartMessage, getWeatherClearMessage, getWeatherStartMessage } from "../data/weather";
import { CommonAnimPhase } from "../phases"; import { CommonAnimPhase } from "../phases";
import { CommonAnim } from "../data/battle-anims"; import { CommonAnim } from "../data/battle-anims";
import { Type } from "../data/type"; import { Type } from "../data/type";
import Move from "../data/move"; import Move from "../data/move";
import { ArenaTag, ArenaTagSide, getArenaTag } from "../data/arena-tag"; import { ArenaTag, ArenaTagSide, getArenaTag } from "../data/arena-tag";
import { ArenaTagType } from "../data/enums/arena-tag-type";
import { TrainerType } from "../data/enums/trainer-type";
import { BattlerIndex } from "../battle"; import { BattlerIndex } from "../battle";
import { Moves } from "../data/enums/moves";
import { TimeOfDay } from "../data/enums/time-of-day";
import { Terrain, TerrainType } from "../data/terrain"; import { Terrain, TerrainType } from "../data/terrain";
import { PostTerrainChangeAbAttr, PostWeatherChangeAbAttr, applyPostTerrainChangeAbAttrs, applyPostWeatherChangeAbAttrs } from "../data/ability"; import { PostTerrainChangeAbAttr, PostWeatherChangeAbAttr, applyPostTerrainChangeAbAttrs, applyPostWeatherChangeAbAttrs } from "../data/ability";
import Pokemon from "./pokemon"; import Pokemon from "./pokemon";
import * as Overrides from "../overrides"; import * as Overrides from "../overrides";
import { WeatherChangedEvent, TerrainChangedEvent, TagAddedEvent, TagRemovedEvent } from "../events/arena"; import { WeatherChangedEvent, TerrainChangedEvent, TagAddedEvent, TagRemovedEvent } from "./events/arena";
export class Arena { export class Arena {
public scene: BattleScene; public scene: BattleScene;

View File

@ -1,5 +1,5 @@
import { ArenaTagSide } from "#app/data/arena-tag.js"; import { ArenaTagSide } from "#app/data/arena-tag.js";
import { ArenaTagType } from "#enums"; import { ArenaTagType } from "#app/data/enums/arena-tag-type.js";
import { TerrainType } from "#app/data/terrain.js"; import { TerrainType } from "#app/data/terrain.js";
import { WeatherType } from "#app/data/weather.js"; import { WeatherType } from "#app/data/weather.js";

View File

@ -3,6 +3,7 @@ import BattleScene, { AnySound } from "../battle-scene";
import { Variant, VariantSet, variantColorCache } from "#app/data/variant"; import { Variant, VariantSet, variantColorCache } from "#app/data/variant";
import { variantData } from "#app/data/variant"; import { variantData } from "#app/data/variant";
import BattleInfo, { PlayerBattleInfo, EnemyBattleInfo } from "../ui/battle-info"; import BattleInfo, { PlayerBattleInfo, EnemyBattleInfo } from "../ui/battle-info";
import { Moves } from "../data/enums/moves";
import Move, { HighCritAttr, HitsTagAttr, applyMoveAttrs, FixedDamageAttr, VariableAtkAttr, VariablePowerAttr, allMoves, MoveCategory, TypelessAttr, CritOnlyAttr, getMoveTargets, OneHitKOAttr, MultiHitAttr, VariableMoveTypeAttr, StatusMoveTypeImmunityAttr, MoveTarget, VariableDefAttr, AttackMove, ModifiedDamageAttr, VariableMoveTypeMultiplierAttr, IgnoreOpponentStatChangesAttr, SacrificialAttr, VariableMoveCategoryAttr, CounterDamageAttr, StatChangeAttr, RechargeAttr, ChargeAttr, IgnoreWeatherTypeDebuffAttr, BypassBurnDamageReductionAttr, SacrificialAttrOnHit, MoveFlags } from "../data/move"; import Move, { HighCritAttr, HitsTagAttr, applyMoveAttrs, FixedDamageAttr, VariableAtkAttr, VariablePowerAttr, allMoves, MoveCategory, TypelessAttr, CritOnlyAttr, getMoveTargets, OneHitKOAttr, MultiHitAttr, VariableMoveTypeAttr, StatusMoveTypeImmunityAttr, MoveTarget, VariableDefAttr, AttackMove, ModifiedDamageAttr, VariableMoveTypeMultiplierAttr, IgnoreOpponentStatChangesAttr, SacrificialAttr, VariableMoveCategoryAttr, CounterDamageAttr, StatChangeAttr, RechargeAttr, ChargeAttr, IgnoreWeatherTypeDebuffAttr, BypassBurnDamageReductionAttr, SacrificialAttrOnHit, MoveFlags } from "../data/move";
import { default as PokemonSpecies, PokemonSpeciesForm, SpeciesFormKey, getFusedSpeciesName, getPokemonSpecies, getPokemonSpeciesForm, getStarterValueFriendshipCap, speciesStarters, starterPassiveAbilities } from "../data/pokemon-species"; import { default as PokemonSpecies, PokemonSpeciesForm, SpeciesFormKey, getFusedSpeciesName, getPokemonSpecies, getPokemonSpeciesForm, getStarterValueFriendshipCap, speciesStarters, starterPassiveAbilities } from "../data/pokemon-species";
import * as Utils from "../utils"; import * as Utils from "../utils";
@ -19,13 +20,18 @@ import { reverseCompatibleTms, tmSpecies, tmPoolTiers } from "../data/tms";
import { DamagePhase, FaintPhase, LearnMovePhase, ObtainStatusEffectPhase, StatChangePhase, SwitchSummonPhase, ToggleDoublePositionPhase } from "../phases"; import { DamagePhase, FaintPhase, LearnMovePhase, ObtainStatusEffectPhase, StatChangePhase, SwitchSummonPhase, ToggleDoublePositionPhase } from "../phases";
import { BattleStat } from "../data/battle-stat"; import { BattleStat } from "../data/battle-stat";
import { BattlerTag, BattlerTagLapseType, EncoreTag, HelpingHandTag, HighestStatBoostTag, TypeBoostTag, getBattlerTag } from "../data/battler-tags"; import { BattlerTag, BattlerTagLapseType, EncoreTag, HelpingHandTag, HighestStatBoostTag, TypeBoostTag, getBattlerTag } from "../data/battler-tags";
import { BattlerTagType } from "../data/enums/battler-tag-type";
import { Species } from "../data/enums/species";
import { WeatherType } from "../data/weather"; import { WeatherType } from "../data/weather";
import { TempBattleStat } from "../data/temp-battle-stat"; import { TempBattleStat } from "../data/temp-battle-stat";
import { ArenaTagSide, WeakenMoveScreenTag, WeakenMoveTypeTag } from "../data/arena-tag"; import { ArenaTagSide, WeakenMoveScreenTag, WeakenMoveTypeTag } from "../data/arena-tag";
import { Abilities, ArenaTagType, Moves, BattlerTagType, Species, Biome, BattleSpec, BerryType } from "#enums"; import { ArenaTagType } from "../data/enums/arena-tag-type";
import { Biome } from "../data/enums/biome";
import { Ability, AbAttr, BattleStatMultiplierAbAttr, BlockCritAbAttr, BonusCritAbAttr, BypassBurnDamageReductionAbAttr, FieldPriorityMoveImmunityAbAttr, FieldVariableMovePowerAbAttr, IgnoreOpponentStatChangesAbAttr, MoveImmunityAbAttr, MoveTypeChangeAttr, PreApplyBattlerTagAbAttr, PreDefendFullHpEndureAbAttr, ReceivedMoveDamageMultiplierAbAttr, ReduceStatusEffectDurationAbAttr, StabBoostAbAttr, StatusEffectImmunityAbAttr, TypeImmunityAbAttr, VariableMovePowerAbAttr, WeightMultiplierAbAttr, allAbilities, applyAbAttrs, applyBattleStatMultiplierAbAttrs, applyPreApplyBattlerTagAbAttrs, applyPreAttackAbAttrs, applyPreDefendAbAttrs, applyPreSetStatusAbAttrs, UnsuppressableAbilityAbAttr, SuppressFieldAbilitiesAbAttr, NoFusionAbilityAbAttr, MultCritAbAttr, IgnoreTypeImmunityAbAttr, DamageBoostAbAttr, IgnoreTypeStatusEffectImmunityAbAttr, ConditionalCritAbAttr, applyFieldBattleStatMultiplierAbAttrs, FieldMultiplyBattleStatAbAttr } from "../data/ability"; import { Ability, AbAttr, BattleStatMultiplierAbAttr, BlockCritAbAttr, BonusCritAbAttr, BypassBurnDamageReductionAbAttr, FieldPriorityMoveImmunityAbAttr, FieldVariableMovePowerAbAttr, IgnoreOpponentStatChangesAbAttr, MoveImmunityAbAttr, MoveTypeChangeAttr, PreApplyBattlerTagAbAttr, PreDefendFullHpEndureAbAttr, ReceivedMoveDamageMultiplierAbAttr, ReduceStatusEffectDurationAbAttr, StabBoostAbAttr, StatusEffectImmunityAbAttr, TypeImmunityAbAttr, VariableMovePowerAbAttr, WeightMultiplierAbAttr, allAbilities, applyAbAttrs, applyBattleStatMultiplierAbAttrs, applyPreApplyBattlerTagAbAttrs, applyPreAttackAbAttrs, applyPreDefendAbAttrs, applyPreSetStatusAbAttrs, UnsuppressableAbilityAbAttr, SuppressFieldAbilitiesAbAttr, NoFusionAbilityAbAttr, MultCritAbAttr, IgnoreTypeImmunityAbAttr, DamageBoostAbAttr, IgnoreTypeStatusEffectImmunityAbAttr, ConditionalCritAbAttr, applyFieldBattleStatMultiplierAbAttrs, FieldMultiplyBattleStatAbAttr } from "../data/ability";
import { Abilities } from "#app/data/enums/abilities";
import PokemonData from "../system/pokemon-data"; import PokemonData from "../system/pokemon-data";
import { BattlerIndex } from "../battle"; import { BattlerIndex } from "../battle";
import { BattleSpec } from "../enums/battle-spec";
import { Mode } from "../ui/ui"; import { Mode } from "../ui/ui";
import PartyUiHandler, { PartyOption, PartyUiMode } from "../ui/party-ui-handler"; import PartyUiHandler, { PartyOption, PartyUiMode } from "../ui/party-ui-handler";
import SoundFade from "phaser3-rex-plugins/plugins/soundfade"; import SoundFade from "phaser3-rex-plugins/plugins/soundfade";
@ -38,6 +44,7 @@ import { SpeciesFormChange, SpeciesFormChangeActiveTrigger, SpeciesFormChangeMov
import { TerrainType } from "../data/terrain"; import { TerrainType } from "../data/terrain";
import { TrainerSlot } from "../data/trainer-config"; import { TrainerSlot } from "../data/trainer-config";
import * as Overrides from "../overrides"; import * as Overrides from "../overrides";
import { BerryType } from "../data/enums/berry-type";
import i18next from "../plugins/i18n"; import i18next from "../plugins/i18n";
import { speciesEggMoves } from "../data/egg-moves"; import { speciesEggMoves } from "../data/egg-moves";
import { ModifierTier } from "../modifier/modifier-tier"; import { ModifierTier } from "../modifier/modifier-tier";

View File

@ -11,7 +11,8 @@ import {
trainerPartyTemplates, trainerPartyTemplates,
signatureSpecies signatureSpecies
} from "../data/trainer-config"; } from "../data/trainer-config";
import {PartyMemberStrength, Species, TrainerType} from "#enums"; import {PartyMemberStrength} from "../data/enums/party-member-strength";
import {TrainerType} from "../data/enums/trainer-type";
import {EnemyPokemon} from "./pokemon"; import {EnemyPokemon} from "./pokemon";
import * as Utils from "../utils"; import * as Utils from "../utils";
import {PersistentModifier} from "../modifier/modifier"; import {PersistentModifier} from "../modifier/modifier";
@ -19,6 +20,7 @@ import {trainerNamePools} from "../data/trainer-names";
import {ArenaTagSide, ArenaTrapTag} from "#app/data/arena-tag"; import {ArenaTagSide, ArenaTrapTag} from "#app/data/arena-tag";
import {getIsInitialized, initI18n} from "#app/plugins/i18n"; import {getIsInitialized, initI18n} from "#app/plugins/i18n";
import i18next from "i18next"; import i18next from "i18next";
import {Species} from "#app/data/enums/species";
export enum TrainerVariant { export enum TrainerVariant {
DEFAULT, DEFAULT,

View File

@ -7,7 +7,7 @@ import { EndEvolutionPhase, EvolutionPhase } from "./evolution-phase";
import Pokemon, { EnemyPokemon, PlayerPokemon } from "./field/pokemon"; import Pokemon, { EnemyPokemon, PlayerPokemon } from "./field/pokemon";
import { Mode } from "./ui/ui"; import { Mode } from "./ui/ui";
import PartyUiHandler from "./ui/party-ui-handler"; import PartyUiHandler from "./ui/party-ui-handler";
import { BattleSpec } from "#enums"; import { BattleSpec } from "./enums/battle-spec";
import { BattlePhase, MovePhase, PokemonHealPhase } from "./phases"; import { BattlePhase, MovePhase, PokemonHealPhase } from "./phases";
import { getTypeRgb } from "./data/type"; import { getTypeRgb } from "./data/type";

View File

@ -2,7 +2,8 @@ import i18next from "i18next";
import { classicFixedBattles, FixedBattleConfig, FixedBattleConfigs } from "./battle"; import { classicFixedBattles, FixedBattleConfig, FixedBattleConfigs } from "./battle";
import BattleScene from "./battle-scene"; import BattleScene from "./battle-scene";
import { allChallenges, applyChallenges, Challenge, ChallengeType, copyChallenge } from "./data/challenge"; import { allChallenges, applyChallenges, Challenge, ChallengeType, copyChallenge } from "./data/challenge";
import { Biome, Species } from "#enums"; import { Biome } from "./data/enums/biome";
import { Species } from "./data/enums/species";
import PokemonSpecies, { allSpecies } from "./data/pokemon-species"; import PokemonSpecies, { allSpecies } from "./data/pokemon-species";
import { Arena } from "./field/arena"; import { Arena } from "./field/arena";
import * as Overrides from "./overrides"; import * as Overrides from "./overrides";

View File

@ -6,11 +6,12 @@ import pad_unlicensedSNES from "./configs/inputs/pad_unlicensedSNES";
import pad_xbox360 from "./configs/inputs/pad_xbox360"; import pad_xbox360 from "./configs/inputs/pad_xbox360";
import pad_dualshock from "./configs/inputs/pad_dualshock"; import pad_dualshock from "./configs/inputs/pad_dualshock";
import pad_procon from "./configs/inputs/pad_procon"; import pad_procon from "./configs/inputs/pad_procon";
import {Button} from "./enums/buttons";
import {Mode} from "./ui/ui"; import {Mode} from "./ui/ui";
import SettingsGamepadUiHandler from "./ui/settings/settings-gamepad-ui-handler"; import SettingsGamepadUiHandler from "./ui/settings/settings-gamepad-ui-handler";
import SettingsKeyboardUiHandler from "./ui/settings/settings-keyboard-ui-handler"; import SettingsKeyboardUiHandler from "./ui/settings/settings-keyboard-ui-handler";
import cfg_keyboard_qwerty from "./configs/inputs/cfg_keyboard_qwerty"; import cfg_keyboard_qwerty from "./configs/inputs/cfg_keyboard_qwerty";
import {Button, Device} from "#enums"; import {Device} from "#app/enums/devices";
import { import {
assign, assign,
getButtonWithKeycode, getButtonWithKeycode,

View File

@ -1,5 +1,6 @@
import { GachaType } from "./data/egg"; import { GachaType } from "./data/egg";
import { Biome, TrainerType } from "#enums"; import { Biome } from "./data/enums/biome";
import { TrainerType } from "./data/enums/trainer-type";
import { trainerConfigs } from "./data/trainer-config"; import { trainerConfigs } from "./data/trainer-config";
import { getBiomeHasProps } from "./field/arena"; import { getBiomeHasProps } from "./field/arena";
import CacheBustedLoaderPlugin from "./plugins/cache-busted-loader-plugin"; import CacheBustedLoaderPlugin from "./plugins/cache-busted-loader-plugin";

View File

@ -1,4 +1,4 @@
import { BattleSpec } from "#enums"; import { BattleSpec } from "./enums/battle-spec";
import Pokemon from "./field/pokemon"; import Pokemon from "./field/pokemon";
import i18next from "./plugins/i18n"; import i18next from "./plugins/i18n";

View File

@ -1,6 +1,7 @@
import * as Modifiers from "./modifier"; import * as Modifiers from "./modifier";
import { AttackMove, allMoves } from "../data/move"; import { AttackMove, allMoves } from "../data/move";
import { Abilities, BattlerTagType, BerryType, Moves } from "#enums"; import { Moves } from "../data/enums/moves";
import { Abilities } from "../data/enums/abilities";
import { PokeballType, getPokeballCatchMultiplier, getPokeballName } from "../data/pokeball"; import { PokeballType, getPokeballCatchMultiplier, getPokeballName } from "../data/pokeball";
import Pokemon, { EnemyPokemon, PlayerPokemon, PokemonMove } from "../field/pokemon"; import Pokemon, { EnemyPokemon, PlayerPokemon, PokemonMove } from "../field/pokemon";
import { EvolutionItem, pokemonEvolutions } from "../data/pokemon-evolutions"; import { EvolutionItem, pokemonEvolutions } from "../data/pokemon-evolutions";
@ -11,6 +12,7 @@ import PartyUiHandler, { PokemonMoveSelectFilter, PokemonSelectFilter } from "..
import * as Utils from "../utils"; import * as Utils from "../utils";
import { TempBattleStat, getTempBattleStatBoosterItemName, getTempBattleStatName } from "../data/temp-battle-stat"; import { TempBattleStat, getTempBattleStatBoosterItemName, getTempBattleStatName } from "../data/temp-battle-stat";
import { getBerryEffectDescription, getBerryName } from "../data/berry"; import { getBerryEffectDescription, getBerryName } from "../data/berry";
import { BerryType } from "../data/enums/berry-type";
import { Unlockables } from "../system/unlockables"; import { Unlockables } from "../system/unlockables";
import { StatusEffect, getStatusEffectDescriptor } from "../data/status-effect"; import { StatusEffect, getStatusEffectDescriptor } from "../data/status-effect";
import { SpeciesFormKey } from "../data/pokemon-species"; import { SpeciesFormKey } from "../data/pokemon-species";
@ -21,6 +23,7 @@ import { ModifierTier } from "./modifier-tier";
import { Nature, getNatureName, getNatureStatMultiplier } from "#app/data/nature"; import { Nature, getNatureName, getNatureStatMultiplier } from "#app/data/nature";
import i18next from "#app/plugins/i18n"; import i18next from "#app/plugins/i18n";
import { getModifierTierTextTint } from "#app/ui/text"; import { getModifierTierTextTint } from "#app/ui/text";
import { BattlerTagType } from "#app/data/enums/battler-tag-type.js";
import * as Overrides from "../overrides"; import * as Overrides from "../overrides";
import { MoneyMultiplierModifier } from "./modifier"; import { MoneyMultiplierModifier } from "./modifier";

View File

@ -13,12 +13,13 @@ import { getPokemonMessage } from "../messages";
import * as Utils from "../utils"; import * as Utils from "../utils";
import { TempBattleStat } from "../data/temp-battle-stat"; import { TempBattleStat } from "../data/temp-battle-stat";
import { getBerryEffectFunc, getBerryPredicate } from "../data/berry"; import { getBerryEffectFunc, getBerryPredicate } from "../data/berry";
import { BattlerTagType, BerryType } from "#enums"; import { BerryType } from "../data/enums/berry-type";
import { StatusEffect, getStatusEffectHealText } from "../data/status-effect"; import { StatusEffect, getStatusEffectHealText } from "../data/status-effect";
import { achvs } from "../system/achv"; import { achvs } from "../system/achv";
import { VoucherType } from "../system/voucher"; import { VoucherType } from "../system/voucher";
import { FormChangeItem, SpeciesFormChangeItemTrigger } from "../data/pokemon-forms"; import { FormChangeItem, SpeciesFormChangeItemTrigger } from "../data/pokemon-forms";
import { Nature } from "#app/data/nature"; import { Nature } from "#app/data/nature";
import { BattlerTagType } from "#app/data/enums/battler-tag-type";
import * as Overrides from "../overrides"; import * as Overrides from "../overrides";
import { ModifierType, modifierTypes } from "./modifier-type"; import { ModifierType, modifierTypes } from "./modifier-type";
import { Command } from "#app/ui/command-ui-handler.js"; import { Command } from "#app/ui/command-ui-handler.js";

View File

@ -1,12 +1,17 @@
import { Species, Abilities, Biome, Moves, BerryType, TimeOfDay } from "#enums"; import { Species } from "./data/enums/species";
import { Abilities } from "./data/enums/abilities";
import { Biome } from "./data/enums/biome";
import { Moves } from "./data/enums/moves";
import { WeatherType } from "./data/weather"; import { WeatherType } from "./data/weather";
import { Variant } from "./data/variant"; import { Variant } from "./data/variant";
import { BerryType } from "./data/enums/berry-type";
import { TempBattleStat } from "./data/temp-battle-stat"; import { TempBattleStat } from "./data/temp-battle-stat";
import { Nature } from "./data/nature"; import { Nature } from "./data/nature";
import { Type } from "./data/type"; import { Type } from "./data/type";
import { Stat } from "./data/pokemon-stat"; import { Stat } from "./data/pokemon-stat";
import { PokeballCounts } from "./battle-scene"; import { PokeballCounts } from "./battle-scene";
import { PokeballType } from "./data/pokeball"; import { PokeballType } from "./data/pokeball";
import {TimeOfDay} from "#app/data/enums/time-of-day";
import { Gender } from "./data/gender"; import { Gender } from "./data/gender";
import { StatusEffect } from "./data/status-effect"; import { StatusEffect } from "./data/status-effect";
import { modifierTypes } from "./modifier/modifier-type"; import { modifierTypes } from "./modifier/modifier-type";

View File

@ -1,7 +1,7 @@
import BattleScene, { bypassLogin } from "./battle-scene"; import BattleScene, { bypassLogin } from "./battle-scene";
import { default as Pokemon, PlayerPokemon, EnemyPokemon, PokemonMove, MoveResult, DamageResult, FieldPosition, HitResult, TurnMove } from "./field/pokemon"; import { default as Pokemon, PlayerPokemon, EnemyPokemon, PokemonMove, MoveResult, DamageResult, FieldPosition, HitResult, TurnMove } from "./field/pokemon";
import * as Utils from "./utils"; import * as Utils from "./utils";
import { Abilities, ArenaTagType, BattleSpec, BattleStyle, BattlerTagType, Biome, ExpNotification, Moves, PlayerGender, Species, TrainerType } from "#enums"; import { Moves } from "./data/enums/moves";
import { allMoves, applyMoveAttrs, BypassSleepAttr, ChargeAttr, applyFilteredMoveAttrs, HitsTagAttr, MissEffectAttr, MoveAttr, MoveEffectAttr, MoveFlags, MultiHitAttr, OverrideMoveEffectAttr, VariableAccuracyAttr, MoveTarget, getMoveTargets, MoveTargetSet, MoveEffectTrigger, CopyMoveAttr, AttackMove, SelfStatusMove, PreMoveMessageAttr, HealStatusEffectAttr, IgnoreOpponentStatChangesAttr, NoEffectAttr, BypassRedirectAttr, FixedDamageAttr, PostVictoryStatChangeAttr, OneHitKOAccuracyAttr, ForceSwitchOutAttr, VariableTargetAttr, IncrementMovePriorityAttr } from "./data/move"; import { allMoves, applyMoveAttrs, BypassSleepAttr, ChargeAttr, applyFilteredMoveAttrs, HitsTagAttr, MissEffectAttr, MoveAttr, MoveEffectAttr, MoveFlags, MultiHitAttr, OverrideMoveEffectAttr, VariableAccuracyAttr, MoveTarget, getMoveTargets, MoveTargetSet, MoveEffectTrigger, CopyMoveAttr, AttackMove, SelfStatusMove, PreMoveMessageAttr, HealStatusEffectAttr, IgnoreOpponentStatChangesAttr, NoEffectAttr, BypassRedirectAttr, FixedDamageAttr, PostVictoryStatChangeAttr, OneHitKOAccuracyAttr, ForceSwitchOutAttr, VariableTargetAttr, IncrementMovePriorityAttr } from "./data/move";
import { Mode } from "./ui/ui"; import { Mode } from "./ui/ui";
import { Command } from "./ui/command-ui-handler"; import { Command } from "./ui/command-ui-handler";
@ -17,27 +17,34 @@ import { EvolutionPhase } from "./evolution-phase";
import { Phase } from "./phase"; import { Phase } from "./phase";
import { BattleStat, getBattleStatLevelChangeDescription, getBattleStatName } from "./data/battle-stat"; import { BattleStat, getBattleStatLevelChangeDescription, getBattleStatName } from "./data/battle-stat";
import { biomeLinks, getBiomeName } from "./data/biomes"; import { biomeLinks, getBiomeName } from "./data/biomes";
import { Biome } from "./data/enums/biome";
import { ModifierTier } from "./modifier/modifier-tier"; import { ModifierTier } from "./modifier/modifier-tier";
import { FusePokemonModifierType, ModifierPoolType, ModifierType, ModifierTypeFunc, ModifierTypeOption, PokemonModifierType, PokemonMoveModifierType, PokemonPpRestoreModifierType, PokemonPpUpModifierType, RememberMoveModifierType, TmModifierType, getDailyRunStarterModifiers, getEnemyBuffModifierForWave, getModifierType, getPlayerModifierTypeOptions, getPlayerShopModifierTypeOptionsForWave, modifierTypes, regenerateModifierPoolThresholds } from "./modifier/modifier-type"; import { FusePokemonModifierType, ModifierPoolType, ModifierType, ModifierTypeFunc, ModifierTypeOption, PokemonModifierType, PokemonMoveModifierType, PokemonPpRestoreModifierType, PokemonPpUpModifierType, RememberMoveModifierType, TmModifierType, getDailyRunStarterModifiers, getEnemyBuffModifierForWave, getModifierType, getPlayerModifierTypeOptions, getPlayerShopModifierTypeOptionsForWave, modifierTypes, regenerateModifierPoolThresholds } from "./modifier/modifier-type";
import SoundFade from "phaser3-rex-plugins/plugins/soundfade"; import SoundFade from "phaser3-rex-plugins/plugins/soundfade";
import { BattlerTagLapseType, EncoreTag, HideSpriteTag as HiddenTag, ProtectedTag, TrappedTag } from "./data/battler-tags"; import { BattlerTagLapseType, EncoreTag, HideSpriteTag as HiddenTag, ProtectedTag, TrappedTag } from "./data/battler-tags";
import { BattlerTagType } from "./data/enums/battler-tag-type";
import { getPokemonMessage, getPokemonNameWithAffix } from "./messages"; import { getPokemonMessage, getPokemonNameWithAffix } from "./messages";
import { Starter } from "./ui/starter-select-ui-handler"; import { Starter } from "./ui/starter-select-ui-handler";
import { Gender } from "./data/gender"; import { Gender } from "./data/gender";
import { Weather, WeatherType, getRandomWeatherType, getTerrainBlockMessage, getWeatherDamageMessage, getWeatherLapseMessage } from "./data/weather"; import { Weather, WeatherType, getRandomWeatherType, getTerrainBlockMessage, getWeatherDamageMessage, getWeatherLapseMessage } from "./data/weather";
import { TempBattleStat } from "./data/temp-battle-stat"; import { TempBattleStat } from "./data/temp-battle-stat";
import { ArenaTagSide, ArenaTrapTag, MistTag, TrickRoomTag } from "./data/arena-tag"; import { ArenaTagSide, ArenaTrapTag, MistTag, TrickRoomTag } from "./data/arena-tag";
import { ArenaTagType } from "./data/enums/arena-tag-type";
import { CheckTrappedAbAttr, IgnoreOpponentStatChangesAbAttr, IgnoreOpponentEvasionAbAttr, PostAttackAbAttr, PostBattleAbAttr, PostDefendAbAttr, PostSummonAbAttr, PostTurnAbAttr, PostWeatherLapseAbAttr, PreSwitchOutAbAttr, PreWeatherDamageAbAttr, ProtectStatAbAttr, RedirectMoveAbAttr, BlockRedirectAbAttr, RunSuccessAbAttr, StatChangeMultiplierAbAttr, SuppressWeatherEffectAbAttr, SyncEncounterNatureAbAttr, applyAbAttrs, applyCheckTrappedAbAttrs, applyPostAttackAbAttrs, applyPostBattleAbAttrs, applyPostDefendAbAttrs, applyPostSummonAbAttrs, applyPostTurnAbAttrs, applyPostWeatherLapseAbAttrs, applyPreStatChangeAbAttrs, applyPreSwitchOutAbAttrs, applyPreWeatherEffectAbAttrs, BattleStatMultiplierAbAttr, applyBattleStatMultiplierAbAttrs, IncrementMovePriorityAbAttr, applyPostVictoryAbAttrs, PostVictoryAbAttr, BlockNonDirectDamageAbAttr as BlockNonDirectDamageAbAttr, applyPostKnockOutAbAttrs, PostKnockOutAbAttr, PostBiomeChangeAbAttr, applyPostFaintAbAttrs, PostFaintAbAttr, IncreasePpAbAttr, PostStatChangeAbAttr, applyPostStatChangeAbAttrs, AlwaysHitAbAttr, PreventBerryUseAbAttr, StatChangeCopyAbAttr, PokemonTypeChangeAbAttr, applyPreAttackAbAttrs, applyPostMoveUsedAbAttrs, PostMoveUsedAbAttr, MaxMultiHitAbAttr, HealFromBerryUseAbAttr } from "./data/ability"; import { CheckTrappedAbAttr, IgnoreOpponentStatChangesAbAttr, IgnoreOpponentEvasionAbAttr, PostAttackAbAttr, PostBattleAbAttr, PostDefendAbAttr, PostSummonAbAttr, PostTurnAbAttr, PostWeatherLapseAbAttr, PreSwitchOutAbAttr, PreWeatherDamageAbAttr, ProtectStatAbAttr, RedirectMoveAbAttr, BlockRedirectAbAttr, RunSuccessAbAttr, StatChangeMultiplierAbAttr, SuppressWeatherEffectAbAttr, SyncEncounterNatureAbAttr, applyAbAttrs, applyCheckTrappedAbAttrs, applyPostAttackAbAttrs, applyPostBattleAbAttrs, applyPostDefendAbAttrs, applyPostSummonAbAttrs, applyPostTurnAbAttrs, applyPostWeatherLapseAbAttrs, applyPreStatChangeAbAttrs, applyPreSwitchOutAbAttrs, applyPreWeatherEffectAbAttrs, BattleStatMultiplierAbAttr, applyBattleStatMultiplierAbAttrs, IncrementMovePriorityAbAttr, applyPostVictoryAbAttrs, PostVictoryAbAttr, BlockNonDirectDamageAbAttr as BlockNonDirectDamageAbAttr, applyPostKnockOutAbAttrs, PostKnockOutAbAttr, PostBiomeChangeAbAttr, applyPostFaintAbAttrs, PostFaintAbAttr, IncreasePpAbAttr, PostStatChangeAbAttr, applyPostStatChangeAbAttrs, AlwaysHitAbAttr, PreventBerryUseAbAttr, StatChangeCopyAbAttr, PokemonTypeChangeAbAttr, applyPreAttackAbAttrs, applyPostMoveUsedAbAttrs, PostMoveUsedAbAttr, MaxMultiHitAbAttr, HealFromBerryUseAbAttr } from "./data/ability";
import { Unlockables, getUnlockableName } from "./system/unlockables"; import { Unlockables, getUnlockableName } from "./system/unlockables";
import { getBiomeKey } from "./field/arena"; import { getBiomeKey } from "./field/arena";
import { BattleType, BattlerIndex, TurnCommand } from "./battle"; import { BattleType, BattlerIndex, TurnCommand } from "./battle";
import { BattleSpec } from "./enums/battle-spec";
import { Species } from "./data/enums/species";
import { ChallengeAchv, HealAchv, LevelAchv, achvs } from "./system/achv"; import { ChallengeAchv, HealAchv, LevelAchv, achvs } from "./system/achv";
import { TrainerSlot, trainerConfigs } from "./data/trainer-config"; import { TrainerSlot, trainerConfigs } from "./data/trainer-config";
import { TrainerType } from "./data/enums/trainer-type";
import { EggHatchPhase } from "./egg-hatch-phase"; import { EggHatchPhase } from "./egg-hatch-phase";
import { Egg } from "./data/egg"; import { Egg } from "./data/egg";
import { vouchers } from "./system/voucher"; import { vouchers } from "./system/voucher";
import { loggedInUser, updateUserInfo } from "./account"; import { loggedInUser, updateUserInfo } from "./account";
import { SessionSaveData } from "./system/game-data"; import { SessionSaveData } from "./system/game-data";
import { PlayerGender } from "./data/enums/player-gender";
import { addPokeballCaptureStars, addPokeballOpenParticles } from "./field/anims"; import { addPokeballCaptureStars, addPokeballOpenParticles } from "./field/anims";
import { SpeciesFormChangeActiveTrigger, SpeciesFormChangeManualTrigger, SpeciesFormChangeMoveLearnedTrigger, SpeciesFormChangePostMoveTrigger, SpeciesFormChangePreMoveTrigger } from "./data/pokemon-forms"; import { SpeciesFormChangeActiveTrigger, SpeciesFormChangeManualTrigger, SpeciesFormChangeMoveLearnedTrigger, SpeciesFormChangePostMoveTrigger, SpeciesFormChangePreMoveTrigger } from "./data/pokemon-forms";
import { battleSpecDialogue, getCharVariantFromDialogue, miscDialogue } from "./data/dialogue"; import { battleSpecDialogue, getCharVariantFromDialogue, miscDialogue } from "./data/dialogue";
@ -51,10 +58,13 @@ import { fetchDailyRunSeed, getDailyRunStarters } from "./data/daily-run";
import { GameMode, GameModes, getGameMode } from "./game-mode"; import { GameMode, GameModes, getGameMode } from "./game-mode";
import PokemonSpecies, { getPokemonSpecies, speciesStarters } from "./data/pokemon-species"; import PokemonSpecies, { getPokemonSpecies, speciesStarters } from "./data/pokemon-species";
import i18next from "./plugins/i18n"; import i18next from "./plugins/i18n";
import { Abilities } from "./data/enums/abilities";
import * as Overrides from "./overrides"; import * as Overrides from "./overrides";
import { TextStyle, addTextObject } from "./ui/text"; import { TextStyle, addTextObject } from "./ui/text";
import { Type } from "./data/type"; import { Type } from "./data/type";
import { BerryUsedEvent, EncounterPhaseEvent, MoveUsedEvent, TurnEndEvent, TurnInitEvent } from "./events/battle-scene"; import { BerryUsedEvent, EncounterPhaseEvent, MoveUsedEvent, TurnEndEvent, TurnInitEvent } from "./events/battle-scene";
import { ExpNotification } from "./enums/exp-notification";
import { BattleStyle } from "./enums/battle-style";
export class LoginPhase extends Phase { export class LoginPhase extends Phase {

View File

@ -3,7 +3,7 @@ import BattleScene from "../battle-scene";
import { TurnHeldItemTransferModifier } from "../modifier/modifier"; import { TurnHeldItemTransferModifier } from "../modifier/modifier";
import i18next from "../plugins/i18n"; import i18next from "../plugins/i18n";
import * as Utils from "../utils"; import * as Utils from "../utils";
import { PlayerGender } from "#enums"; import { PlayerGender } from "#app/data/enums/player-gender";
import { ParseKeys } from "i18next"; import { ParseKeys } from "i18next";
import { Challenge, SingleGenerationChallenge, SingleTypeChallenge } from "#app/data/challenge.js"; import { Challenge, SingleGenerationChallenge, SingleTypeChallenge } from "#app/data/challenge.js";

View File

@ -1,6 +1,6 @@
import { Arena } from "../field/arena"; import { Arena } from "../field/arena";
import { ArenaTag } from "../data/arena-tag"; import { ArenaTag } from "../data/arena-tag";
import { Biome } from "#enums"; import { Biome } from "../data/enums/biome";
import { Weather } from "../data/weather"; import { Weather } from "../data/weather";
import { Terrain } from "#app/data/terrain.js"; import { Terrain } from "#app/data/terrain.js";

View File

@ -2,7 +2,7 @@ import BattleScene, { PokeballCounts, bypassLogin } from "../battle-scene";
import Pokemon, { EnemyPokemon, PlayerPokemon } from "../field/pokemon"; import Pokemon, { EnemyPokemon, PlayerPokemon } from "../field/pokemon";
import { pokemonEvolutions, pokemonPrevolutions } from "../data/pokemon-evolutions"; import { pokemonEvolutions, pokemonPrevolutions } from "../data/pokemon-evolutions";
import PokemonSpecies, { allSpecies, getPokemonSpecies, noStarterFormKeys, speciesStarters } from "../data/pokemon-species"; import PokemonSpecies, { allSpecies, getPokemonSpecies, noStarterFormKeys, speciesStarters } from "../data/pokemon-species";
import { Species, defaultStarterSpecies, Moves, Device, PlayerGender, GameDataType } from "#enums"; import { Species, defaultStarterSpecies } from "../data/enums/species";
import * as Utils from "../utils"; import * as Utils from "../utils";
import * as Overrides from "../overrides"; import * as Overrides from "../overrides";
import PokemonData from "./pokemon-data"; import PokemonData from "./pokemon-data";
@ -24,6 +24,7 @@ import { clientSessionId, loggedInUser, updateUserInfo } from "../account";
import { Nature } from "../data/nature"; import { Nature } from "../data/nature";
import { GameStats } from "./game-stats"; import { GameStats } from "./game-stats";
import { Tutorial } from "../tutorial"; import { Tutorial } from "../tutorial";
import { Moves } from "../data/enums/moves";
import { speciesEggMoves } from "../data/egg-moves"; import { speciesEggMoves } from "../data/egg-moves";
import { allMoves } from "../data/move"; import { allMoves } from "../data/move";
import { TrainerVariant } from "../field/trainer"; import { TrainerVariant } from "../field/trainer";
@ -31,9 +32,12 @@ import { OutdatedPhase, ReloadSessionPhase } from "#app/phases";
import { Variant, variantData } from "#app/data/variant"; import { Variant, variantData } from "#app/data/variant";
import {setSettingGamepad, SettingGamepad, settingGamepadDefaults} from "./settings/settings-gamepad"; import {setSettingGamepad, SettingGamepad, settingGamepadDefaults} from "./settings/settings-gamepad";
import {setSettingKeyboard, SettingKeyboard} from "#app/system/settings/settings-keyboard"; import {setSettingKeyboard, SettingKeyboard} from "#app/system/settings/settings-keyboard";
import { TerrainChangedEvent, WeatherChangedEvent } from "#app/events/arena.js"; import { TerrainChangedEvent, WeatherChangedEvent } from "#app/field/events/arena";
import { Device } from "#app/enums/devices.js";
import { EnemyAttackStatusEffectChanceModifier } from "../modifier/modifier"; import { EnemyAttackStatusEffectChanceModifier } from "../modifier/modifier";
import { StatusEffect } from "#app/data/status-effect.js"; import { StatusEffect } from "#app/data/status-effect.js";
import { PlayerGender } from "#app/data/enums/player-gender";
import { GameDataType } from "#app/data/enums/game-data-type";
import ChallengeData from "./challenge-data"; import ChallengeData from "./challenge-data";
const saveKey = "x0i2O7WRiANTqPmZ"; // Temporary; secure encryption is not yet necessary const saveKey = "x0i2O7WRiANTqPmZ"; // Temporary; secure encryption is not yet necessary
@ -1209,11 +1213,9 @@ export class GameData {
reader.onload = (_ => { reader.onload = (_ => {
return e => { return e => {
let dataName: string;
let dataStr = AES.decrypt(e.target.result.toString(), saveKey).toString(enc.Utf8); let dataStr = AES.decrypt(e.target.result.toString(), saveKey).toString(enc.Utf8);
let valid = false; let valid = false;
try { try {
dataName = GameDataType[dataType].toLowerCase();
switch (dataType) { switch (dataType) {
case GameDataType.SYSTEM: case GameDataType.SYSTEM:
dataStr = this.convertSystemDataStr(dataStr); dataStr = this.convertSystemDataStr(dataStr);
@ -1233,12 +1235,28 @@ export class GameData {
console.error(ex); console.error(ex);
} }
let dataName: string;
switch (dataType) {
case GameDataType.SYSTEM:
dataName = "save";
break;
case GameDataType.SESSION:
dataName = "session";
break;
case GameDataType.SETTINGS:
dataName = "settings";
break;
case GameDataType.TUTORIALS:
dataName = "tutorials";
break;
}
const displayError = (error: string) => this.scene.ui.showText(error, null, () => this.scene.ui.showText(null, 0), Utils.fixedInt(1500)); const displayError = (error: string) => this.scene.ui.showText(error, null, () => this.scene.ui.showText(null, 0), Utils.fixedInt(1500));
if (!valid) { if (!valid) {
return this.scene.ui.showText(`Your ${dataName} data could not be loaded. It may be corrupted.`, null, () => this.scene.ui.showText(null, 0), Utils.fixedInt(1500)); return this.scene.ui.showText(`Your ${dataName} data could not be loaded. It may be corrupted.`, null, () => this.scene.ui.showText(null, 0), Utils.fixedInt(1500));
} }
this.scene.ui.revertMode();
this.scene.ui.showText(`Your ${dataName} data will be overridden and the page will reload. Proceed?`, null, () => { this.scene.ui.showText(`Your ${dataName} data will be overridden and the page will reload. Proceed?`, null, () => {
this.scene.ui.setOverlayMode(Mode.CONFIRM, () => { this.scene.ui.setOverlayMode(Mode.CONFIRM, () => {
localStorage.setItem(dataKey, encrypt(dataStr, bypassLogin)); localStorage.setItem(dataKey, encrypt(dataStr, bypassLogin));

View File

@ -1,13 +1,15 @@
import { BattleType } from "../battle"; import { BattleType } from "../battle";
import BattleScene from "../battle-scene"; import BattleScene from "../battle-scene";
import { Biome, Species, Moves } from "#enums"; import { Biome } from "../data/enums/biome";
import { Gender } from "../data/gender"; import { Gender } from "../data/gender";
import { Nature } from "../data/nature"; import { Nature } from "../data/nature";
import { PokeballType } from "../data/pokeball"; import { PokeballType } from "../data/pokeball";
import { getPokemonSpecies } from "../data/pokemon-species"; import { getPokemonSpecies } from "../data/pokemon-species";
import { Species } from "../data/enums/species";
import { Status } from "../data/status-effect"; import { Status } from "../data/status-effect";
import Pokemon, { EnemyPokemon, PokemonMove, PokemonSummonData } from "../field/pokemon"; import Pokemon, { EnemyPokemon, PokemonMove, PokemonSummonData } from "../field/pokemon";
import { TrainerSlot } from "../data/trainer-config"; import { TrainerSlot } from "../data/trainer-config";
import { Moves } from "../data/enums/moves";
import { Variant } from "#app/data/variant"; import { Variant } from "#app/data/variant";
import { loadBattlerTag } from "../data/battler-tags"; import { loadBattlerTag } from "../data/battler-tags";

View File

@ -2,7 +2,7 @@ import BattleScene from "../../battle-scene";
import SettingsGamepadUiHandler from "../../ui/settings/settings-gamepad-ui-handler"; import SettingsGamepadUiHandler from "../../ui/settings/settings-gamepad-ui-handler";
import {Mode} from "../../ui/ui"; import {Mode} from "../../ui/ui";
import {truncateString} from "../../utils"; import {truncateString} from "../../utils";
import {Button} from "#enums"; import {Button} from "../../enums/buttons";
import {SettingKeyboard} from "#app/system/settings/settings-keyboard"; import {SettingKeyboard} from "#app/system/settings/settings-keyboard";
export enum SettingGamepad { export enum SettingGamepad {

View File

@ -1,4 +1,4 @@
import {Button} from "#enums"; import {Button} from "#app/enums/buttons";
import BattleScene from "#app/battle-scene"; import BattleScene from "#app/battle-scene";
import {Mode} from "#app/ui/ui"; import {Mode} from "#app/ui/ui";
import SettingsKeyboardUiHandler from "#app/ui/settings/settings-keyboard-ui-handler"; import SettingsKeyboardUiHandler from "#app/ui/settings/settings-keyboard-ui-handler";

View File

@ -3,9 +3,11 @@ import i18next from "i18next";
import BattleScene from "../../battle-scene"; import BattleScene from "../../battle-scene";
import { hasTouchscreen } from "../../touch-controls"; import { hasTouchscreen } from "../../touch-controls";
import { updateWindowType } from "../../ui/ui-theme"; import { updateWindowType } from "../../ui/ui-theme";
import { PlayerGender, MoneyFormat, EaseType } from "#enums"; import { PlayerGender } from "#app/data/enums/player-gender";
import { CandyUpgradeNotificationChangedEvent } from "../../events/battle-scene"; import { CandyUpgradeNotificationChangedEvent } from "../../events/battle-scene";
import { MoneyFormat } from "../../enums/money-format";
import SettingsUiHandler from "#app/ui/settings/settings-ui-handler"; import SettingsUiHandler from "#app/ui/settings/settings-ui-handler";
import { EaseType } from "#app/ui/enums/ease-type.js";
const MUTE = "Mute"; const MUTE = "Mute";
const VOLUME_OPTIONS = new Array(11).fill(null).map((_, i) => i ? (i * 10).toString() : MUTE); const VOLUME_OPTIONS = new Array(11).fill(null).map((_, i) => i ? (i * 10).toString() : MUTE);

View File

@ -1,5 +1,5 @@
import BattleScene from "../battle-scene"; import BattleScene from "../battle-scene";
import { TrainerType } from "#enums"; import { TrainerType } from "../data/enums/trainer-type";
import Trainer, { TrainerVariant } from "../field/trainer"; import Trainer, { TrainerVariant } from "../field/trainer";
export default class TrainerData { export default class TrainerData {

View File

@ -1,7 +1,8 @@
import BattleScene from "../battle-scene"; import BattleScene from "../battle-scene";
import { TrainerType } from "../data/enums/trainer-type";
import i18next from "../plugins/i18n"; import i18next from "../plugins/i18n";
import { Achv, AchvTier, achvs, getAchievementDescription } from "./achv"; import { Achv, AchvTier, achvs, getAchievementDescription } from "./achv";
import { PlayerGender, TrainerType } from "#enums"; import { PlayerGender } from "#app/data/enums/player-gender";
export enum VoucherType { export enum VoucherType {
REGULAR, REGULAR,

View File

@ -2,9 +2,9 @@ import { afterEach, beforeAll, beforeEach, describe, expect, test, vi } from "vi
import GameManager from "#test/utils/gameManager"; import GameManager from "#test/utils/gameManager";
import { getMovePosition } from "#test/utils/gameManagerUtils"; import { getMovePosition } from "#test/utils/gameManagerUtils";
import * as Overrides from "#app/overrides"; import * as Overrides from "#app/overrides";
import { Moves } from "#enums"; import { Moves } from "#app/data/enums/moves.js";
import { Abilities } from "#enums"; import { Abilities } from "#app/data/enums/abilities.js";
import { Species } from "#enums"; import { Species } from "#app/data/enums/species.js";
import { Status, StatusEffect } from "#app/data/status-effect.js"; import { Status, StatusEffect } from "#app/data/status-effect.js";
import { TurnEndPhase } from "#app/phases.js"; import { TurnEndPhase } from "#app/phases.js";
import { QuietFormChangePhase } from "#app/form-change-phase.js"; import { QuietFormChangePhase } from "#app/form-change-phase.js";

View File

@ -2,9 +2,9 @@ import { afterEach, beforeAll, beforeEach, describe, expect, test, vi } from "vi
import GameManager from "#test/utils/gameManager"; import GameManager from "#test/utils/gameManager";
import { getMovePosition } from "#test/utils/gameManagerUtils"; import { getMovePosition } from "#test/utils/gameManagerUtils";
import * as Overrides from "#app/overrides"; import * as Overrides from "#app/overrides";
import { Moves } from "#enums"; import { Moves } from "#app/data/enums/moves.js";
import { Abilities } from "#enums"; import { Abilities } from "#app/data/enums/abilities.js";
import { Species } from "#enums"; import { Species } from "#app/data/enums/species.js";
import { Status, StatusEffect } from "#app/data/status-effect.js"; import { Status, StatusEffect } from "#app/data/status-effect.js";
import { TurnEndPhase } from "#app/phases.js"; import { TurnEndPhase } from "#app/phases.js";
import { QuietFormChangePhase } from "#app/form-change-phase.js"; import { QuietFormChangePhase } from "#app/form-change-phase.js";

View File

@ -2,7 +2,8 @@ import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import * as overrides from "#app/overrides"; import * as overrides from "#app/overrides";
import {Abilities, Species, Moves} from "#enums"; import {Abilities} from "#app/data/enums/abilities";
import {Species} from "#app/data/enums/species";
import { import {
CommandPhase, DamagePhase, EncounterPhase, CommandPhase, DamagePhase, EncounterPhase,
EnemyCommandPhase, SelectStarterPhase, EnemyCommandPhase, SelectStarterPhase,
@ -10,6 +11,7 @@ import {
} from "#app/phases"; } from "#app/phases";
import {Mode} from "#app/ui/ui"; import {Mode} from "#app/ui/ui";
import {BattleStat} from "#app/data/battle-stat"; import {BattleStat} from "#app/data/battle-stat";
import {Moves} from "#app/data/enums/moves";
import {generateStarter, getMovePosition} from "#app/test/utils/gameManagerUtils"; import {generateStarter, getMovePosition} from "#app/test/utils/gameManagerUtils";
import {Command} from "#app/ui/command-ui-handler"; import {Command} from "#app/ui/command-ui-handler";
import {Status, StatusEffect} from "#app/data/status-effect"; import {Status, StatusEffect} from "#app/data/status-effect";

View File

@ -2,7 +2,8 @@ import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import * as overrides from "#app/overrides"; import * as overrides from "#app/overrides";
import {Abilities, Species} from "#enums"; import {Abilities} from "#app/data/enums/abilities";
import {Species} from "#app/data/enums/species";
import { import {
CommandPhase, CommandPhase,
} from "#app/phases"; } from "#app/phases";

View File

@ -2,16 +2,16 @@ import Phaser from "phaser";
import { afterEach, beforeAll, beforeEach, describe, expect, test, vi } from "vitest"; import { afterEach, beforeAll, beforeEach, describe, expect, test, vi } from "vitest";
import GameManager from "../utils/gameManager"; import GameManager from "../utils/gameManager";
import * as Overrides from "#app/overrides"; import * as Overrides from "#app/overrides";
import { Species } from "#enums"; import { Species } from "#app/data/enums/species.js";
import { Abilities } from "#enums"; import { Abilities } from "#app/data/enums/abilities.js";
import { Moves } from "#enums"; import { Moves } from "#app/data/enums/moves.js";
import { getMovePosition } from "../utils/gameManagerUtils"; import { getMovePosition } from "../utils/gameManagerUtils";
import { MoveEffectPhase, TurnEndPhase } from "#app/phases.js"; import { MoveEffectPhase, TurnEndPhase } from "#app/phases.js";
import { allMoves } from "#app/data/move.js"; import { allMoves } from "#app/data/move.js";
import { BattlerTagType } from "#enums"; import { BattlerTagType } from "#app/data/enums/battler-tag-type.js";
import { Weather, WeatherType } from "#app/data/weather.js"; import { Weather, WeatherType } from "#app/data/weather.js";
import { Type } from "#app/data/type.js"; import { Type } from "#app/data/type.js";
import { Biome } from "#enums"; import { Biome } from "#app/data/enums/biome.js";
import { PlayerPokemon } from "#app/field/pokemon.js"; import { PlayerPokemon } from "#app/field/pokemon.js";
const TIMEOUT = 20 * 1000; const TIMEOUT = 20 * 1000;

View File

@ -2,7 +2,8 @@ import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import * as overrides from "#app/overrides"; import * as overrides from "#app/overrides";
import {Abilities, Moves, Species} from "#enums"; import {Abilities} from "#app/data/enums/abilities";
import {Species} from "#app/data/enums/species";
import { import {
CommandPhase, CommandPhase,
EnemyCommandPhase, EnemyCommandPhase,
@ -10,6 +11,7 @@ import {
} from "#app/phases"; } from "#app/phases";
import {Mode} from "#app/ui/ui"; import {Mode} from "#app/ui/ui";
import {Stat} from "#app/data/pokemon-stat"; import {Stat} from "#app/data/pokemon-stat";
import {Moves} from "#app/data/enums/moves";
import {getMovePosition} from "#app/test/utils/gameManagerUtils"; import {getMovePosition} from "#app/test/utils/gameManagerUtils";
import {Command} from "#app/ui/command-ui-handler"; import {Command} from "#app/ui/command-ui-handler";
import {BattleStat} from "#app/data/battle-stat"; import {BattleStat} from "#app/data/battle-stat";

View File

@ -2,9 +2,9 @@ import { afterEach, beforeAll, beforeEach, describe, expect, test, vi } from "vi
import GameManager from "#test/utils/gameManager"; import GameManager from "#test/utils/gameManager";
import { getMovePosition } from "#test/utils/gameManagerUtils"; import { getMovePosition } from "#test/utils/gameManagerUtils";
import * as Overrides from "#app/overrides"; import * as Overrides from "#app/overrides";
import { Moves } from "#enums"; import { Moves } from "#app/data/enums/moves.js";
import { Abilities } from "#enums"; import { Abilities } from "#app/data/enums/abilities.js";
import { Species } from "#enums"; import { Species } from "#app/data/enums/species.js";
import { Status, StatusEffect } from "#app/data/status-effect.js"; import { Status, StatusEffect } from "#app/data/status-effect.js";
import { TurnEndPhase } from "#app/phases.js"; import { TurnEndPhase } from "#app/phases.js";
import { QuietFormChangePhase } from "#app/form-change-phase.js"; import { QuietFormChangePhase } from "#app/form-change-phase.js";

View File

@ -2,16 +2,16 @@ import Phaser from "phaser";
import { afterEach, beforeAll, beforeEach, describe, expect, test, vi } from "vitest"; import { afterEach, beforeAll, beforeEach, describe, expect, test, vi } from "vitest";
import GameManager from "../utils/gameManager"; import GameManager from "../utils/gameManager";
import * as Overrides from "#app/overrides"; import * as Overrides from "#app/overrides";
import { Species } from "#enums"; import { Species } from "#app/data/enums/species.js";
import { Abilities } from "#enums"; import { Abilities } from "#app/data/enums/abilities.js";
import { Moves } from "#enums"; import { Moves } from "#app/data/enums/moves.js";
import { getMovePosition } from "../utils/gameManagerUtils"; import { getMovePosition } from "../utils/gameManagerUtils";
import { MoveEffectPhase, TurnEndPhase } from "#app/phases.js"; import { MoveEffectPhase, TurnEndPhase } from "#app/phases.js";
import { allMoves } from "#app/data/move.js"; import { allMoves } from "#app/data/move.js";
import { BattlerTagType } from "#enums"; import { BattlerTagType } from "#app/data/enums/battler-tag-type.js";
import { Weather, WeatherType } from "#app/data/weather.js"; import { Weather, WeatherType } from "#app/data/weather.js";
import { Type } from "#app/data/type.js"; import { Type } from "#app/data/type.js";
import { Biome } from "#enums"; import { Biome } from "#app/data/enums/biome.js";
import { PlayerPokemon } from "#app/field/pokemon.js"; import { PlayerPokemon } from "#app/field/pokemon.js";
const TIMEOUT = 20 * 1000; const TIMEOUT = 20 * 1000;

View File

@ -2,16 +2,19 @@ import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import * as overrides from "#app/overrides"; import * as overrides from "#app/overrides";
import {Species} from "#app/data/enums/species";
import { import {
CommandPhase, CommandPhase,
EnemyCommandPhase, MoveEndPhase, TurnEndPhase, EnemyCommandPhase, MoveEndPhase, TurnEndPhase,
} from "#app/phases"; } from "#app/phases";
import {Mode} from "#app/ui/ui"; import {Mode} from "#app/ui/ui";
import {Moves} from "#app/data/enums/moves";
import {getMovePosition} from "#app/test/utils/gameManagerUtils"; import {getMovePosition} from "#app/test/utils/gameManagerUtils";
import {Command} from "#app/ui/command-ui-handler"; import {Command} from "#app/ui/command-ui-handler";
import { Abilities, BattlerTagType, Moves, Species } from "#enums"; import { Abilities } from "#app/data/enums/abilities.js";
import { BattleStat } from "#app/data/battle-stat.js"; import { BattleStat } from "#app/data/battle-stat.js";
import { TerrainType } from "#app/data/terrain.js"; import { TerrainType } from "#app/data/terrain.js";
import { BattlerTagType } from "#app/data/enums/battler-tag-type.js";
// See also: TypeImmunityAbAttr // See also: TypeImmunityAbAttr
describe("Abilities - Sap Sipper", () => { describe("Abilities - Sap Sipper", () => {

View File

@ -2,9 +2,9 @@ import { afterEach, beforeAll, beforeEach, describe, expect, test, vi } from "vi
import GameManager from "#test/utils/gameManager"; import GameManager from "#test/utils/gameManager";
import { getMovePosition } from "#test/utils/gameManagerUtils"; import { getMovePosition } from "#test/utils/gameManagerUtils";
import * as Overrides from "#app/overrides"; import * as Overrides from "#app/overrides";
import { Moves } from "#enums"; import { Moves } from "#app/data/enums/moves.js";
import { Abilities } from "#enums"; import { Abilities } from "#app/data/enums/abilities.js";
import { Species } from "#enums"; import { Species } from "#app/data/enums/species.js";
import { Status, StatusEffect } from "#app/data/status-effect.js"; import { Status, StatusEffect } from "#app/data/status-effect.js";
import { TurnEndPhase } from "#app/phases.js"; import { TurnEndPhase } from "#app/phases.js";
import { QuietFormChangePhase } from "#app/form-change-phase.js"; import { QuietFormChangePhase } from "#app/form-change-phase.js";

View File

@ -2,9 +2,9 @@ import { afterEach, beforeAll, beforeEach, describe, expect, test, vi } from "vi
import GameManager from "#test/utils/gameManager"; import GameManager from "#test/utils/gameManager";
import { getMovePosition } from "#test/utils/gameManagerUtils"; import { getMovePosition } from "#test/utils/gameManagerUtils";
import * as Overrides from "#app/overrides"; import * as Overrides from "#app/overrides";
import { Moves } from "#enums"; import { Moves } from "#app/data/enums/moves.js";
import { Abilities } from "#enums"; import { Abilities } from "#app/data/enums/abilities.js";
import { Species } from "#enums"; import { Species } from "#app/data/enums/species.js";
import { Status, StatusEffect } from "#app/data/status-effect.js"; import { Status, StatusEffect } from "#app/data/status-effect.js";
import { TurnEndPhase } from "#app/phases.js"; import { TurnEndPhase } from "#app/phases.js";
import { QuietFormChangePhase } from "#app/form-change-phase.js"; import { QuietFormChangePhase } from "#app/form-change-phase.js";

View File

@ -2,12 +2,15 @@ import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import * as overrides from "#app/overrides"; import * as overrides from "#app/overrides";
import {Species} from "#app/data/enums/species";
import { import {
TurnEndPhase, TurnEndPhase,
} from "#app/phases"; } from "#app/phases";
import {Moves} from "#app/data/enums/moves";
import {getMovePosition} from "#app/test/utils/gameManagerUtils"; import {getMovePosition} from "#app/test/utils/gameManagerUtils";
import { Abilities, BattlerTagType, Moves, Species } from "#enums"; import { Abilities } from "#app/data/enums/abilities.js";
import { BattleStat } from "#app/data/battle-stat.js"; import { BattleStat } from "#app/data/battle-stat.js";
import { BattlerTagType } from "#app/data/enums/battler-tag-type.js";
// See also: TypeImmunityAbAttr // See also: TypeImmunityAbAttr
describe("Abilities - Volt Absorb", () => { describe("Abilities - Volt Absorb", () => {

View File

@ -2,6 +2,8 @@ import { afterEach, beforeAll, beforeEach, describe, expect, test, vi } from "vi
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import * as Overrides from "#app/overrides"; import * as Overrides from "#app/overrides";
import { Abilities } from "#app/data/enums/abilities";
import { Species } from "#app/data/enums/species";
import { import {
CommandPhase, CommandPhase,
DamagePhase, DamagePhase,
@ -16,7 +18,7 @@ import {
} from "#app/phases"; } from "#app/phases";
import { Mode } from "#app/ui/ui"; import { Mode } from "#app/ui/ui";
import { Stat } from "#app/data/pokemon-stat"; import { Stat } from "#app/data/pokemon-stat";
import { Abilities, Moves, Species } from "#enums"; import { Moves } from "#app/data/enums/moves";
import { getMovePosition } from "#app/test/utils/gameManagerUtils"; import { getMovePosition } from "#app/test/utils/gameManagerUtils";
import { Command } from "#app/ui/command-ui-handler"; import { Command } from "#app/ui/command-ui-handler";
import { QuietFormChangePhase } from "#app/form-change-phase"; import { QuietFormChangePhase } from "#app/form-change-phase";

View File

@ -2,9 +2,9 @@ import { afterEach, beforeAll, beforeEach, describe, expect, test, vi } from "vi
import GameManager from "#test/utils/gameManager"; import GameManager from "#test/utils/gameManager";
import { getMovePosition } from "#test/utils/gameManagerUtils"; import { getMovePosition } from "#test/utils/gameManagerUtils";
import * as Overrides from "#app/overrides"; import * as Overrides from "#app/overrides";
import { Moves } from "#enums"; import { Moves } from "#app/data/enums/moves.js";
import { Abilities } from "#enums"; import { Abilities } from "#app/data/enums/abilities.js";
import { Species } from "#enums"; import { Species } from "#app/data/enums/species.js";
import { Status, StatusEffect } from "#app/data/status-effect.js"; import { Status, StatusEffect } from "#app/data/status-effect.js";
import { TurnEndPhase } from "#app/phases.js"; import { TurnEndPhase } from "#app/phases.js";
import { QuietFormChangePhase } from "#app/form-change-phase.js"; import { QuietFormChangePhase } from "#app/form-change-phase.js";

View File

@ -2,16 +2,19 @@ import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import * as overrides from "#app/overrides"; import * as overrides from "#app/overrides";
import {Abilities, Species, Moves, Button} from "#enums"; import {Abilities} from "#app/data/enums/abilities";
import {Species} from "#app/data/enums/species";
import { import {
CommandPhase, EnemyCommandPhase, SelectTargetPhase, CommandPhase, EnemyCommandPhase, SelectTargetPhase,
TurnStartPhase TurnStartPhase
} from "#app/phases"; } from "#app/phases";
import {Mode} from "#app/ui/ui"; import {Mode} from "#app/ui/ui";
import {getMovePosition} from "#app/test/utils/gameManagerUtils"; import {getMovePosition} from "#app/test/utils/gameManagerUtils";
import {Moves} from "#app/data/enums/moves";
import {Command} from "#app/ui/command-ui-handler"; import {Command} from "#app/ui/command-ui-handler";
import {Stat} from "#app/data/pokemon-stat"; import {Stat} from "#app/data/pokemon-stat";
import TargetSelectUiHandler from "#app/ui/target-select-ui-handler"; import TargetSelectUiHandler from "#app/ui/target-select-ui-handler";
import {Button} from "#app/enums/buttons";
describe("Battle order", () => { describe("Battle order", () => {

View File

@ -2,7 +2,7 @@ import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest
import {generateStarter, getMovePosition,} from "#app/test/utils/gameManagerUtils"; import {generateStarter, getMovePosition,} from "#app/test/utils/gameManagerUtils";
import {Mode} from "#app/ui/ui"; import {Mode} from "#app/ui/ui";
import {GameModes} from "#app/game-mode"; import {GameModes} from "#app/game-mode";
import {Species, Moves, PlayerGender, Abilities} from "#enums"; import {Species} from "#app/data/enums/species";
import * as overrides from "../../overrides"; import * as overrides from "../../overrides";
import {Command} from "#app/ui/command-ui-handler"; import {Command} from "#app/ui/command-ui-handler";
import { import {
@ -17,10 +17,13 @@ import {
TitlePhase, TitlePhase,
TurnInitPhase, VictoryPhase, TurnInitPhase, VictoryPhase,
} from "#app/phases"; } from "#app/phases";
import {Moves} from "#app/data/enums/moves";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import Phaser from "phaser"; import Phaser from "phaser";
import {allSpecies} from "#app/data/pokemon-species"; import {allSpecies} from "#app/data/pokemon-species";
import {PlayerGender} from "#app/data/enums/player-gender";
import { getGameMode } from "#app/game-mode.js"; import { getGameMode } from "#app/game-mode.js";
import {Abilities} from "#app/data/enums/abilities";
describe("Test Battle Phase", () => { describe("Test Battle Phase", () => {
let phaserGame: Phaser.Game; let phaserGame: Phaser.Game;

View File

@ -2,7 +2,9 @@ import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import Phaser from "phaser"; import Phaser from "phaser";
import * as overrides from "#app/overrides"; import * as overrides from "#app/overrides";
import {Species, Moves, Abilities} from "#enums"; import {Species} from "#app/data/enums/species";
import {Moves} from "#app/data/enums/moves";
import {Abilities} from "#app/data/enums/abilities";
describe("Test Battle Phase", () => { describe("Test Battle Phase", () => {
let phaserGame: Phaser.Game; let phaserGame: Phaser.Game;

View File

@ -1,12 +1,14 @@
import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest"; import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest";
import {Mode} from "#app/ui/ui"; import {Mode} from "#app/ui/ui";
import {Species, Moves, Abilities} from "#enums"; import {Species} from "#app/data/enums/species";
import * as overrides from "../../overrides"; import * as overrides from "../../overrides";
import { import {
CommandPhase, CommandPhase,
} from "#app/phases"; } from "#app/phases";
import {Moves} from "#app/data/enums/moves";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import Phaser from "phaser"; import Phaser from "phaser";
import {Abilities} from "#app/data/enums/abilities";
describe("Test Battle Phase", () => { describe("Test Battle Phase", () => {
let phaserGame: Phaser.Game; let phaserGame: Phaser.Game;

View File

@ -1,7 +1,7 @@
import {beforeAll, describe, expect, it} from "vitest"; import {beforeAll, describe, expect, it} from "vitest";
import BattleScene from "../../battle-scene"; import BattleScene from "../../battle-scene";
import { getLegendaryGachaSpeciesForTimestamp } from "#app/data/egg.js"; import { getLegendaryGachaSpeciesForTimestamp } from "#app/data/egg.js";
import { Species } from "#enums"; import { Species } from "#app/data/enums/species.js";
import Phaser from "phaser"; import Phaser from "phaser";
describe("getLegendaryGachaSpeciesForTimestamp", () => { describe("getLegendaryGachaSpeciesForTimestamp", () => {

View File

@ -5,7 +5,7 @@ async function importModule() {
try { try {
initStatsKeys(); initStatsKeys();
const { PokemonMove } = await import("#app/field/pokemon"); const { PokemonMove } = await import("#app/field/pokemon");
const { Species } = await import("#enums"); const { Species } = await import("#app/data/enums/species");
return { return {
PokemonMove, PokemonMove,
Species, Species,

View File

@ -2,7 +2,8 @@ import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import * as overrides from "#app/overrides"; import * as overrides from "#app/overrides";
import {Abilities, Moves, Species} from "#enums"; import {Abilities} from "#app/data/enums/abilities";
import {Species} from "#app/data/enums/species";
import { import {
CommandPhase, CommandPhase,
EnemyCommandPhase, EnemyCommandPhase,
@ -10,6 +11,7 @@ import {
TurnEndPhase, TurnEndPhase,
} from "#app/phases"; } from "#app/phases";
import {Mode} from "#app/ui/ui"; import {Mode} from "#app/ui/ui";
import {Moves} from "#app/data/enums/moves";
import {getMovePosition} from "#app/test/utils/gameManagerUtils"; import {getMovePosition} from "#app/test/utils/gameManagerUtils";
import {Command} from "#app/ui/command-ui-handler"; import {Command} from "#app/ui/command-ui-handler";
import {StatusEffect} from "#app/data/status-effect"; import {StatusEffect} from "#app/data/status-effect";

View File

@ -1,7 +1,7 @@
import {afterEach, beforeAll, describe, expect, it} from "vitest"; import {afterEach, beforeAll, describe, expect, it} from "vitest";
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import {Species} from "#enums"; import {Species} from "#app/data/enums/species";
import i18next from "i18next"; import i18next from "i18next";
import {initI18n} from "#app/plugins/i18n"; import {initI18n} from "#app/plugins/i18n";

View File

@ -2,7 +2,8 @@ import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import * as overrides from "#app/overrides"; import * as overrides from "#app/overrides";
import {Abilities, Moves, Species} from "#enums"; import {Abilities} from "#app/data/enums/abilities";
import {Species} from "#app/data/enums/species";
import { import {
CommandPhase, CommandPhase,
EnemyCommandPhase, EnemyCommandPhase,
@ -10,6 +11,7 @@ import {
} from "#app/phases"; } from "#app/phases";
import {Mode} from "#app/ui/ui"; import {Mode} from "#app/ui/ui";
import {Stat} from "#app/data/pokemon-stat"; import {Stat} from "#app/data/pokemon-stat";
import {Moves} from "#app/data/enums/moves";
import {getMovePosition} from "#app/test/utils/gameManagerUtils"; import {getMovePosition} from "#app/test/utils/gameManagerUtils";
import {Command} from "#app/ui/command-ui-handler"; import {Command} from "#app/ui/command-ui-handler";
import {BattleStat} from "#app/data/battle-stat"; import {BattleStat} from "#app/data/battle-stat";

View File

@ -2,10 +2,12 @@ import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import * as overrides from "#app/overrides"; import * as overrides from "#app/overrides";
import {Abilities, Moves, Species} from "#enums"; import {Abilities} from "#app/data/enums/abilities";
import {Species} from "#app/data/enums/species";
import { import {
CommandPhase CommandPhase
} from "#app/phases"; } from "#app/phases";
import {Moves} from "#app/data/enums/moves";
describe("Moves - Spikes", () => { describe("Moves - Spikes", () => {

View File

@ -2,12 +2,13 @@ import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import * as overrides from "#app/overrides"; import * as overrides from "#app/overrides";
import {Moves, Species} from "#enums"; import {Species} from "#app/data/enums/species";
import { import {
CommandPhase, CommandPhase,
EnemyCommandPhase, TurnEndPhase, EnemyCommandPhase, TurnEndPhase,
} from "#app/phases"; } from "#app/phases";
import {Mode} from "#app/ui/ui"; import {Mode} from "#app/ui/ui";
import {Moves} from "#app/data/enums/moves";
import {getMovePosition} from "#app/test/utils/gameManagerUtils"; import {getMovePosition} from "#app/test/utils/gameManagerUtils";
import {Command} from "#app/ui/command-ui-handler"; import {Command} from "#app/ui/command-ui-handler";
import {Stat} from "#app/data/pokemon-stat"; import {Stat} from "#app/data/pokemon-stat";

View File

@ -2,13 +2,15 @@ import {afterEach, beforeAll, beforeEach, describe, expect, it, vi} from "vitest
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import * as overrides from "#app/overrides"; import * as overrides from "#app/overrides";
import {Abilities, Moves, Species} from "#enums"; import {Abilities} from "#app/data/enums/abilities";
import {Species} from "#app/data/enums/species";
import { import {
CommandPhase, CommandPhase,
EnemyCommandPhase, EnemyCommandPhase,
TurnInitPhase, TurnInitPhase,
} from "#app/phases"; } from "#app/phases";
import {Mode} from "#app/ui/ui"; import {Mode} from "#app/ui/ui";
import {Moves} from "#app/data/enums/moves";
import {getMovePosition} from "#app/test/utils/gameManagerUtils"; import {getMovePosition} from "#app/test/utils/gameManagerUtils";
import {Command} from "#app/ui/command-ui-handler"; import {Command} from "#app/ui/command-ui-handler";
import {BattleStat} from "#app/data/battle-stat"; import {BattleStat} from "#app/data/battle-stat";

View File

@ -1,5 +1,5 @@
import {beforeEach, describe, expect, it} from "vitest"; import {beforeEach, describe, expect, it} from "vitest";
import {Button, Device} from "#enums"; import {Button} from "#app/enums/buttons";
import {deepCopy} from "#app/utils"; import {deepCopy} from "#app/utils";
import { import {
getKeyWithKeycode, getKeyWithKeycode,
@ -7,6 +7,7 @@ import {
} from "#app/configs/inputs/configHandler"; } from "#app/configs/inputs/configHandler";
import {MenuManip} from "#app/test/settingMenu/helpers/menuManip"; import {MenuManip} from "#app/test/settingMenu/helpers/menuManip";
import {InGameManip} from "#app/test/settingMenu/helpers/inGameManip"; import {InGameManip} from "#app/test/settingMenu/helpers/inGameManip";
import {Device} from "#app/enums/devices";
import {InterfaceConfig} from "#app/inputs-controller"; import {InterfaceConfig} from "#app/inputs-controller";
import cfg_keyboard_qwerty from "#app/configs/inputs/cfg_keyboard_qwerty"; import cfg_keyboard_qwerty from "#app/configs/inputs/cfg_keyboard_qwerty";
import {SettingKeyboard} from "#app/system/settings/settings-keyboard"; import {SettingKeyboard} from "#app/system/settings/settings-keyboard";

View File

@ -1,6 +1,7 @@
import {afterEach, beforeAll, beforeEach, describe, expect, it} from "vitest"; import {afterEach, beforeAll, beforeEach, describe, expect, it} from "vitest";
import Phaser from "phaser"; import Phaser from "phaser";
import GameManager from "#app/test/utils/gameManager"; import GameManager from "#app/test/utils/gameManager";
import {Species} from "#app/data/enums/species";
import { import {
EncounterPhase, EncounterPhase,
SelectStarterPhase, SelectStarterPhase,
@ -9,13 +10,14 @@ import {
import {Mode} from "#app/ui/ui"; import {Mode} from "#app/ui/ui";
import {GameModes} from "#app/game-mode"; import {GameModes} from "#app/game-mode";
import StarterSelectUiHandler from "#app/ui/starter-select-ui-handler"; import StarterSelectUiHandler from "#app/ui/starter-select-ui-handler";
import {Button} from "#app/enums/buttons";
import OptionSelectUiHandler from "#app/ui/settings/option-select-ui-handler"; import OptionSelectUiHandler from "#app/ui/settings/option-select-ui-handler";
import SaveSlotSelectUiHandler from "#app/ui/save-slot-select-ui-handler"; import SaveSlotSelectUiHandler from "#app/ui/save-slot-select-ui-handler";
import {OptionSelectItem} from "#app/ui/abstact-option-select-ui-handler"; import {OptionSelectItem} from "#app/ui/abstact-option-select-ui-handler";
import {Gender} from "#app/data/gender"; import {Gender} from "#app/data/gender";
import {allSpecies} from "#app/data/pokemon-species"; import {allSpecies} from "#app/data/pokemon-species";
import {Nature} from "#app/data/nature"; import {Nature} from "#app/data/nature";
import {Abilities, Button, Species} from "#enums"; import {Abilities} from "#app/data/enums/abilities";
describe("UI - Starter select", () => { describe("UI - Starter select", () => {

Some files were not shown because too many files have changed in this diff Show More