mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-07-27 10:42:25 +02:00
Added condition to require that mon is on field in order to apply ability, accounting for exceptions
This commit is contained in:
parent
796886790e
commit
851bb7e544
@ -1479,7 +1479,7 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return (this.hp > 0 || ability.isBypassFaint) && !ability.conditions.find(condition => !condition(this));
|
||||
return (((this.isOnField() || ability.isBypassOnField) && this.hp > 0) || ability.isBypassFaint) && !ability.conditions.find(condition => !condition(this));
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user