FlagBrew / PKSM

Gen I to GenVIII save manager.
GNU General Public License v3.0
1.67k stars 173 forks source link

Bug Report - Editing storage in PKSM disrupts HeartGold cartridge's ability to save correctly #1456

Open fireanddream opened 2 months ago

fireanddream commented 2 months ago

Describe the bug On a Japanese HeartGold cartridge, making changes to storage will write a readable save file with no issue. However, when I load up that save file, make some changes to storage (in-game), and save, the next time I boot up the game it says it's corrupted the reverts to my backup save file.

To Reproduce

  1. Open PKSM and make changes to three boxes, releasing one pokemon from each, not editing anything else.
  2. Write save to cartridge.
  3. Boot up the game, go to a PC and take out a single pokemon. Save and shut down the console.
  4. The next time the game boots up, it shows the error message and reads the backup save.

Expected behavior The game reads the save it created normally after a PKSM edit.

Screenshots IMG_20240426_232203

Information about your environment

Additional context PKSM still reads the latest save file (created by the game) perfectly. I don't have any issue with dirty contact points or any other games mulfunctioning. Most importantly, if I save twice in-game, the save file is read successfully after a restart. My save file at all three stages: https://mega.nz/folder/sHIHjKBR#b2SZsKp5WUnz-66-NL59Rw

Volcan4436 commented 3 weeks ago

just speculation but I am thinking its PKSM not creating the right Save Hash