mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-08-24 08:19:33 +02:00
fix EnemyEndureChanceModifier.apply
types
This commit is contained in:
parent
fe026af101
commit
eb5128f41c
@ -3518,10 +3518,10 @@ export class EnemyEndureChanceModifier extends EnemyPersistentModifier {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Applies {@linkcode EnemyEndureChanceModifier}
|
* Applies {@linkcode EnemyEndureChanceModifier}
|
||||||
* @param target {@linkcode EnemyPokemon} to apply the {@linkcode BattlerTagType.ENDURING} chance to
|
* @param target {@linkcode Pokemon} to apply the {@linkcode BattlerTagType.ENDURING} chance to
|
||||||
* @returns `true` if {@linkcode EnemyPokemon} endured
|
* @returns `true` if {@linkcode Pokemon} endured
|
||||||
*/
|
*/
|
||||||
override apply(target: EnemyPokemon): boolean {
|
override apply(target: Pokemon): boolean {
|
||||||
if (target.battleData.endured || Phaser.Math.RND.realInRange(0, 1) >= (this.chance * this.getStackCount())) {
|
if (target.battleData.endured || Phaser.Math.RND.realInRange(0, 1) >= (this.chance * this.getStackCount())) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user