Add unnicknamed forced languageID wc7 handling

https://projectpokemon.org/home/forums/topic/47295-bug-event-golduck-name-not-matching-species/
another edge case
This commit is contained in:
Kurt 2018-08-29 20:36:32 -07:00
parent e9059023eb
commit ebae14e6ad
2 changed files with 16 additions and 2 deletions

View file

@ -105,10 +105,19 @@ namespace PKHeX.Core
if (!match)
{
if (EncounterMatch is WC7 wc7 && wc7.IsAshGreninjaWC7(pkm))
data.AddLine(GetValid(V19));
if (EncounterMatch is WC7 wc7)
{
if (wc7.IsAshGreninjaWC7(pkm))
data.AddLine(GetValid(V19));
else if (wc7.Language != 0 && !wc7.IsNicknamed && !PKX.IsNicknamedAnyLanguage(pkm.Species, nickname, pkm.Format))
data.AddLine(GetValid(V18)); // fixed language without nickname, nice job event maker!
else
data.AddLine(GetInvalid(V20));
}
else
{
data.AddLine(GetInvalid(V20));
}
}
else
{

View file

@ -584,6 +584,11 @@ namespace PKHeX.WinForms.Controls
CB_Ball.SelectedValue = (int)Ball.Poke;
return;
}
if (ModifierKeys.HasFlag(Keys.Shift))
{
CB_Ball.SelectedValue = BallRandomizer.ApplyBallLegalByColor(pkm);
return;
}
var legal = BallRandomizer.GetLegalBalls(pkm).ToArray();
var poss = ((Ball[]) Enum.GetValues(typeof(Ball))).Skip(1)