Allow Strongest Trainer memory on gen6-visitors banned from Maison

https://projectpokemon.org/home/forums/topic/57375-pkhex-new-update-legality-errors-contribution-page/?do=findComment&comment=265898

End result is only gen7-origin-in-gen7 are disallowed.

Co-Authored-By: Matt <17801814+sora10pls@users.noreply.github.com>
This commit is contained in:
Kurt 2021-04-16 08:53:50 -07:00
parent 4bb5433489
commit 16406d7bba

View file

@ -252,8 +252,10 @@ namespace PKHeX.Core
yield return new RibbonResult(rib);
}
// Gen6 can get the memory on those who did not participate by being in the party with other participants.
// This includes those who cannot enter into the Maison; having memory and no ribbon.
const int memChatelaine = 30;
bool hasChampMemory = pkm.Format <= 7 && pkm is ITrainerMemories m && (m.HT_Memory == memChatelaine || m.OT_Memory == memChatelaine);
bool hasChampMemory = enc.Generation == 7 && pkm.Format == 7 && pkm is ITrainerMemories m && (m.HT_Memory == memChatelaine || m.OT_Memory == memChatelaine);
if (!IsAllowedBattleFrontier(pkm.Species))
{
if (hasChampMemory || s6.RibbonBattlerSkillful) // having memory and not ribbon is too rare, just flag here.