diff --git a/src/data/battler-tags.ts b/src/data/battler-tags.ts index 55c68fa1561..b7c44fcdfa3 100644 --- a/src/data/battler-tags.ts +++ b/src/data/battler-tags.ts @@ -2835,10 +2835,10 @@ export class StuffCheeksTag extends MoveRestrictionBattlerTag { // Stuff Cheeks private moveId: Moves = Moves.STUFF_CHEEKS; /** - * This Tag only lasts the turn the {@linkcode MoveUnselectableTag} was added. + * This Tag only lasts the turn the {@linkcode StuffCheeksTag} was added. * @param move {@linkcode Moves} that is selected */ - constructor(move: Moves) { + constructor() { super(BattlerTagType.STUFF_CHEEKS, BattlerTagLapseType.TURN_END, 0, Moves.STUFF_CHEEKS); } @@ -3201,7 +3201,7 @@ export function getBattlerTag(tagType: BattlerTagType, turnCount: number, source case BattlerTagType.PSYCHO_SHIFT: return new PsychoShiftTag(); case BattlerTagType.STUFF_CHEEKS: - return new StuffCheeksTag(sourceMove); + return new StuffCheeksTag(); case BattlerTagType.NONE: default: return new BattlerTag(tagType, BattlerTagLapseType.CUSTOM, turnCount, sourceMove, sourceId); diff --git a/src/data/move.ts b/src/data/move.ts index 35873ad8d12..8d56339c627 100644 --- a/src/data/move.ts +++ b/src/data/move.ts @@ -7772,7 +7772,7 @@ export class StuffCheeksCondition extends MoveSelectCondition { * @returns true if the user is holding a berry, otherwise false */ private selectableCondition(user: Pokemon): boolean { - return user?.getHeldItems()?.filter(m => m instanceof BerryModifier, user.isPlayer())?.length > 0; + return user.getHeldItems().filter(m => m instanceof BerryModifier, user.isPlayer()).length > 0; } /** @@ -7791,7 +7791,7 @@ export class StuffCheeksCondition extends MoveSelectCondition { } } -const hasBerryCondition: MoveConditionFunc = (user: Pokemon, target: Pokemon, move: Move) => user.scene.findModifiers(m => m instanceof BerryModifier, user.isPlayer()).length > 0; +const hasBerryCondition: MoveConditionFunc = (user: Pokemon, target: Pokemon, move: Move) => user.getHeldItems().filter(m => m instanceof BerryModifier, user.isPlayer()).length > 0; export class MoveCondition { protected func: MoveConditionFunc; diff --git a/src/phases/command-phase.ts b/src/phases/command-phase.ts index 9453c297615..f033360a5b1 100644 --- a/src/phases/command-phase.ts +++ b/src/phases/command-phase.ts @@ -149,7 +149,7 @@ export class CommandPhase extends FieldPhase { const move = playerPokemon.getMoveset()[cursor]!; //TODO: is this bang correct? this.scene.ui.setMode(Mode.MESSAGE); - // Decides between a Disabled, not selectable, Not Implemented, or No PP translation message + // Decides between a Disabled, Not Implemented, or No PP translation message const errorMessage = playerPokemon.isMoveRestricted(move.moveId, playerPokemon) ? playerPokemon.getRestrictingTag(move.moveId, playerPokemon)!.selectionDeniedText(playerPokemon, move.moveId)