[Bug] Self effect moves fix for Shield Dust (#3167)

* Self effect moves fix for Shield Dust

Moves with self effects no longer affected by Shield Dust.

* comma spaces

Co-authored-by: Adrian T. <68144167+torranx@users.noreply.github.com>

---------

Co-authored-by: Adrian T. <68144167+torranx@users.noreply.github.com>
This commit is contained in:
NxKarim 2024-07-29 15:16:00 -06:00 committed by GitHub
parent 33978481ce
commit 4b0157d5d7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 1 deletions

View File

@ -973,7 +973,9 @@ export class MoveEffectAttr extends MoveAttr {
getMoveChance(user: Pokemon, target: Pokemon, move: Move, selfEffect?: Boolean, showAbility?: Boolean): integer {
const moveChance = new Utils.NumberHolder(move.chance);
applyAbAttrs(MoveEffectChanceMultiplierAbAttr, user, null, moveChance, move, target, selfEffect, showAbility);
applyPreDefendAbAttrs(IgnoreMoveEffectsAbAttr,target,user,null,null, moveChance);
if (!selfEffect) {
applyPreDefendAbAttrs(IgnoreMoveEffectsAbAttr, target, user, null, null, moveChance);
}
return moveChance.value;
}
}