From 9a00090617a5c233c63759dd2ee85b35d3710e04 Mon Sep 17 00:00:00 2001 From: Flashfyre Date: Fri, 26 Jan 2024 18:36:23 -0500 Subject: [PATCH] Fix max elixir logic not working properly --- src/modifier/modifier.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modifier/modifier.ts b/src/modifier/modifier.ts index 7fbfd2962..ea8f057a3 100644 --- a/src/modifier/modifier.ts +++ b/src/modifier/modifier.ts @@ -900,7 +900,7 @@ export class PokemonPpRestoreModifier extends ConsumablePokemonMoveModifier { apply(args: any[]): boolean { const pokemon = args[0] as Pokemon; const move = pokemon.getMoveset()[this.moveIndex]; - move.ppUsed = this.restorePoints >= -1 ? Math.max(move.ppUsed - this.restorePoints, 0) : 0; + move.ppUsed = this.restorePoints > -1 ? Math.max(move.ppUsed - this.restorePoints, 0) : 0; return true; } @@ -918,7 +918,7 @@ export class PokemonAllMovePpRestoreModifier extends ConsumablePokemonModifier { apply(args: any[]): boolean { const pokemon = args[0] as Pokemon; for (let move of pokemon.getMoveset()) - move.ppUsed = this.restorePoints >= -1 ? Math.max(move.ppUsed - this.restorePoints, 0) : 0; + move.ppUsed = this.restorePoints > -1 ? Math.max(move.ppUsed - this.restorePoints, 0) : 0; return true; }