mirror of
https://github.com/kwsch/PKHeX
synced 2024-12-03 17:29:13 +00:00
fix gen3 once-saved saves
Catch a case that all BitOrder is 0. (after delete all data)
This commit is contained in:
parent
ac20c0574b
commit
d49fdfbe89
1 changed files with 2 additions and 0 deletions
|
@ -206,6 +206,8 @@ namespace PKHeX.Core
|
|||
// Real 0th block comes before block1.
|
||||
if (BlockOrder[0] == 1 && Block0 != BlockOrder.Length - 1)
|
||||
continue;
|
||||
if (BlockOrder.Count(v => v == 0) == BlockOrder.Length)
|
||||
continue;
|
||||
uint GameCode = BitConverter.ToUInt32(data, Block0 * 0x1000 + 0xAC + ofs);
|
||||
if (GameCode == uint.MaxValue)
|
||||
return GameVersion.Unknown; // what a hack
|
||||
|
|
Loading…
Reference in a new issue