diff --git a/src/field/pokemon.ts b/src/field/pokemon.ts index e32b5303dc7..279ffeccc42 100644 --- a/src/field/pokemon.ts +++ b/src/field/pokemon.ts @@ -276,7 +276,18 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container { isAllowedInBattle(): boolean { const challengeAllowed = new Utils.BooleanHolder(true); applyChallenges(this.scene.gameMode, ChallengeType.POKEMON_IN_BATTLE, this, challengeAllowed); - return !this.isFainted() && challengeAllowed.value; + return !this.isFainted() && this.isAllowed(); + } + + /** + * Check if this pokemon is allowed (no challenge exclusion) + * This is frequently a better alternative to {@link isFainted} + * @returns {boolean} True if pokemon is allowed in battle + */ + isAllowed(): boolean { + const challengeAllowed = new Utils.BooleanHolder(true); + applyChallenges(this.scene.gameMode, ChallengeType.POKEMON_IN_BATTLE, this, challengeAllowed); + return challengeAllowed.value; } isActive(onField?: boolean): boolean {