mirror of
https://github.com/kwsch/PKHeX
synced 2025-02-17 05:48:44 +00:00
boxdata i/o + changelog
This commit is contained in:
parent
bc53411f45
commit
8ab19985c5
3 changed files with 26 additions and 3 deletions
1
PKX/f1-Main.Designer.cs
generated
1
PKX/f1-Main.Designer.cs
generated
|
@ -3785,6 +3785,7 @@
|
|||
this.L_SAVManipulation.Size = new System.Drawing.Size(117, 13);
|
||||
this.L_SAVManipulation.TabIndex = 7;
|
||||
this.L_SAVManipulation.Text = "Save File Manipulation:";
|
||||
this.L_SAVManipulation.Click += new System.EventHandler(this.L_SAVManipulation_Click);
|
||||
//
|
||||
// B_SwitchSAV
|
||||
//
|
||||
|
|
|
@ -533,8 +533,8 @@ namespace PKHeX
|
|||
}
|
||||
#endregion
|
||||
#region Box Data
|
||||
else if (input.Length == 0xE8 * 30 * 31)
|
||||
{ Array.Copy(input, 0, savefile, SaveGame.Box, input.Length); setPKXBoxes(); Util.Alert("Box Binary loaded."); }
|
||||
else if (input.Length == 0xE8 * 30)
|
||||
{ Array.Copy(input, 0, savefile, SaveGame.Box + 0xE8 * 30 * C_BoxSelect.SelectedIndex, input.Length); setPKXBoxes(); Util.Alert("Box Binary loaded."); }
|
||||
#endregion
|
||||
else
|
||||
Util.Error("Attempted to load an unsupported file type/size.", "File Loaded:" + Environment.NewLine + path);
|
||||
|
@ -2916,6 +2916,8 @@ namespace PKHeX
|
|||
}
|
||||
private void clickExportSAV(object sender, EventArgs e)
|
||||
{
|
||||
if (ModifierKeys == Keys.Control) { exportBoxes(); return; }
|
||||
|
||||
// Create another version of the save file.
|
||||
byte[] editedsav = new byte[0x100000];
|
||||
Array.Copy(savefile, editedsav, savefile.Length);
|
||||
|
@ -4056,6 +4058,21 @@ namespace PKHeX
|
|||
Util.Alert(result);
|
||||
}
|
||||
}
|
||||
private void exportBox()
|
||||
{
|
||||
if (Util.Prompt(MessageBoxButtons.YesNo, "Export Boxes?") == DialogResult.Yes)
|
||||
{
|
||||
SaveFileDialog sfd = new SaveFileDialog();
|
||||
sfd.Filter = "Box Data|*.bin";
|
||||
sfd.FileName = "boxdata.bin";
|
||||
if (sfd.ShowDialog() == DialogResult.OK)
|
||||
File.WriteAllBytes(sfd.FileName, savefile.Skip(SaveGame.Box + 0xE8 * 30 * C_BoxSelect.SelectedIndex).Take(0xE8 * 30).ToArray());
|
||||
}
|
||||
}
|
||||
private void L_SAVManipulation_Click(object sender, EventArgs e)
|
||||
{
|
||||
exportBoxes();
|
||||
}
|
||||
// Subfunction Save Buttons //
|
||||
private void B_OpenWondercards_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
@ -4465,5 +4482,6 @@ namespace PKHeX
|
|||
private int pkm_from_offset = 0;
|
||||
private int pkm_from_slot = -1;
|
||||
#endregion
|
||||
|
||||
}
|
||||
}
|
|
@ -443,4 +443,8 @@ http://projectpokemon.org/forums/showthread.php?36986
|
|||
- Fixed: Super Training copying too much and erroring out. Thanks SoujiSeta!
|
||||
- Fixed: Mono compatibility fix for inventory data editing. Thanks SoujiSeta!
|
||||
- Fixed: Deleting Wondercard recieved flags will actually save. Thanks ifyfg!
|
||||
- Fixed: X/Y xorpad auto-loading/decryption now works instead of hanging.
|
||||
- Fixed: X/Y xorpad auto-loading/decryption now works instead of hanging.
|
||||
|
||||
1/25/15 - New Update:
|
||||
- Added: PK6 Distribution Super Training flags. Still have to unlock the missions ingame with wondercards. Thanks SciresM!
|
||||
- Added: Box Import functionality for use with the spider web exploit.
|
Loading…
Add table
Reference in a new issue