Merge pull request #1170 from javierhimura/master

Mark OT Female trainer from Gamecube and VC pokemon as invalid.
This commit is contained in:
Kurt 2017-05-28 10:27:58 -07:00 committed by GitHub
commit 92881e489c
5 changed files with 23 additions and 3 deletions

View file

@ -422,9 +422,21 @@ namespace PKHeX.Core
else if (pkm.SID == 0)
AddLine(Severity.Fishy, V37, CheckIdentifier.Trainer);
if (pkm.OT_Gender == 1)
verifyOTFemale();
if (pkm.VC)
verifyG1OT();
}
private void verifyOTFemale()
{
if (pkm.Format < 3) // Format 2 pkm with ot gender stored are from crystal, female player is allowed
return;
if (pkm.Version == 15)
AddLine(Severity.Invalid, V407, CheckIdentifier.Trainer);
else if (pkm.VC) // If VC2 is realease probably more checks will be needed
AddLine(Severity.Invalid, V407, CheckIdentifier.Trainer);
}
private void verifyG1OT()
{
string tr = pkm.OT_Name;

View file

@ -400,6 +400,8 @@ namespace PKHeX.Core
public static string V402 {get; set;} = "Incorrect Stadium OT.";
public static string V405 {get; set;} = "Outsider {0} should have evolved into {1}.";
public static string V406 {get; set;} = "Non japanese Shadow E-reader Pokémon. Unreleased encounter.";
public static string V407 {get; set;} = "OT Trainer from Colloseum/XD could not be female.";
public static string V408 {get; set;} = "OT Trainer from generation 1 could not be female.";
#endregion
}

View file

@ -336,4 +336,6 @@ V400 = Unable to match encounter conditions to a possible RNG frame.
V401 = In-game trade {0} should have evolved into {1}.
V402 = Incorrect Stadium OT.
V405 = Outsider {0} should have evolved into {1}.
V406 = Non japanese Shadow E-reader Pokémon. Unreleased encounter.
V406 = Non japanese Shadow E-reader Pokémon. Unreleased encounter.
V407 = OT Trainer from Colloseum/XD could not be female.
V408 = OT Trainer from generation 1 could not be female.

View file

@ -337,4 +337,6 @@ V400 = Unable to match encounter conditions to a possible RNG frame.
V401 = In-game trade {0} should have evolved into {1}.
V402 = Incorrect Stadium OT.
V405 = Outsider {0} should have evolved into {1}.
V406 = Non japanese Shadow E-reader Pokémon. Unreleased encounter.
V406 = Non japanese Shadow E-reader Pokémon. Unreleased encounter.
V407 = OT Trainer from Colloseum/XD could not be female.
V408 = OT Trainer from generation 1 could not be female.

View file

@ -336,4 +336,6 @@ V400 = 遇见方式无法与可能的乱数帧匹配。
V401 = 游戏内交换{0}应当进化为{1}.
V402 = 不正确竞技场初训家。
V405 = 外来的{0}应当进化为{1}.
V406 = 非日版黑暗E-reader宝可梦。未解禁遇见方式。
V406 = 非日版黑暗E-reader宝可梦。未解禁遇见方式。
V407 = OT Trainer from Colloseum/XD could not be female.
V408 = OT Trainer from generation 1 could not be female.