mirror of
https://github.com/kwsch/PKHeX
synced 2024-11-10 14:44:24 +00:00
Add missing validity setters
Game checks for these region codes, if missing they won't appear in party/box. just set to an arbitrary value
This commit is contained in:
parent
53f8abc26c
commit
e51daa3a4b
2 changed files with 16 additions and 0 deletions
|
@ -274,6 +274,17 @@ namespace PKHeX
|
|||
return data;
|
||||
}
|
||||
|
||||
protected override void setPKM(PKM pkm)
|
||||
{
|
||||
var pk = pkm as CK3;
|
||||
if (pk == null)
|
||||
return;
|
||||
|
||||
if (pk.CurrentRegion == 0)
|
||||
pk.CurrentRegion = 2; // NTSC-U
|
||||
if (pk.OriginalRegion == 0)
|
||||
pk.OriginalRegion = 2; // NTSC-U
|
||||
}
|
||||
protected override void setDex(PKM pkm)
|
||||
{
|
||||
// Dex Related
|
||||
|
|
|
@ -266,6 +266,11 @@ namespace PKHeX
|
|||
if (pk == null)
|
||||
return; // shouldn't ever hit
|
||||
|
||||
if (pk.CurrentRegion == 0)
|
||||
pk.CurrentRegion = 2; // NTSC-U
|
||||
if (pk.OriginalRegion == 0)
|
||||
pk.OriginalRegion = 2; // NTSC-U
|
||||
|
||||
// Set Shadow Data back to save
|
||||
if (pk.ShadowID <= 0 || pk.ShadowID >= ShadowInfo.Count)
|
||||
return;
|
||||
|
|
Loading…
Reference in a new issue