mirror of
https://github.com/kwsch/PKHeX.git
synced 2026-08-28 16:45:28 -05:00
Search mystery gift relearn moves for needed moves
Add to encountertrades searcher, for futureproofing solves gen8 mg searching volt tackle pikachu
This commit is contained in:
@@ -291,7 +291,7 @@ private static IEnumerable<MysteryGift> GetGifts(PKM pk, IReadOnlyCollection<int
|
||||
yield return gift;
|
||||
continue;
|
||||
}
|
||||
var em = gift.Moves;
|
||||
var em = gift.Moves.Concat(gift.Relearn);
|
||||
if (!needs.Except(em).Any())
|
||||
yield return gift;
|
||||
}
|
||||
@@ -373,6 +373,8 @@ private static IEnumerable<EncounterTrade> GetTrades(PKM pk, IReadOnlyCollection
|
||||
IEnumerable<int> em = trade.Moves;
|
||||
if (trade.Generation <= 2)
|
||||
em = em.Concat(MoveLevelUp.GetEncounterMoves(trade.Species, 0, trade.Level, trade.Version));
|
||||
else if (trade is IRelearn { Relearn: { Count: not 0 } } r)
|
||||
em = em.Concat(r.Relearn);
|
||||
if (!needs.Except(em).Any())
|
||||
yield return trade;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user