Fix negative EXP level cap bug

This commit is contained in:
Flashfyre committed 2023-10-28 18:38:22 -04:00
1 parent f831f3ab75
commit 989e4b37f4
4 files changed
+6 -4

No files matched your search

+1 -1
View File
@@ -538,7 +538,7 @@ export default class SummaryUiHandler extends UiHandler {
statsContainer.add(expText);
const nextLvExp = this.pokemon.level < this.scene.getMaxExpLevel()
? getLevelTotalExp(this.pokemon.level + 1, this.pokemon.species.growthRate) - this.pokemon.levelExp
? getLevelTotalExp(this.pokemon.level + 1, this.pokemon.species.growthRate) - this.pokemon.exp
: 0;
const nextLvExpText = addTextObject(this.scene, 208, 128, nextLvExp.toString(), TextStyle.WINDOW);
nextLvExpText.setOrigin(1, 0);