Fix improper stat ratio.

This commit is contained in:
Sirz Benjie 2025-02-21 13:23:21 -06:00 committed by GitHub
parent 7e8abced22
commit 2a8c9e4af5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1030,7 +1030,7 @@ export class AttackMove extends Move {
const statHolder = new Utils.NumberHolder(user.getEffectiveStat(thisStat, target));
const offStatValue = user.getEffectiveStat(offStat, target);
applyMoveAttrs(VariableAtkAttr, user, target, move, statHolder);
const statRatio = statHolder.value / offStatValue;
const statRatio = offStatValue / statHolder.value;
attackScore *= statRatio <= 0.75 ? 2 : statRatio <= 0.875 ? 1.5 : 1;
const power = new Utils.NumberHolder(this.calculateEffectivePower());