From 1f8c72af5aa2e901ee02cdeff3323f6e8a47fd2e Mon Sep 17 00:00:00 2001 From: Kurt Date: Sat, 19 May 2018 21:49:26 -0700 Subject: [PATCH] Handle EncounterTrade without moves specified Similar to EncounterStatic handling Thanks @architdate for pointing this out --- .../Legality/Encounters/Generator/EncounterMovesetGenerator.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PKHeX.Core/Legality/Encounters/Generator/EncounterMovesetGenerator.cs b/PKHeX.Core/Legality/Encounters/Generator/EncounterMovesetGenerator.cs index 2bd484eec..163e80517 100644 --- a/PKHeX.Core/Legality/Encounters/Generator/EncounterMovesetGenerator.cs +++ b/PKHeX.Core/Legality/Encounters/Generator/EncounterMovesetGenerator.cs @@ -267,7 +267,7 @@ private static IEnumerable GetTrades(PKM pk, IReadOnlyCollection continue; } var em = trade.Moves; - if (!needs.Except(em).Any()) + if (em != null && !needs.Except(em).Any()) yield return trade; } }