#3722 fix so that testing works correctly

This commit is contained in:
Jesse Chung 2024-08-29 20:12:06 -07:00
commit 5c543367aa

View File

@ -1950,8 +1950,11 @@ export class StatusEffectAttr extends MoveEffectAttr {
return false; return false;
} }
} }
if (!pokemon.status || (pokemon.status.effect === this.effect && moveChance < 0)) {
pokemon.canSetStatus(this.effect, false, false, user);
}
if ((!pokemon.status || (pokemon.status.effect === this.effect && moveChance < 0)) if ((!pokemon.status || (pokemon.status.effect === this.effect && moveChance < 0))
&& pokemon.trySetStatus(this.effect, false, user, this.cureTurn)) { && pokemon.trySetStatus(this.effect, true, user, this.cureTurn)) {
applyPostAttackAbAttrs(ConfusionOnStatusEffectAbAttr, user, target, move, null, false, this.effect); applyPostAttackAbAttrs(ConfusionOnStatusEffectAbAttr, user, target, move, null, false, this.effect);
return true; return true;
} }