Skip to content

Commit

Permalink
Merge pull request #54 from bucanero/patch-1
Browse files Browse the repository at this point in the history
Fix PS1 PSV header save size
  • Loading branch information
ShendoXT authored Oct 27, 2024
2 parents 2d0f2ba + c763b7c commit f4585af
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion MemcardRex.Core/ps1card.cs
Original file line number Diff line number Diff line change
Expand Up @@ -502,12 +502,12 @@ private byte[] MakePsvSave(byte[] save)
psvSave[0x3C] = 1;
psvSave[0x44] = 0x84;
psvSave[0x49] = 2;
psvSave[0x5D] = 0x20;
psvSave[0x60] = 3;
psvSave[0x61] = 0x90;

Array.Copy(save, 0x0A, psvSave, 0x64, 0x20);
Array.Copy(BitConverter.GetBytes(save.Length - 0x80), 0, psvSave, 0x40, 4);
Array.Copy(BitConverter.GetBytes(save.Length - 0x80), 0, psvSave, 0x5C, 4);
Array.Copy(save, 0x80, psvSave, 0x84, save.Length - 0x80);

using (SHA1 sha = SHA1.Create())
Expand Down

0 comments on commit f4585af

Please sign in to comment.