Add nonnull after checking for null

This commit is contained in:
Temps Ray 2024-09-19 10:37:56 -04:00
parent e83a1d5366
commit 5156990339
1 changed files with 1 additions and 1 deletions

View File

@ -1402,7 +1402,7 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container {
const autotomizedTag = this.getTag(AutotomizedTag);
let weightRemoved = 0;
if (!Utils.isNullOrUndefined(autotomizedTag)) {
weightRemoved = 100 * autotomizedTag.autotomizeCount;
weightRemoved = 100 * autotomizedTag!.autotomizeCount;
}
const minWeight = 0.1;
const weight = new Utils.NumberHolder(this.species.weight - weightRemoved);