mirror of
https://github.com/kwsch/PKHeX.git
synced 2026-05-20 20:58:30 -05:00
Add static encounter egg edge case handling
Closes #1219 reject the eevee case if any relearn moves are present allow traded eggs to be matched
This commit is contained in:
parent
cf8f6573f2
commit
bb6c5e3dbb
|
|
@ -310,7 +310,19 @@ private static IEnumerable<EncounterStatic> getMatchingStaticEncounters(PKM pkm,
|
|||
continue;
|
||||
}
|
||||
else if (e.EggLocation != pkm.Egg_Location)
|
||||
continue;
|
||||
{
|
||||
switch (pkm.GenNumber)
|
||||
{
|
||||
case 4:
|
||||
if (pkm.Egg_Location != 2002) // Link Trade
|
||||
continue;
|
||||
break;
|
||||
default:
|
||||
if (pkm.Egg_Location != 30002) // Link Trade
|
||||
continue;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (pkm.HasOriginalMetLocation)
|
||||
{
|
||||
if (e.Location != 0 && e.Location != pkm.Met_Location)
|
||||
|
|
@ -324,6 +336,8 @@ private static IEnumerable<EncounterStatic> getMatchingStaticEncounters(PKM pkm,
|
|||
continue;
|
||||
if (e.Form != pkm.AltForm && !e.SkipFormCheck && !getCanFormChange(pkm, e.Species))
|
||||
continue;
|
||||
if (e.EggLocation == 60002 && e.Relearn[0] == 0 && pkm.RelearnMoves.Any(z => z != 0)) // gen7 eevee edge case
|
||||
continue;
|
||||
|
||||
if (pkm is PK1 pk1 && pkm.Gen1_NotTradeback)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user