mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-06-21 00:52:47 +02:00
Moved files around + fixed stuff
This commit is contained in:
parent
95690be3c9
commit
4fa850d924
41
src/@types/illusion-data.ts
Normal file
41
src/@types/illusion-data.ts
Normal file
@ -0,0 +1,41 @@
|
|||||||
|
import type { Gender } from "#app/data/gender";
|
||||||
|
import type PokemonSpecies from "#app/data/pokemon-species";
|
||||||
|
import type { Variant } from "#app/sprites/variant";
|
||||||
|
import type { PokeballType } from "#enums/pokeball";
|
||||||
|
import type { Species } from "#enums/species";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Data pertaining to this Pokemon's Illusion.
|
||||||
|
*/
|
||||||
|
export interface IllusionData {
|
||||||
|
basePokemon: {
|
||||||
|
/** The actual name of the Pokemon */
|
||||||
|
name: string;
|
||||||
|
/** The actual nickname of the Pokemon */
|
||||||
|
nickname: string;
|
||||||
|
/** Whether the base pokemon is shiny or not */
|
||||||
|
shiny: boolean;
|
||||||
|
/** The shiny variant of the base pokemon */
|
||||||
|
variant: Variant;
|
||||||
|
/** Whether the fusion species of the base pokemon is shiny or not */
|
||||||
|
fusionShiny: boolean;
|
||||||
|
/** The variant of the fusion species of the base pokemon */
|
||||||
|
fusionVariant: Variant;
|
||||||
|
};
|
||||||
|
/** The species of the illusion */
|
||||||
|
species: Species;
|
||||||
|
/** The formIndex of the illusion */
|
||||||
|
formIndex: number;
|
||||||
|
/** The gender of the illusion */
|
||||||
|
gender: Gender;
|
||||||
|
/** The pokeball of the illusion */
|
||||||
|
pokeball: PokeballType;
|
||||||
|
/** The fusion species of the illusion if it's a fusion */
|
||||||
|
fusionSpecies?: PokemonSpecies;
|
||||||
|
/** The fusionFormIndex of the illusion */
|
||||||
|
fusionFormIndex?: number;
|
||||||
|
/** The fusionGender of the illusion if it's a fusion */
|
||||||
|
fusionGender?: Gender;
|
||||||
|
/** The level of the illusion (not used currently) */
|
||||||
|
level?: number;
|
||||||
|
}
|
@ -45,7 +45,7 @@ import { BattlerIndex } from "#app/battle";
|
|||||||
import { Moves } from "#enums/moves";
|
import { Moves } from "#enums/moves";
|
||||||
import { EncounterBattleAnim } from "#app/data/battle-anims";
|
import { EncounterBattleAnim } from "#app/data/battle-anims";
|
||||||
import { MoveCategory } from "#enums/MoveCategory";
|
import { MoveCategory } from "#enums/MoveCategory";
|
||||||
import { CustomPokemonData } from "#app/@types/pokemon-data";
|
import { CustomPokemonData } from "#app/data/pokemon/pokemon-data";
|
||||||
import { CLASSIC_MODE_MYSTERY_ENCOUNTER_WAVES } from "#app/constants";
|
import { CLASSIC_MODE_MYSTERY_ENCOUNTER_WAVES } from "#app/constants";
|
||||||
import { EncounterAnim } from "#enums/encounter-anims";
|
import { EncounterAnim } from "#enums/encounter-anims";
|
||||||
import { Challenges } from "#enums/challenges";
|
import { Challenges } from "#enums/challenges";
|
||||||
|
@ -29,7 +29,7 @@ import { MysteryEncounterOptionMode } from "#enums/mystery-encounter-option-mode
|
|||||||
import { PartyHealPhase } from "#app/phases/party-heal-phase";
|
import { PartyHealPhase } from "#app/phases/party-heal-phase";
|
||||||
import { BerryType } from "#enums/berry-type";
|
import { BerryType } from "#enums/berry-type";
|
||||||
import { Stat } from "#enums/stat";
|
import { Stat } from "#enums/stat";
|
||||||
import { CustomPokemonData } from "#app/@types/pokemon-data";
|
import { CustomPokemonData } from "#app/data/pokemon/pokemon-data";
|
||||||
import { randSeedInt } from "#app/utils/common";
|
import { randSeedInt } from "#app/utils/common";
|
||||||
|
|
||||||
/** i18n namespace for the encounter */
|
/** i18n namespace for the encounter */
|
||||||
|
@ -25,7 +25,7 @@ import { BattlerIndex } from "#app/battle";
|
|||||||
import { BattlerTagType } from "#enums/battler-tag-type";
|
import { BattlerTagType } from "#enums/battler-tag-type";
|
||||||
import { BerryType } from "#enums/berry-type";
|
import { BerryType } from "#enums/berry-type";
|
||||||
import { MysteryEncounterTier } from "#enums/mystery-encounter-tier";
|
import { MysteryEncounterTier } from "#enums/mystery-encounter-tier";
|
||||||
import { CustomPokemonData } from "#app/@types/pokemon-data";
|
import { CustomPokemonData } from "#app/data/pokemon/pokemon-data";
|
||||||
import { Stat } from "#enums/stat";
|
import { Stat } from "#enums/stat";
|
||||||
import { StatStageChangePhase } from "#app/phases/stat-stage-change-phase";
|
import { StatStageChangePhase } from "#app/phases/stat-stage-change-phase";
|
||||||
import { CLASSIC_MODE_MYSTERY_ENCOUNTER_WAVES } from "#app/constants";
|
import { CLASSIC_MODE_MYSTERY_ENCOUNTER_WAVES } from "#app/constants";
|
||||||
|
@ -49,7 +49,7 @@ import { TrainerSlot } from "#enums/trainer-slot";
|
|||||||
import type PokemonSpecies from "#app/data/pokemon-species";
|
import type PokemonSpecies from "#app/data/pokemon-species";
|
||||||
import type { IEggOptions } from "#app/data/egg";
|
import type { IEggOptions } from "#app/data/egg";
|
||||||
import { Egg } from "#app/data/egg";
|
import { Egg } from "#app/data/egg";
|
||||||
import type { CustomPokemonData } from "#app/@types/pokemon-data";
|
import type { CustomPokemonData } from "#app/data/pokemon/pokemon-data";
|
||||||
import type HeldModifierConfig from "#app/interfaces/held-modifier-config";
|
import type HeldModifierConfig from "#app/interfaces/held-modifier-config";
|
||||||
import { MovePhase } from "#app/phases/move-phase";
|
import { MovePhase } from "#app/phases/move-phase";
|
||||||
import { EggLapsePhase } from "#app/phases/egg-lapse-phase";
|
import { EggLapsePhase } from "#app/phases/egg-lapse-phase";
|
||||||
|
@ -34,7 +34,7 @@ import { Gender } from "#app/data/gender";
|
|||||||
import type { PermanentStat } from "#enums/stat";
|
import type { PermanentStat } from "#enums/stat";
|
||||||
import { VictoryPhase } from "#app/phases/victory-phase";
|
import { VictoryPhase } from "#app/phases/victory-phase";
|
||||||
import { SummaryUiMode } from "#app/ui/summary-ui-handler";
|
import { SummaryUiMode } from "#app/ui/summary-ui-handler";
|
||||||
import { CustomPokemonData } from "#app/@types/pokemon-data";
|
import { CustomPokemonData } from "#app/data/pokemon/pokemon-data";
|
||||||
import type { Abilities } from "#enums/abilities";
|
import type { Abilities } from "#enums/abilities";
|
||||||
import type { PokeballType } from "#enums/pokeball";
|
import type { PokeballType } from "#enums/pokeball";
|
||||||
import { StatusEffect } from "#enums/status-effect";
|
import { StatusEffect } from "#enums/status-effect";
|
||||||
|
@ -1,20 +1,17 @@
|
|||||||
import { type BattlerTag, loadBattlerTag } from "#app/data/battler-tags";
|
import { type BattlerTag, loadBattlerTag } from "#app/data/battler-tags";
|
||||||
import type { Gender } from "#app/data/gender";
|
import type { Gender } from "#app/data/gender";
|
||||||
import type PokemonSpecies from "#app/data/pokemon-species";
|
|
||||||
import type { PokemonSpeciesForm } from "#app/data/pokemon-species";
|
import type { PokemonSpeciesForm } from "#app/data/pokemon-species";
|
||||||
import type { TypeDamageMultiplier } from "#app/data/type";
|
import type { TypeDamageMultiplier } from "#app/data/type";
|
||||||
import type { Variant } from "#app/sprites/variant";
|
|
||||||
import { isNullOrUndefined } from "#app/utils/common";
|
import { isNullOrUndefined } from "#app/utils/common";
|
||||||
import type { Abilities } from "#enums/abilities";
|
import type { Abilities } from "#enums/abilities";
|
||||||
import type { BerryType } from "#enums/berry-type";
|
import type { BerryType } from "#enums/berry-type";
|
||||||
import type { Moves } from "#enums/moves";
|
import type { Moves } from "#enums/moves";
|
||||||
import type { PokeballType } from "#enums/pokeball";
|
|
||||||
import type { PokemonType } from "#enums/pokemon-type";
|
import type { PokemonType } from "#enums/pokemon-type";
|
||||||
import type { Species } from "#enums/species";
|
|
||||||
import { PokemonMove } from "#app/field/pokemon";
|
import { PokemonMove } from "#app/field/pokemon";
|
||||||
import type { TurnMove } from "#app/@types/turn-move";
|
import type { TurnMove } from "#app/@types/turn-move";
|
||||||
import type { AttackMoveResult } from "#app/@types/attack-move-result";
|
import type { AttackMoveResult } from "#app/@types/attack-move-result";
|
||||||
import type { Nature } from "#enums/nature";
|
import type { Nature } from "#enums/nature";
|
||||||
|
import type { IllusionData } from "#app/@types/illusion-data";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Permanent data that can customize a Pokemon in non-standard ways from its Species.
|
* Permanent data that can customize a Pokemon in non-standard ways from its Species.
|
||||||
@ -109,42 +106,6 @@ export class PokemonSummonData {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Illusion property
|
|
||||||
*/
|
|
||||||
export interface IllusionData {
|
|
||||||
basePokemon: {
|
|
||||||
/** The actual name of the Pokemon */
|
|
||||||
name: string;
|
|
||||||
/** The actual nickname of the Pokemon */
|
|
||||||
nickname: string;
|
|
||||||
/** Whether the base pokemon is shiny or not */
|
|
||||||
shiny: boolean;
|
|
||||||
/** The shiny variant of the base pokemon */
|
|
||||||
variant: Variant;
|
|
||||||
/** Whether the fusion species of the base pokemon is shiny or not */
|
|
||||||
fusionShiny: boolean;
|
|
||||||
/** The variant of the fusion species of the base pokemon */
|
|
||||||
fusionVariant: Variant;
|
|
||||||
};
|
|
||||||
/** The species of the illusion */
|
|
||||||
species: Species;
|
|
||||||
/** The formIndex of the illusion */
|
|
||||||
formIndex: number;
|
|
||||||
/** The gender of the illusion */
|
|
||||||
gender: Gender;
|
|
||||||
/** The pokeball of the illusion */
|
|
||||||
pokeball: PokeballType;
|
|
||||||
/** The fusion species of the illusion if it's a fusion */
|
|
||||||
fusionSpecies?: PokemonSpecies;
|
|
||||||
/** The fusionFormIndex of the illusion */
|
|
||||||
fusionFormIndex?: number;
|
|
||||||
/** The fusionGender of the illusion if it's a fusion */
|
|
||||||
fusionGender?: Gender;
|
|
||||||
/** The level of the illusion (not used currently) */
|
|
||||||
level?: number;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO: Merge this inside `summmonData` but exclude from save if/when a save data serializer is added
|
// TODO: Merge this inside `summmonData` but exclude from save if/when a save data serializer is added
|
||||||
export class PokemonTempSummonData {
|
export class PokemonTempSummonData {
|
||||||
/**
|
/**
|
@ -242,7 +242,7 @@ import { SwitchSummonPhase } from "#app/phases/switch-summon-phase";
|
|||||||
import { Challenges } from "#enums/challenges";
|
import { Challenges } from "#enums/challenges";
|
||||||
import { PokemonAnimType } from "#enums/pokemon-anim-type";
|
import { PokemonAnimType } from "#enums/pokemon-anim-type";
|
||||||
import { PLAYER_PARTY_MAX_SIZE } from "#app/constants";
|
import { PLAYER_PARTY_MAX_SIZE } from "#app/constants";
|
||||||
import { CustomPokemonData } from "#app/@types/pokemon-data";
|
import { CustomPokemonData } from "#app/data/pokemon/pokemon-data";
|
||||||
import { SwitchType } from "#enums/switch-type";
|
import { SwitchType } from "#enums/switch-type";
|
||||||
import { SpeciesFormKey } from "#enums/species-form-key";
|
import { SpeciesFormKey } from "#enums/species-form-key";
|
||||||
import { getStatusEffectOverlapText } from "#app/data/status-effect";
|
import { getStatusEffectOverlapText } from "#app/data/status-effect";
|
||||||
@ -259,7 +259,8 @@ import { MoveFlags } from "#enums/MoveFlags";
|
|||||||
import { timedEventManager } from "#app/global-event-manager";
|
import { timedEventManager } from "#app/global-event-manager";
|
||||||
import { loadMoveAnimations } from "#app/sprites/pokemon-asset-loader";
|
import { loadMoveAnimations } from "#app/sprites/pokemon-asset-loader";
|
||||||
import { ResetStatusPhase } from "#app/phases/reset-status-phase";
|
import { ResetStatusPhase } from "#app/phases/reset-status-phase";
|
||||||
import { PokemonBattleData, PokemonSummonData, PokemonTempSummonData, PokemonWaveData, PokemonTurnData, type IllusionData } from "../@types/pokemon-data";
|
import { PokemonBattleData, PokemonSummonData, PokemonTempSummonData, PokemonWaveData, PokemonTurnData } from "../data/pokemon/pokemon-data";
|
||||||
|
import { type IllusionData } from "#app/@types/illusion-data";
|
||||||
import type { TurnMove } from "../@types/turn-move";
|
import type { TurnMove } from "../@types/turn-move";
|
||||||
|
|
||||||
export enum LearnMoveSituation {
|
export enum LearnMoveSituation {
|
||||||
|
@ -6,13 +6,13 @@ import { PokeballType } from "#enums/pokeball";
|
|||||||
import { getPokemonSpecies, getPokemonSpeciesForm } from "../data/pokemon-species";
|
import { getPokemonSpecies, getPokemonSpeciesForm } from "../data/pokemon-species";
|
||||||
import { Status } from "../data/status-effect";
|
import { Status } from "../data/status-effect";
|
||||||
import Pokemon, { EnemyPokemon, PokemonMove } from "../field/pokemon";
|
import Pokemon, { EnemyPokemon, PokemonMove } from "../field/pokemon";
|
||||||
import { PokemonBattleData, PokemonSummonData } from "#app/@types/pokemon-data";
|
import { PokemonBattleData, PokemonSummonData } from "#app/data/pokemon/pokemon-data";
|
||||||
import { TrainerSlot } from "#enums/trainer-slot";
|
import { TrainerSlot } from "#enums/trainer-slot";
|
||||||
import type { Variant } from "#app/sprites/variant";
|
import type { Variant } from "#app/sprites/variant";
|
||||||
import type { Biome } from "#enums/biome";
|
import type { Biome } from "#enums/biome";
|
||||||
import type { Moves } from "#enums/moves";
|
import type { Moves } from "#enums/moves";
|
||||||
import type { Species } from "#enums/species";
|
import type { Species } from "#enums/species";
|
||||||
import { CustomPokemonData } from "#app/@types/pokemon-data";
|
import { CustomPokemonData } from "#app/data/pokemon/pokemon-data";
|
||||||
import type { PokemonType } from "#enums/pokemon-type";
|
import type { PokemonType } from "#enums/pokemon-type";
|
||||||
|
|
||||||
export default class PokemonData {
|
export default class PokemonData {
|
||||||
|
@ -2,7 +2,7 @@ import { SettingKeys } from "#app/system/settings/settings";
|
|||||||
import type { SystemSaveData, SessionSaveData } from "#app/system/game-data";
|
import type { SystemSaveData, SessionSaveData } from "#app/system/game-data";
|
||||||
import { AbilityAttr, defaultStarterSpecies, DexAttr } from "#app/system/game-data";
|
import { AbilityAttr, defaultStarterSpecies, DexAttr } from "#app/system/game-data";
|
||||||
import { allSpecies } from "#app/data/pokemon-species";
|
import { allSpecies } from "#app/data/pokemon-species";
|
||||||
import { CustomPokemonData } from "#app/@types/pokemon-data";
|
import { CustomPokemonData } from "#app/data/pokemon/pokemon-data";
|
||||||
import { isNullOrUndefined } from "#app/utils/common";
|
import { isNullOrUndefined } from "#app/utils/common";
|
||||||
import type { SystemSaveMigrator } from "#app/@types/SystemSaveMigrator";
|
import type { SystemSaveMigrator } from "#app/@types/SystemSaveMigrator";
|
||||||
import type { SettingsSaveMigrator } from "#app/@types/SettingsSaveMigrator";
|
import type { SettingsSaveMigrator } from "#app/@types/SettingsSaveMigrator";
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { StockpilingTag } from "#app/data/battler-tags";
|
import { StockpilingTag } from "#app/data/battler-tags";
|
||||||
import type Pokemon from "#app/field/pokemon";
|
import type Pokemon from "#app/field/pokemon";
|
||||||
import { PokemonSummonData } from "#app/@types/pokemon-data";
|
import { PokemonSummonData } from "#app/data/pokemon/pokemon-data";
|
||||||
import * as messages from "#app/messages";
|
import * as messages from "#app/messages";
|
||||||
import { StatStageChangePhase } from "#app/phases/stat-stage-change-phase";
|
import { StatStageChangePhase } from "#app/phases/stat-stage-change-phase";
|
||||||
import { Stat } from "#enums/stat";
|
import { Stat } from "#enums/stat";
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { afterEach, beforeAll, beforeEach, describe, expect, it, vi } from "vitest";
|
import { afterEach, beforeAll, beforeEach, describe, expect, it, vi } from "vitest";
|
||||||
import type { TurnMove } from "#app/@types/turn-move";
|
import type { TurnMove } from "#app/@types/turn-move";
|
||||||
import type { PokemonTurnData } from "#app/@types/pokemon-data";
|
import type { PokemonTurnData } from "#app/data/pokemon/pokemon-data";
|
||||||
import type Pokemon from "#app/field/pokemon";
|
import type Pokemon from "#app/field/pokemon";
|
||||||
import { MoveResult } from "#app/field/pokemon";
|
import { MoveResult } from "#app/field/pokemon";
|
||||||
import type BattleScene from "#app/battle-scene";
|
import type BattleScene from "#app/battle-scene";
|
||||||
|
@ -5,7 +5,7 @@ import { PokeballType } from "#enums/pokeball";
|
|||||||
import type BattleScene from "#app/battle-scene";
|
import type BattleScene from "#app/battle-scene";
|
||||||
import { Moves } from "#app/enums/moves";
|
import { Moves } from "#app/enums/moves";
|
||||||
import { PokemonType } from "#enums/pokemon-type";
|
import { PokemonType } from "#enums/pokemon-type";
|
||||||
import { CustomPokemonData } from "#app/@types/pokemon-data";
|
import { CustomPokemonData } from "#app/data/pokemon/pokemon-data";
|
||||||
|
|
||||||
describe("Spec - Pokemon", () => {
|
describe("Spec - Pokemon", () => {
|
||||||
let phaserGame: Phaser.Game;
|
let phaserGame: Phaser.Game;
|
||||||
|
@ -24,7 +24,7 @@ import { BerryModifier, PokemonBaseStatTotalModifier } from "#app/modifier/modif
|
|||||||
import { MysteryEncounterOptionMode } from "#enums/mystery-encounter-option-mode";
|
import { MysteryEncounterOptionMode } from "#enums/mystery-encounter-option-mode";
|
||||||
import { MysteryEncounterTier } from "#enums/mystery-encounter-tier";
|
import { MysteryEncounterTier } from "#enums/mystery-encounter-tier";
|
||||||
import { initSceneWithoutEncounterPhase } from "#test/testUtils/gameManagerUtils";
|
import { initSceneWithoutEncounterPhase } from "#test/testUtils/gameManagerUtils";
|
||||||
import { CustomPokemonData } from "#app/@types/pokemon-data";
|
import { CustomPokemonData } from "#app/data/pokemon/pokemon-data";
|
||||||
import { CommandPhase } from "#app/phases/command-phase";
|
import { CommandPhase } from "#app/phases/command-phase";
|
||||||
import { MovePhase } from "#app/phases/move-phase";
|
import { MovePhase } from "#app/phases/move-phase";
|
||||||
import { SelectModifierPhase } from "#app/phases/select-modifier-phase";
|
import { SelectModifierPhase } from "#app/phases/select-modifier-phase";
|
||||||
|
Loading…
Reference in New Issue
Block a user