mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-07-06 08:22:16 +02:00
moves: actually properly check for trapped tag here
This commit is contained in:
parent
4c511d1734
commit
c9f4cf6989
@ -2956,7 +2956,8 @@ export class ForceSwitchOutAttr extends MoveEffectAttr {
|
|||||||
if (!player && !user.scene.currentBattle.battleType) {
|
if (!player && !user.scene.currentBattle.battleType) {
|
||||||
if (this.batonPass)
|
if (this.batonPass)
|
||||||
return false;
|
return false;
|
||||||
if (move.category == MoveCategory.STATUS && !user.hasAbilityWithAttr(RunSuccessAbAttr))
|
// Don't let wild opponents flee with Teleport unless they have a workaround ability.
|
||||||
|
if (user.getTag(BattlerTagType.TRAPPED) && move.id == Moves.TELEPORT && !user.hasAbilityWithAttr(RunSuccessAbAttr))
|
||||||
return false;
|
return false;
|
||||||
// Don't allow wild opponents to flee on the boss stage since it can ruin a run early on
|
// Don't allow wild opponents to flee on the boss stage since it can ruin a run early on
|
||||||
if (!(user.scene.currentBattle.waveIndex % 10))
|
if (!(user.scene.currentBattle.waveIndex % 10))
|
||||||
|
Loading…
Reference in New Issue
Block a user