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/sim/pokemon.ts b/sim/pokemon.ts index b9283feb3a..3d377d5082 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']) { @@ -863,7 +863,7 @@ export class Pokemon { } ignoringAbility() { - if (this.battle.gen >= 5 && !this.isActive) 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; @@ -884,8 +884,8 @@ export class Pokemon { } ignoringItem(isFling = false) { + if ((this.battle.gen >= 5 && !this.isActive) || this.fainted) return true; if (this.getItem().isPrimalOrb) return false; - if (this.battle.gen >= 5 && !this.isActive) 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');