From 375587213e344ab3531391b2c96ceb75bac08e5d Mon Sep 17 00:00:00 2001 From: NightKev <34855794+DayKev@users.noreply.github.com> Date: Mon, 4 Aug 2025 21:24:58 -0700 Subject: [PATCH] [Misc] Replace `Moves.MOVE_NAME` with `MoveId.MOVE_NAME` in comments --- src/data/abilities/ability.ts | 2 +- src/data/battler-tags.ts | 2 +- src/data/moves/invalid-moves.ts | 4 ++-- src/data/moves/move.ts | 10 +++++----- src/field/pokemon.ts | 24 ++++++++++++------------ src/phases/move-phase.ts | 2 -- 6 files changed, 21 insertions(+), 23 deletions(-) diff --git a/src/data/abilities/ability.ts b/src/data/abilities/ability.ts index 0ee1a51a78e..2f57df4a551 100644 --- a/src/data/abilities/ability.ts +++ b/src/data/abilities/ability.ts @@ -1768,7 +1768,7 @@ export interface AddSecondStrikeAbAttrParams extends Omit = new Set([ MoveId.HIDDEN_POWER, ]); -/** Set of all moves that cannot be copied by {@linkcode Moves.SKETCH}. */ +/** Set of all moves that cannot be copied by {@linkcode MoveId.SKETCH}. */ export const invalidSketchMoves: ReadonlySet = new Set([ MoveId.NONE, MoveId.CHATTER, @@ -270,7 +270,7 @@ export const invalidSketchMoves: ReadonlySet = new Set([ MoveId.BREAKNECK_BLITZ__SPECIAL, ]); -/** Set of all moves that cannot be locked into by {@linkcode Moves.ENCORE}. */ +/** Set of all moves that cannot be locked into by {@linkcode MoveId.ENCORE}. */ export const invalidEncoreMoves: ReadonlySet = new Set([ MoveId.MIMIC, MoveId.MIRROR_MOVE, diff --git a/src/data/moves/move.ts b/src/data/moves/move.ts index bde5f2977d8..5f52f48bfca 100644 --- a/src/data/moves/move.ts +++ b/src/data/moves/move.ts @@ -2587,7 +2587,7 @@ export class PsychoShiftEffectAttr extends MoveEffectAttr { } /** - * Applies the effect of {@linkcode Moves.PSYCHO_SHIFT} to its target. + * Applies the effect of {@linkcode MoveId.PSYCHO_SHIFT} to its target. * Psycho Shift takes the user's status effect and passes it onto the target. * The user is then healed after the move has been successfully executed. * @param user - The {@linkcode Pokemon} using the move @@ -2927,7 +2927,7 @@ export class HealStatusEffectAttr extends MoveEffectAttr { /** * Attribute to add the {@linkcode BattlerTagType.BYPASS_SLEEP | BYPASS_SLEEP Battler Tag} for 1 turn to the user before move use. - * Used by {@linkcode Moves.SNORE} and {@linkcode Moves.SLEEP_TALK}. + * Used by {@linkcode MoveId.SNORE} and {@linkcode MoveId.SLEEP_TALK}. */ // TODO: Should this use a battler tag? // TODO: Give this `userSleptOrComatoseCondition` by default @@ -7139,7 +7139,7 @@ export class CopyMoveAttr extends CallMoveAttr { /** * Attribute used for moves that cause the target to repeat their last used move. * - * Used by {@linkcode Moves.INSTRUCT | Instruct}. + * Used by {@linkcode MoveId.INSTRUCT | Instruct}. * @see [Instruct on Bulbapedia](https://bulbapedia.bulbagarden.net/wiki/Instruct_(move)) */ export class RepeatMoveAttr extends MoveEffectAttr { @@ -7402,7 +7402,7 @@ const targetMoveCopiableCondition: MoveConditionFunc = (user, target, move) => { /** * Attribute to temporarily copy the last move in the target's moveset. - * Used by {@linkcode Moves.MIMIC}. + * Used by {@linkcode MoveId.MIMIC}. */ export class MovesetCopyMoveAttr extends OverrideMoveEffectAttr { apply(user: Pokemon, target: Pokemon, move: Move, args: any[]): boolean { @@ -7966,7 +7966,7 @@ export class VariableTargetAttr extends MoveAttr { /** * Attribute to cause the target to move immediately after the user. * - * Used by {@linkcode Moves.AFTER_YOU}. + * Used by {@linkcode MoveId.AFTER_YOU}. */ export class AfterYouAttr extends MoveEffectAttr { /** diff --git a/src/field/pokemon.ts b/src/field/pokemon.ts index 0523671ee5f..221068d2f6e 100644 --- a/src/field/pokemon.ts +++ b/src/field/pokemon.ts @@ -725,7 +725,7 @@ export abstract class Pokemon extends Phaser.GameObjects.Container { /** * Load all assets needed for this Pokemon's use in battle - * @param ignoreOverride - Whether to ignore overrides caused by {@linkcode Moves.TRANSFORM | Transform}; default `true` + * @param ignoreOverride - Whether to ignore overrides caused by {@linkcode MoveId.TRANSFORM | Transform}; default `true` * @param useIllusion - Whether to consider this pokemon's active illusion; default `false` * @returns A promise that resolves once all the corresponding assets have been loaded. */ @@ -1032,7 +1032,7 @@ export abstract class Pokemon extends Phaser.GameObjects.Container { /** * Return this Pokemon's {@linkcode PokemonSpeciesForm | SpeciesForm}. - * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode Moves.TRANSFORM | Transform}; default `false` + * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode MoveId.TRANSFORM | Transform}; default `false` * and overrides `useIllusion`. * @param useIllusion - Whether to consider this Pokemon's illusion if present; default `false`. * @returns This Pokemon's {@linkcode PokemonSpeciesForm}. @@ -1088,7 +1088,7 @@ export abstract class Pokemon extends Phaser.GameObjects.Container { /** * Return the {@linkcode PokemonSpeciesForm | SpeciesForm} of this Pokemon's fusion counterpart. - * @param ignoreOverride - Whether to ignore species overrides caused by {@linkcode Moves.TRANSFORM | Transform}; default `false` + * @param ignoreOverride - Whether to ignore species overrides caused by {@linkcode MoveId.TRANSFORM | Transform}; default `false` * @param useIllusion - Whether to consider the species of this Pokemon's illusion; default `false` * @returns The {@linkcode PokemonSpeciesForm} of this Pokemon's fusion counterpart. */ @@ -1659,7 +1659,7 @@ export abstract class Pokemon extends Phaser.GameObjects.Container { /** * Return this Pokemon's {@linkcode Gender}. - * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode Moves.TRANSFORM | Transform}; default `false` + * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode MoveId.TRANSFORM | Transform}; default `false` * @param useIllusion - Whether to consider this pokemon's illusion if present; default `false` * @returns the {@linkcode Gender} of this {@linkcode Pokemon}. */ @@ -1675,7 +1675,7 @@ export abstract class Pokemon extends Phaser.GameObjects.Container { /** * Return this Pokemon's fusion's {@linkcode Gender}. - * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode Moves.TRANSFORM | Transform}; default `false` + * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode MoveId.TRANSFORM | Transform}; default `false` * @param useIllusion - Whether to consider this pokemon's illusion if present; default `false` * @returns The {@linkcode Gender} of this {@linkcode Pokemon}'s fusion. */ @@ -1817,7 +1817,7 @@ export abstract class Pokemon extends Phaser.GameObjects.Container { /** * Return all the {@linkcode PokemonMove}s that make up this Pokemon's moveset. * Takes into account player/enemy moveset overrides (which will also override PP count). - * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode Moves.TRANSFORM | Transform}; default `false` + * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode MoveId.TRANSFORM | Transform}; default `false` * @returns An array of {@linkcode PokemonMove}, as described above. */ getMoveset(ignoreOverride = false): PokemonMove[] { @@ -1883,7 +1883,7 @@ export abstract class Pokemon extends Phaser.GameObjects.Container { * Evaluate and return this Pokemon's typing. * @param includeTeraType - Whether to use this Pokemon's tera type if Terastallized; default `false` * @param forDefend - Whether this Pokemon is currently receiving an attack; default `false` - * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode Moves.TRANSFORM | Transform}; default `false` + * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode MoveId.TRANSFORM | Transform}; default `false` * @param useIllusion - Whether to consider this Pokemon's illusion if present; default `false` * @returns An array of {@linkcode PokemonType}s corresponding to this Pokemon's typing (real or percieved). */ @@ -2006,7 +2006,7 @@ export abstract class Pokemon extends Phaser.GameObjects.Container { * @param type - The {@linkcode PokemonType} to check * @param includeTeraType - Whether to use this Pokemon's tera type if Terastallized; default `true` * @param forDefend - Whether this Pokemon is currently receiving an attack; default `false` - * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode Moves.TRANSFORM | Transform}; default `false` + * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode MoveId.TRANSFORM | Transform}; default `false` * @returns Whether this Pokemon is of the specified type. */ public isOfType(type: PokemonType, includeTeraType = true, forDefend = false, ignoreOverride = false): boolean { @@ -2019,7 +2019,7 @@ export abstract class Pokemon extends Phaser.GameObjects.Container { * Should rarely be called directly in favor of {@linkcode hasAbility} or {@linkcode hasAbilityWithAttr}, * both of which check both ability slots and account for suppression. * @see {@linkcode hasAbility} and {@linkcode hasAbilityWithAttr} are the intended ways to check abilities in most cases - * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode Moves.TRANSFORM | Transform}; default `false` + * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode MoveId.TRANSFORM | Transform}; default `false` * @returns The non-passive {@linkcode Ability} of this Pokemon. */ public getAbility(ignoreOverride = false): Ability { @@ -2201,7 +2201,7 @@ export abstract class Pokemon extends Phaser.GameObjects.Container { * Accounts for all the various effects which can disable or modify abilities. * @param ability - The {@linkcode Abilities | Ability} to check for * @param canApply - Whether to check if the ability is currently active; default `true` - * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode Moves.TRANSFORM | Transform}; default `false` + * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode MoveId.TRANSFORM | Transform}; default `false` * @returns Whether this {@linkcode Pokemon} has the given ability */ public hasAbility(ability: AbilityId, canApply = true, ignoreOverride = false): boolean { @@ -2216,7 +2216,7 @@ export abstract class Pokemon extends Phaser.GameObjects.Container { * Accounts for all the various effects which can disable or modify abilities. * @param attrType - The {@linkcode AbAttr | attribute} to check for * @param canApply - Whether to check if the ability is currently active; default `true` - * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode Moves.TRANSFORM | Transform}; default `false` + * @param ignoreOverride - Whether to ignore any overrides caused by {@linkcode MoveId.TRANSFORM | Transform}; default `false` * @returns Whether this Pokemon has an ability with the given {@linkcode AbAttr}. */ public hasAbilityWithAttr(attrType: AbAttrString, canApply = true, ignoreOverride = false): boolean { @@ -4466,7 +4466,7 @@ export abstract class Pokemon extends Phaser.GameObjects.Container { * Return the most recently executed {@linkcode TurnMove} this {@linkcode Pokemon} has used that is: * - Not {@linkcode MoveId.NONE} * - Non-virtual ({@linkcode MoveUseMode | useMode} < {@linkcode MoveUseMode.INDIRECT}) - * @param ignoreStruggle - Whether to additionally ignore {@linkcode Moves.STRUGGLE}; default `false` + * @param ignoreStruggle - Whether to additionally ignore {@linkcode MoveId.STRUGGLE}; default `false` * @param ignoreFollowUp - Whether to ignore moves with a use type of {@linkcode MoveUseMode.FOLLOW_UP} * (e.g. ones called by Copycat/Mirror Move); default `true`. * @returns The last move this Pokemon has used satisfying the aforementioned conditions, diff --git a/src/phases/move-phase.ts b/src/phases/move-phase.ts index cd7c7a8f48f..f88f9d0cad1 100644 --- a/src/phases/move-phase.ts +++ b/src/phases/move-phase.ts @@ -649,7 +649,6 @@ export class MovePhase extends BattlePhase { * Displays the move's usage text to the player as applicable for the move being used. */ public showMoveText(): void { - // No text for Moves.NONE, recharging/2-turn moves or interrupted moves if ( this.move.moveId === MoveId.NONE || this.pokemon.getTag(BattlerTagType.RECHARGING) || @@ -658,7 +657,6 @@ export class MovePhase extends BattlePhase { return; } - // Play message for magic coat reflection // TODO: This should be done by the move... globalScene.phaseManager.queueMessage( i18next.t(isReflected(this.useMode) ? "battle:magicCoatActivated" : "battle:useMove", {