From d2c6aa5df8ee253608e30327e71a669ad0038ce6 Mon Sep 17 00:00:00 2001 From: "Amani H." <109637146+xsn34kzx@users.noreply.github.com> Date: Mon, 12 Aug 2024 01:49:32 -0400 Subject: [PATCH] [Bug] Prevent Relearnable Egg Moves in Fresh Start (#3466) * [Bug] Prevent Relearnable Egg Moves in Fresh Start * Mention Condition in Docs * Use `isFreshStartChallenge()` --- src/field/pokemon.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/field/pokemon.ts b/src/field/pokemon.ts index 36603b33b90..588b6839d70 100644 --- a/src/field/pokemon.ts +++ b/src/field/pokemon.ts @@ -916,13 +916,13 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container { * excluding any moves already known. * * Available egg moves are only included if the {@linkcode Pokemon} was - * in the starting party of the run. + * in the starting party of the run and if Fresh Start is not active. * @returns an array of {@linkcode Moves}, the length of which is determined * by how many learnable moves there are for the {@linkcode Pokemon}. */ getLearnableLevelMoves(): Moves[] { let levelMoves = this.getLevelMoves(1, true).map(lm => lm[1]); - if (this.metBiome === -1) { + if (this.metBiome === -1 && !this.scene.gameMode.isFreshStartChallenge()) { levelMoves = this.getUnlockedEggMoves().concat(levelMoves); } return levelMoves.filter(lm => !this.moveset.some(m => m?.moveId === lm));