From 1052667de3d828f2cc1b811fe67d49c8be441426 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Bastos=20Dias?= <80102738+andrebastosdias@users.noreply.github.com> Date: Sat, 9 May 2026 18:16:56 +0100 Subject: [PATCH 1/4] =?UTF-8?q?Gen=204:=20Fainted=20Pok=C3=A9mon=20shouldn?= =?UTF-8?q?'t=20activate=20Pressure?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sim/pokemon.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sim/pokemon.ts b/sim/pokemon.ts index 2803eb6ef7..117a317a13 100644 --- a/sim/pokemon.ts +++ b/sim/pokemon.ts @@ -863,7 +863,7 @@ export class Pokemon { } ignoringAbility() { - if (this.battle.gen >= 5 && !this.isActive) return true; + if (!this.isActive && (this.battle.gen >= 5 || this.fainted)) return true; // Certain Abilities won't activate while Transformed, even if they ordinarily couldn't be suppressed (e.g. Disguise) if (this.getAbility().flags['notransform'] && this.transformed) return true; @@ -885,7 +885,7 @@ export class Pokemon { ignoringItem(isFling = false) { if (this.getItem().isPrimalOrb) return false; - if (this.battle.gen >= 5 && !this.isActive) return true; + if (!this.isActive && (this.battle.gen >= 5 || this.fainted)) return true; if (this.volatiles['embargo'] || this.battle.field.pseudoWeather['magicroom']) return true; // check Fling first to avoid infinite recursion if (isFling) return this.battle.gen >= 5 && this.hasAbility('klutz'); From 2fd3b3c3f6459228d9765c8dd7c8ac3d5a3df25b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Bastos=20Dias?= <80102738+andrebastosdias@users.noreply.github.com> Date: Sat, 9 May 2026 18:22:22 +0100 Subject: [PATCH 2/4] Refactor condition --- sim/pokemon.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sim/pokemon.ts b/sim/pokemon.ts index 117a317a13..8dca2b0b08 100644 --- a/sim/pokemon.ts +++ b/sim/pokemon.ts @@ -863,7 +863,7 @@ export class Pokemon { } ignoringAbility() { - if (!this.isActive && (this.battle.gen >= 5 || this.fainted)) return true; + if ((this.battle.gen >= 5 && !this.isActive) || this.fainted) return true; // Certain Abilities won't activate while Transformed, even if they ordinarily couldn't be suppressed (e.g. Disguise) if (this.getAbility().flags['notransform'] && this.transformed) return true; @@ -885,7 +885,7 @@ export class Pokemon { ignoringItem(isFling = false) { if (this.getItem().isPrimalOrb) return false; - if (!this.isActive && (this.battle.gen >= 5 || this.fainted)) return true; + if ((this.battle.gen >= 5 && !this.isActive) || this.fainted) return true; if (this.volatiles['embargo'] || this.battle.field.pseudoWeather['magicroom']) return true; // check Fling first to avoid infinite recursion if (isFling) return this.battle.gen >= 5 && this.hasAbility('klutz'); From d345fc4becd1750e5845b5319b08a0ed35514afe Mon Sep 17 00:00:00 2001 From: andrebastosdias Date: Sun, 10 May 2026 17:07:55 +0100 Subject: [PATCH 3/4] Fix Gen 3 Pressure for all-target moves --- data/mods/gen4/moves.ts | 2 +- data/moves.ts | 2 +- sim/pokemon.ts | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/data/mods/gen4/moves.ts b/data/mods/gen4/moves.ts index 795aa6e7c8..ec875e1921 100644 --- a/data/mods/gen4/moves.ts +++ b/data/mods/gen4/moves.ts @@ -662,7 +662,7 @@ export const Moves: import('../../../sim/dex-moves').ModdedMoveDataTable = { }, imprison: { inherit: true, - flags: { bypasssub: 1, metronome: 1 }, + flags: { bypasssub: 1, metronome: 1, mustpressure: 1 }, onTryHit(pokemon) { for (const target of pokemon.foes()) { for (const move of pokemon.moves) { diff --git a/data/moves.ts b/data/moves.ts index eba5db2bea..3cea6ba85a 100644 --- a/data/moves.ts +++ b/data/moves.ts @@ -19221,7 +19221,7 @@ export const Moves: import('../sim/dex-moves').MoveDataTable = { name: "Tera Blast", pp: 10, priority: 0, - flags: { protect: 1, mirror: 1, metronome: 1, mustpressure: 1 }, + flags: { protect: 1, mirror: 1, metronome: 1 }, onPrepareHit(target, source, move) { if (source.terastallized) { this.attrLastMove('[anim] Tera Blast ' + source.teraType); diff --git a/sim/pokemon.ts b/sim/pokemon.ts index 8dca2b0b08..af74a2bb37 100644 --- a/sim/pokemon.ts +++ b/sim/pokemon.ts @@ -852,7 +852,7 @@ export class Pokemon { // Resolve apparent targets for Pressure. let pressureTargets = targets; - if (move.target === 'foeSide') { + if (move.target === 'foeSide' || (move.target === 'all' && move.id !== 'perishsong' && this.battle.gen <= 3)) { pressureTargets = []; } if (move.flags['mustpressure']) { @@ -884,8 +884,8 @@ export class Pokemon { } ignoringItem(isFling = false) { - if (this.getItem().isPrimalOrb) return false; if ((this.battle.gen >= 5 && !this.isActive) || this.fainted) return true; + if (this.getItem().isPrimalOrb) return false; if (this.volatiles['embargo'] || this.battle.field.pseudoWeather['magicroom']) return true; // check Fling first to avoid infinite recursion if (isFling) return this.battle.gen >= 5 && this.hasAbility('klutz'); From 30c38f8d408bb4b3b36720fa102b66f9006918d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Bastos=20Dias?= <80102738+andrebastosdias@users.noreply.github.com> Date: Mon, 11 May 2026 22:14:10 +0100 Subject: [PATCH 4/4] Re-add flag --- data/moves.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data/moves.ts b/data/moves.ts index 3cea6ba85a..eba5db2bea 100644 --- a/data/moves.ts +++ b/data/moves.ts @@ -19221,7 +19221,7 @@ export const Moves: import('../sim/dex-moves').MoveDataTable = { name: "Tera Blast", pp: 10, priority: 0, - flags: { protect: 1, mirror: 1, metronome: 1 }, + flags: { protect: 1, mirror: 1, metronome: 1, mustpressure: 1 }, onPrepareHit(target, source, move) { if (source.terastallized) { this.attrLastMove('[anim] Tera Blast ' + source.teraType);