Fix override move animations not loading for enemy Pokemon

This commit is contained in:
Acelynn Zhang 2025-08-04 16:07:49 -05:00
parent 800b8c9905
commit 67c6e96310

View File

@ -1821,8 +1821,6 @@ export abstract class Pokemon extends Phaser.GameObjects.Container {
* @returns An array of {@linkcode PokemonMove}, as described above. * @returns An array of {@linkcode PokemonMove}, as described above.
*/ */
getMoveset(ignoreOverride = false): PokemonMove[] { getMoveset(ignoreOverride = false): PokemonMove[] {
const ret = !ignoreOverride && this.summonData.moveset ? this.summonData.moveset : this.moveset;
// Overrides moveset based on arrays specified in overrides.ts // Overrides moveset based on arrays specified in overrides.ts
let overrideArray: MoveId | Array<MoveId> = this.isPlayer() let overrideArray: MoveId | Array<MoveId> = this.isPlayer()
? Overrides.MOVESET_OVERRIDE ? Overrides.MOVESET_OVERRIDE
@ -1838,7 +1836,7 @@ export abstract class Pokemon extends Phaser.GameObjects.Container {
}); });
} }
return ret; return !ignoreOverride && this.summonData.moveset ? this.summonData.moveset : this.moveset;
} }
/** /**