Skip to content

Commit

Permalink
Fix raid seed editing
Browse files Browse the repository at this point in the history
Because we pass in a reference to the raid block, rather than obtain the reference from the to-be-edited save file object (which was cloned), we need to restore the unmodified data to the save file instead of copying the modified save data.

Bad explanation, but we've edited the origin save data. Revert to original.
  • Loading branch information
kwsch committed Jun 20, 2020
1 parent 808ca8f commit 45a2348
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion PKHeX.WinForms/Subforms/Save Editors/Gen8/SAV_Raid8.cs
Expand Up @@ -25,12 +25,13 @@ public SAV_Raid8(SaveFile sav, RaidSpawnList8 raid)

private void B_Cancel_Click(object sender, EventArgs e)
{
// We've been editing the original save file blocks. Restore the clone's data.
Origin.CopyChangesFrom(SAV);
Close();
}

private void B_Save_Click(object sender, EventArgs e)
{
Origin.CopyChangesFrom(SAV);
Close();
}

Expand Down

0 comments on commit 45a2348

Please sign in to comment.