[Bug] Fix ability Download switch in (1669) (#1679)

* Update ability Dowbload

* Remove whitespace

* Update ability.ts
This commit is contained in:
Adam Clemons 2024-06-07 12:17:22 -06:00 committed by GitHub
parent bb1dde5b0c
commit fb21caa769
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 6 additions and 8 deletions

View File

@ -1693,7 +1693,6 @@ export class DownloadAbAttr extends PostSummonAbAttr {
this.enemySpDef = 0;
this.enemyCountTally = 0;
if (pokemon.getOpponents()[0].summonData !== undefined) {
for (const opponent of pokemon.getOpponents()) {
this.enemyCountTally++;
this.enemyDef += opponent.getBattleStat(Stat.DEF);
@ -1701,7 +1700,6 @@ export class DownloadAbAttr extends PostSummonAbAttr {
}
this.enemyDef = Math.round(this.enemyDef / this.enemyCountTally);
this.enemySpDef = Math.round(this.enemySpDef / this.enemyCountTally);
}
if (this.enemyDef < this.enemySpDef) {
this.stats = [BattleStat.ATK];