Change Memory Mushroom move list to exclude duplicate moves

This commit is contained in:
Flashfyre 2023-11-25 16:17:58 -05:00
parent e1768bfc80
commit cbcf874ffc

View File

@ -505,7 +505,7 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container {
}
getLearnableLevelMoves(): Moves[] {
return this.getLevelMoves(1).filter(lm => !this.moveset.filter(m => m.moveId === lm).length);
return this.getLevelMoves(1).filter(lm => !this.moveset.filter(m => m.moveId === lm).length).filter((move: Moves, i: integer, array: Moves[]) => array.indexOf(move) === i);
}
getTypes(ignoreOverride?: boolean): Type[] {