From 0da469d7a30fe7390f065da438ddbb89a8a0f616 Mon Sep 17 00:00:00 2001 From: LaukkaE <73663099+LaukkaE@users.noreply.github.com> Date: Sat, 25 May 2024 13:32:32 +0300 Subject: [PATCH] Fix Wind Rider (#607) Fix Wind Rider --- src/data/ability.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/data/ability.ts b/src/data/ability.ts index ea5c5cea4fd..0bfc85fa363 100644 --- a/src/data/ability.ts +++ b/src/data/ability.ts @@ -556,7 +556,10 @@ export class MoveImmunityStatChangeAbAttr extends MoveImmunityAbAttr { applyPreDefend(pokemon: Pokemon, passive: boolean, attacker: Pokemon, move: PokemonMove, cancelled: Utils.BooleanHolder, args: any[]): boolean { const ret = super.applyPreDefend(pokemon, passive, attacker, move, cancelled, args); if (ret) { - pokemon.scene.unshiftPhase(new StatChangePhase(pokemon.scene, pokemon.getBattlerIndex(), true, [ this.stat ], this.levels)); + const simulated = args.length > 1 && args[1]; + if (!simulated) { + pokemon.scene.unshiftPhase(new StatChangePhase(pokemon.scene, pokemon.getBattlerIndex(), true, [ this.stat ], this.levels)); + } } return ret;