diff --git a/PKHeX.Core/Legality/Core.cs b/PKHeX.Core/Legality/Core.cs index ba5280a06..ebc29f247 100644 --- a/PKHeX.Core/Legality/Core.cs +++ b/PKHeX.Core/Legality/Core.cs @@ -56,7 +56,8 @@ namespace PKHeX.Core { if (format != 7) return GetPPTable(format); - return pkm.GG ? MovePP_GG : MovePP_SM; + var lgpe = pkm.Version is (int) GameVersion.GO or (int) GameVersion.GP or (int) GameVersion.GE; + return lgpe ? MovePP_GG : MovePP_SM; } public static IReadOnlyList GetPPTable(int format) @@ -196,7 +197,7 @@ namespace PKHeX.Core internal static bool HasVisitedB2W2(this PKM pkm, int species) => pkm.InhabitedGeneration(5, species); internal static bool HasVisitedORAS(this PKM pkm, int species) => pkm.InhabitedGeneration(6, species) && (pkm.AO || !pkm.IsUntraded); internal static bool HasVisitedUSUM(this PKM pkm, int species) => pkm.InhabitedGeneration(7, species) && (pkm.USUM || !pkm.IsUntraded); - internal static bool IsMovesetRestricted(this PKM pkm, int gen) => (pkm.GG && gen == 7) || pkm.IsUntraded; + internal static bool IsMovesetRestricted(this PKM pkm, int gen) => (gen == 7 && pkm.Version is (int)GameVersion.GO or (int)GameVersion.GP or (int)GameVersion.GE) || pkm.IsUntraded; public static bool IsValidMissingLanguage(PKM pkm) { diff --git a/PKHeX.Core/Legality/Evolutions/EvolutionTree.cs b/PKHeX.Core/Legality/Evolutions/EvolutionTree.cs index 10a859ec6..196607499 100644 --- a/PKHeX.Core/Legality/Evolutions/EvolutionTree.cs +++ b/PKHeX.Core/Legality/Evolutions/EvolutionTree.cs @@ -59,7 +59,7 @@ namespace PKHeX.Core 4 => Evolves4, 5 => Evolves5, 6 => Evolves6, - 7 => (pkm.GG ? Evolves7b : Evolves7), + 7 => pkm.Version is (int)GO or (int)GP or (int)GE ? Evolves7b : Evolves7, _ => Evolves8 }; } diff --git a/PKHeX.Core/Legality/Moves/MoveEgg.cs b/PKHeX.Core/Legality/Moves/MoveEgg.cs index 54af60dc1..d2d20b104 100644 --- a/PKHeX.Core/Legality/Moves/MoveEgg.cs +++ b/PKHeX.Core/Legality/Moves/MoveEgg.cs @@ -13,7 +13,7 @@ namespace PKHeX.Core if (!pkm.InhabitedGeneration(gen, species) || (pkm.PersonalInfo.Genderless && !FixedGenderFromBiGender.Contains(species))) return Array.Empty(); - if (pkm.Version == 15 || pkm.GG) + if (pkm.Version is (int)GO or (int)GP or (int)GE or (int)CXD) return Array.Empty(); if (version == Any) diff --git a/PKHeX.Core/Legality/Moves/MoveTutor.cs b/PKHeX.Core/Legality/Moves/MoveTutor.cs index 0ce74c106..1bc4258f6 100644 --- a/PKHeX.Core/Legality/Moves/MoveTutor.cs +++ b/PKHeX.Core/Legality/Moves/MoveTutor.cs @@ -268,7 +268,7 @@ namespace PKHeX.Core private static void AddMovesTutor7(List moves, int species, int form, PKM pkm, bool specialTutors) { - if (pkm.GG) + if (pkm.Version is (int)GameVersion.GO or (int)GameVersion.GP or (int)GameVersion.GE) return; var pi = PersonalTable.USUM.GetFormEntry(species, form); moves.AddRange(TypeTutor6.Where((_, i) => pi.TypeTutors[i]));