Fix recognition for cutecharm Nincada->Shedinja

GetGender would return 2, which would abort the Cute Charm check since genderless is not able to be cute-charm'd.
https://projectpokemon.org/home/forums/topic/57375-pkhex-new-update-legality-errors-contribution-page/?do=findComment&comment=271537
This commit is contained in:
Kurt 2021-12-26 18:22:41 -08:00
parent 11039f1119
commit 3d7967fcfe

View file

@ -929,7 +929,7 @@ namespace PKHeX.Core
private static (int Species, int Gender) GetCuteCharmGenderSpecies(PKM pk, uint pid, int currentSpecies) => currentSpecies switch
{
// Nincada evo chain travels from M/F -> Genderless Shedinja
(int)Species.Shedinja => ((int)Species.Nincada, PKX.GetGenderFromPID(currentSpecies, pid)),
(int)Species.Shedinja => ((int)Species.Nincada, PKX.GetGenderFromPID((int)Species.Nincada, pid)),
// These evolved species cannot be encountered with cute charm.
// 100% fixed gender does not modify PID; override this with the encounter species for correct calculation.