diff --git a/PKHeX.Core/Legality/Evolutions/EvolutionGroup/EvolutionGroupHOME.cs b/PKHeX.Core/Legality/Evolutions/EvolutionGroup/EvolutionGroupHOME.cs index 118887134..a07145f88 100644 --- a/PKHeX.Core/Legality/Evolutions/EvolutionGroup/EvolutionGroupHOME.cs +++ b/PKHeX.Core/Legality/Evolutions/EvolutionGroup/EvolutionGroupHOME.cs @@ -125,19 +125,22 @@ static bool UpdateIfBetter(ref EvoCriteria reference, in EvoCriteria evo) } } - history.Gen8 = SetHistory(result, PersonalTable.SWSH); - history.Gen8a = SetHistory(result, PersonalTable.LA); - history.Gen8b = SetHistory(result, PersonalTable.BDSP); - history.Gen9 = SetHistory(result, PersonalTable.SV); - - if (history.HasVisitedGen7) + // Can't leave BD/SP. Abort early. + if (pk is { Species: (int)Species.Nincada or (int)Species.Spinda, BDSP: true }) { - // 0->X Alolan forms can't evolve after Gen7 (yet). - if (pk is { Species: (int)Species.Raichu, Form: 1 }) - history.Gen8b = history.Gen8a = Array.Empty(); - // All others can't enter otherwise (not in game). + history.Gen8b = SetHistory(result, PersonalTable.BDSP); + return present; } + history.Gen9 = SetHistory(result, PersonalTable.SV); + history.Gen8 = SetHistory(result, PersonalTable.SWSH); + if (pk is { Species: (int)Species.Raichu, Form: 1 } && history.HasVisitedGen7) + return present; // Alolan Raichu can't enter Gen8a/b. + history.Gen8a = SetHistory(result, PersonalTable.LA); + if (pk is { Species: (int)Species.Nincada or (int)Species.Spinda }) + return present; // Nincada/Spinda can't enter Gen8b. + history.Gen8b = SetHistory(result, PersonalTable.BDSP); + return present; } @@ -272,8 +275,7 @@ public bool TryEvolve(ISpeciesForm head, ISpeciesForm next, PKM pk, byte current // Unreleased Item private static bool IsEvolutionBanned(in ISpeciesForm head) => head.Species switch { - (int)Species.Slowpoke => head.Form != 1, - (int)Species.Slowbro => head.Form != 2, + (int)Species.Slowpoke => head.Form == 1, _ => false, }; } diff --git a/PKHeX.Core/Legality/Verifiers/TransferVerifier.cs b/PKHeX.Core/Legality/Verifiers/TransferVerifier.cs index 6cd27aef7..f64e1bf68 100644 --- a/PKHeX.Core/Legality/Verifiers/TransferVerifier.cs +++ b/PKHeX.Core/Legality/Verifiers/TransferVerifier.cs @@ -126,6 +126,8 @@ public void VerifyTransferLegalityG8(LegalityAnalysis data) var pk = data.Entity; var enc = data.EncounterMatch; bool native = enc.Generation == 8 && pk.IsNative; + if (native && pk is PK8 pk8 && LocationsHOME.IsLocationSWSH(pk8.Met_Location)) + native = false; if (!native || IsHOMETrackerRequired(enc)) VerifyHOMETracker(data, pk);