diff --git a/PKHeX.Core/Legality/Moves/MoveLevelUp.cs b/PKHeX.Core/Legality/Moves/MoveLevelUp.cs index 4c91a7982..f90e9566b 100644 --- a/PKHeX.Core/Legality/Moves/MoveLevelUp.cs +++ b/PKHeX.Core/Legality/Moves/MoveLevelUp.cs @@ -42,7 +42,8 @@ namespace PKHeX.Core switch (generation) { case 1: return GetIsLevelUp1(species, move, lvl, minlvlG1, version); - case 2: return GetIsLevelUp2(species, move, lvl, minlvlG2, pkm.Korean, version); + case 2: if (move > MaxMoveID_1 && pkm.LearnMovesNew2Disallowed()) return LearnNONE; + return GetIsLevelUp2(species, move, lvl, minlvlG2, pkm.Korean, version); case 3: return GetIsLevelUp3(species, move, lvl, form, version); case 4: return GetIsLevelUp4(species, move, lvl, form, version); case 5: return GetIsLevelUp5(species, move, lvl, form, version); @@ -243,7 +244,7 @@ namespace PKHeX.Core switch (Generation) { case 1: return GetMovesLevelUp1(species, lvl, minlvlG1, version); - case 2: return GetMovesLevelUp2(species, lvl, minlvlG2, pkm.Korean, pkm.Format, version); + case 2: return GetMovesLevelUp2(species, lvl, minlvlG2, pkm.Korean, pkm.LearnMovesNew2Disallowed(), version); case 3: return GetMovesLevelUp3(species, form, lvl, version); case 4: return GetMovesLevelUp4(species, form, lvl, version); case 5: return GetMovesLevelUp5(species, form, lvl, version); @@ -253,14 +254,16 @@ namespace PKHeX.Core return null; } + private static bool LearnMovesNew2Disallowed(this PKM pkm) => pkm.Format == 1 || (pkm.Format >= 7 && pkm.VC); + internal static List GetMovesLevelUp1(int species, int max, int min, GameVersion ver = Any) { return AddMovesLevelUp1(new List(), ver, species, max, min); } - private static List GetMovesLevelUp2(int species, int max, int min, bool korean, int format, GameVersion ver = Any) + private static List GetMovesLevelUp2(int species, int max, int min, bool korean, bool removeNewGSCMoves, GameVersion ver = Any) { var moves = AddMovesLevelUp2(new List(), ver, species, max, min, korean); - if (format == 1) + if (removeNewGSCMoves) moves.RemoveAll(m => m > MaxMoveID_1); return moves; } diff --git a/PKHeX.Core/Legality/Moves/MoveTechnicalMachine.cs b/PKHeX.Core/Legality/Moves/MoveTechnicalMachine.cs index e42deef8b..640cfcbb6 100644 --- a/PKHeX.Core/Legality/Moves/MoveTechnicalMachine.cs +++ b/PKHeX.Core/Legality/Moves/MoveTechnicalMachine.cs @@ -10,7 +10,10 @@ namespace PKHeX.Core switch (generation) { case 1: return GetIsMachine1(species, move); - case 2: return GetIsMachine2(species, move); + case 2: + if (pkm.VC1 && move > Legal.MaxMoveID_1) + return Legal.NONE; + return GetIsMachine2(species, move); case 3: return GetIsMachine3(species, move, pkm.Format, RemoveTransfer); case 4: return GetIsMachine4(species, move, pkm.Format, RemoveTransfer, form); case 5: return GetIsMachine5(species, move, form); @@ -175,7 +178,10 @@ namespace PKHeX.Core switch (generation) { case 1: AddMachine1(r, species); break; - case 2: AddMachine2(r, species); break; + case 2: AddMachine2(r, species); + if (pkm.Format >= 7 && pkm.VC1) + r.RemoveAll(z => z > Legal.MaxMoveID_1); + break; case 3: AddMachine3(r, species, pkm.Format, RemoveTransfer); break; case 4: AddMachine4(r, species, pkm.Format, RemoveTransfer, form); break; case 5: AddMachine5(r, species, form); break;