diff --git a/Misc/CodeGenerator.cs b/Misc/CodeGenerator.cs index 130af3482..1732e9314 100644 --- a/Misc/CodeGenerator.cs +++ b/Misc/CodeGenerator.cs @@ -14,8 +14,8 @@ namespace PKHeX { public partial class CodeGenerator : Form { - byte[] codedata = new Byte[232]; - byte[] newdata = new Byte[232]; + byte[] codedata = new byte[232]; + byte[] newdata = new byte[232]; SaveGames.SaveStruct SaveGame = new SaveGames.SaveStruct(null); Form1 m_parent; @@ -42,7 +42,7 @@ namespace PKHeX if (m_parent.verifiedpkx()) { byte[] pkx = m_parent.preparepkx(m_parent.buff); - newdata = new Byte[232]; + newdata = new byte[232]; Array.Copy(PKX.encryptArray(pkx), newdata, 232); } else return false; @@ -50,14 +50,14 @@ namespace PKHeX } else if (CB_Source.SelectedIndex == 1) { - newdata = new Byte[0xE8]; + newdata = new byte[0xE8]; Array.Copy(m_parent.savefile, SaveGame.Box // Box Offset + CB_Box.SelectedIndex * (232 * 30) // Box Shift + CB_Slot.SelectedIndex * 232, // Slot Shift newdata, 0, 0xE8); - if (newdata.SequenceEqual(new Byte[0xE8])) + if (newdata.SequenceEqual(new byte[0xE8])) { System.Media.SystemSounds.Exclamation.Play(); return false; @@ -66,12 +66,12 @@ namespace PKHeX else if (CB_Source.SelectedIndex == 2) { // Wondercard - newdata = new Byte[0x108]; + newdata = new byte[0x108]; // Wondercard # int wcn = CB_Slot.SelectedIndex; // copy from save, the chosen wondercard offset, to new data Array.Copy(m_parent.savefile, SaveGame.Wondercard + wcn * 0x108 + 0x100, newdata, 0, 0x108); - byte[] zerodata = new Byte[0x108]; + byte[] zerodata = new byte[0x108]; if (newdata.SequenceEqual(zerodata)) { System.Media.SystemSounds.Exclamation.Play(); @@ -193,7 +193,7 @@ namespace PKHeX // Gotta read in the textbox. if (RTB_Code.Text.Length < 1) return; - byte[] ncf = new Byte[4 + (RTB_Code.Lines.Count()-1) * (3 * 4)]; + byte[] ncf = new byte[4 + (RTB_Code.Lines.Count()-1) * (3 * 4)]; Array.Copy(BitConverter.GetBytes(ncf.Length - 4), ncf, 4); for (int i = 0; i < RTB_Code.Lines.Count()-1; i++) @@ -244,7 +244,7 @@ namespace PKHeX RTB_Code.Clear(); byte[] cybersav = m_parent.cyberSAV; byte[] editedsav = m_parent.savefile; - byte[] newcyber = new Byte[m_parent.cyberSAV.Length]; + byte[] newcyber = new byte[m_parent.cyberSAV.Length]; Array.Copy(editedsav, 0x5400, newcyber, 0, newcyber.Length); int boxoffset = 0x22600; @@ -273,8 +273,8 @@ namespace PKHeX // Loop Through Party for (int i = 0x14200; i < 0x14200 + 260 * 6; i+= 260) { - byte[] newdata = new Byte[260]; Array.Copy(newcyber, i, newdata, 0, 260); - byte[] olddata = new Byte[260]; Array.Copy(cybersav, i, olddata, 0, 260); + byte[] newdata = new byte[260]; Array.Copy(newcyber, i, newdata, 0, 260); + byte[] olddata = new byte[260]; Array.Copy(cybersav, i, olddata, 0, 260); if (!newdata.SequenceEqual(olddata)) { for (int z = 0; z < newdata.Length; z += 4) @@ -305,8 +305,8 @@ namespace PKHeX // Loop Through Boxes for (int i = boxoffset; i < boxoffset + (232 * 30 * 31); i += 232) { - byte[] newdata = new Byte[232]; Array.Copy(newcyber, i, newdata, 0, 232); - byte[] olddata = new Byte[232]; Array.Copy(cybersav, i, olddata, 0, 232); + byte[] newdata = new byte[232]; Array.Copy(newcyber, i, newdata, 0, 232); + byte[] olddata = new byte[232]; Array.Copy(cybersav, i, olddata, 0, 232); if (!newdata.SequenceEqual(olddata)) { for (int z = 0; z < newdata.Length; z += 4) @@ -344,7 +344,7 @@ namespace PKHeX { // Gotta read in the textbox. if (RTB_Code.Text.Length < 1) return; - byte[] data = new Byte[0]; + byte[] data = new byte[0]; // Get Actual Lines for (int i = 0; i < RTB_Code.Lines.Count(); i++) { diff --git a/Misc/pk2pk.cs b/Misc/pk2pk.cs index c1013863e..9f079cc38 100644 --- a/Misc/pk2pk.cs +++ b/Misc/pk2pk.cs @@ -938,7 +938,7 @@ namespace PKHeX } public byte[] convertPK3toPK4(byte[] pk3) { - byte[] pk4 = new Byte[136]; + byte[] pk4 = new byte[136]; Array.Copy(pk3, 0, pk4, 0, 4); Array.Copy(pk3, 0x20, pk4, 0x08, 2); // Species @@ -1160,7 +1160,7 @@ namespace PKHeX } public byte[] convertPK4toPK5(byte[] pk4) { - byte[] pk5 = new Byte[136]; + byte[] pk5 = new byte[136]; if (pk4[0x5F] < 0x10 && BitConverter.ToUInt16(pk4, 0x80) > 0x4000) return pk4; @@ -1204,7 +1204,7 @@ namespace PKHeX pk5[0x83] = pk4[0x86]; // Transfer Nickname and OT Name DataTable CT45 = Char4to5(); - byte[] nicknamestr = new Byte[24]; + byte[] nicknamestr = new byte[24]; string nickname = ""; string trainer = ""; nicknamestr[22] = nicknamestr[23] = 0xFF; @@ -1222,7 +1222,7 @@ namespace PKHeX nickname += (char)newval; } - byte[] OTstr = new Byte[24]; + byte[] OTstr = new byte[24]; OTstr[22] = OTstr[23] = 0xFF; for (int i = 0; i < 24; i += 2) { @@ -1256,7 +1256,7 @@ namespace PKHeX public byte[] convertPK5toPK6(byte[] pk5) { // To transfer, we will go down the pkm offset list and fill it into the PKX list. - byte[] pk6 = new Byte[232]; // Setup new array to store the new PKX + byte[] pk6 = new byte[232]; // Setup new array to store the new PKX // Check if G4PKM if (pk5[0x5F] < 0x10 && BitConverter.ToUInt16(pk5, 0x80) < 4000) diff --git a/PKHeX.csproj b/PKHeX.csproj index 2c6e582f4..4e51167da 100644 --- a/PKHeX.csproj +++ b/PKHeX.csproj @@ -71,6 +71,12 @@ + + Form + + + f2-Text.cs + Form @@ -102,6 +108,11 @@ f3-MemoryAmie.cs + + True + True + Resources.resx + Form @@ -129,11 +140,6 @@ - - True - True - Resources.resx - Form @@ -213,6 +219,9 @@ SplashScreen.cs + + f2-Text.cs + About.cs @@ -328,6 +337,7 @@ + diff --git a/PKX/f3-MemoryAmie.cs b/PKX/f3-MemoryAmie.cs index 3500044a0..ec9c45a4f 100644 --- a/PKX/f3-MemoryAmie.cs +++ b/PKX/f3-MemoryAmie.cs @@ -14,7 +14,7 @@ namespace PKHeX public partial class MemoryAmie : Form { Form1 m_parent; - public byte[] h = new Byte[260]; // Always Visible + public byte[] h = new byte[260]; // Always Visible private string disabled = "Disabled"; private string notleft = "Never left"; private string ot = "OT"; diff --git a/SAV/SAV_BerryField.cs b/SAV/SAV_BerryField.cs index e4b57e77e..a67981e10 100644 --- a/SAV/SAV_BerryField.cs +++ b/SAV/SAV_BerryField.cs @@ -23,7 +23,7 @@ namespace PKHeX } int berryfoffset; Form1 m_parent; - public byte[] sav = new Byte[0x100000]; + public byte[] sav = new byte[0x100000]; public int savindex; int shiftval; public bool editing = false; diff --git a/SAV/SAV_BoxIO.cs b/SAV/SAV_BoxIO.cs index 3330fc76f..30c6612f2 100644 --- a/SAV/SAV_BoxIO.cs +++ b/SAV/SAV_BoxIO.cs @@ -62,7 +62,7 @@ namespace PKHeX File.WriteAllBytes(path + ".bak", backupfile); } int offset = shiftval + boxoffset + (CB_Box.SelectedIndex) * (0xE8 * 30); - byte[] newbox = new Byte[0xE8 * 30]; + byte[] newbox = new byte[0xE8 * 30]; Array.Copy(m_parent.savefile, offset, newbox, 0, 0xE8 * 30); File.WriteAllBytes(path, newbox); } diff --git a/SAV/SAV_BoxLayout.cs b/SAV/SAV_BoxLayout.cs index 03ffcd554..089138fea 100644 --- a/SAV/SAV_BoxLayout.cs +++ b/SAV/SAV_BoxLayout.cs @@ -28,7 +28,7 @@ namespace PKHeX LB_BoxSelect.SelectedIndex = m_parent.C_BoxSelect.SelectedIndex; } Form1 m_parent; - public byte[] sav = new Byte[0x100000]; + public byte[] sav = new byte[0x100000]; public int savindex; public bool editing = false; private static uint ToUInt32(String value) diff --git a/SAV/SAV_EventFlagsORAS.cs b/SAV/SAV_EventFlagsORAS.cs index 262e31e26..2b60902d6 100644 --- a/SAV/SAV_EventFlagsORAS.cs +++ b/SAV/SAV_EventFlagsORAS.cs @@ -101,7 +101,7 @@ namespace PKHeX //flag_2546, // Pokedex }; int offset = 0x1A0FC + savshift; - byte[] data = new Byte[0x180]; + byte[] data = new byte[0x180]; Array.Copy(m_parent.savefile, offset, data, 0, 0x180); BitArray BitRegion = new BitArray(data); BitRegion.CopyTo(flags, 0); @@ -179,8 +179,8 @@ namespace PKHeX else TB_UnSet.AppendText(i.ToString("0000") + ","); } - private byte[] olddata = new Byte[0x180]; - private byte[] newdata = new Byte[0x180]; + private byte[] olddata = new byte[0x180]; + private byte[] newdata = new byte[0x180]; private void openSAV(object sender, EventArgs e) { byte[] eventflags = new byte[0x180]; diff --git a/SAV/SAV_EventFlagsXY.cs b/SAV/SAV_EventFlagsXY.cs index c6dcf04ab..a81a6c242 100644 --- a/SAV/SAV_EventFlagsXY.cs +++ b/SAV/SAV_EventFlagsXY.cs @@ -63,7 +63,7 @@ namespace PKHeX flag_2546, // Pokedex }; int offset = 0x1A0FC + savshift; - byte[] data = new Byte[0x180]; + byte[] data = new byte[0x180]; Array.Copy(m_parent.savefile, offset, data, 0, 0x180); BitArray BitRegion = new BitArray(data); BitRegion.CopyTo(flags, 0); @@ -147,8 +147,8 @@ namespace PKHeX } } } - private byte[] olddata = new Byte[0x180]; - private byte[] newdata = new Byte[0x180]; + private byte[] olddata = new byte[0x180]; + private byte[] newdata = new byte[0x180]; private void openSAV(object sender, EventArgs e) { byte[] eventflags = new byte[0x180]; diff --git a/SAV/SAV_HallOfFame.cs b/SAV/SAV_HallOfFame.cs index de8dd0848..0ffb9cb7a 100644 --- a/SAV/SAV_HallOfFame.cs +++ b/SAV/SAV_HallOfFame.cs @@ -54,7 +54,7 @@ namespace PKHeX editing = true; } Form1 m_parent; - public byte[] sav = new Byte[0x100000]; + public byte[] sav = new byte[0x100000]; public int savindex; int shiftval; public bool editing = false; private int data_offset = 0x1E800; diff --git a/SAV/SAV_Inventory.cs b/SAV/SAV_Inventory.cs index 55b29c6a7..a2ce7a7ae 100644 --- a/SAV/SAV_Inventory.cs +++ b/SAV/SAV_Inventory.cs @@ -48,7 +48,7 @@ namespace PKHeX B_DisplayKeyItems.Text = Form1.itempouch[4]; } Form1 m_parent; - public byte[] sav = new Byte[0x100000]; + public byte[] sav = new byte[0x100000]; public int savindex; int shiftval; public bool editing = false; diff --git a/SAV/SAV_OPower.cs b/SAV/SAV_OPower.cs index 32fd72c1a..34abcf755 100644 --- a/SAV/SAV_OPower.cs +++ b/SAV/SAV_OPower.cs @@ -89,7 +89,7 @@ namespace PKHeX for (int i = 0; i < cba.Length; i++) { - byte[] data = new Byte[cba[i].Items.Count - 1]; + byte[] data = new byte[cba[i].Items.Count - 1]; for (int c = 0; c < cba[i].SelectedIndex; c++) { data[c] = 1; @@ -116,7 +116,7 @@ namespace PKHeX byte[] _3 = new byte[] { 01, 01, 01, 00, }; byte[] _4 = new byte[] { 01, 01, 01, 01, }; - byte[] data = new Byte[4]; + byte[] data = new byte[4]; Array.Copy(m_parent.savefile, o, data, 0, l); if (data.SequenceEqual(_4)) return 4; diff --git a/SAV/SAV_PokedexORAS.cs b/SAV/SAV_PokedexORAS.cs index e81f7d236..0236d8c4f 100644 --- a/SAV/SAV_PokedexORAS.cs +++ b/SAV/SAV_PokedexORAS.cs @@ -26,7 +26,7 @@ namespace PKHeX } private int dexoffset = 0x15000 + 0x5400; Form1 m_parent; - public byte[] sav = new Byte[0x100000]; + public byte[] sav = new byte[0x100000]; public int sv = 0; public bool[,] specbools = new bool[9, 0x60 * 8]; public bool[,] langbools = new bool[7, 0x60 * 8]; @@ -71,7 +71,7 @@ namespace PKHeX // Fill Bit arrays for (int i = 0; i < 9; i++) { - byte[] data = new Byte[0x60]; + byte[] data = new byte[0x60]; int offset = dexoffset + 0x8 + 0x60 * i; Array.Copy(sav, offset, data, 0, 0x60); BitArray BitRegion = new BitArray(data); @@ -81,7 +81,7 @@ namespace PKHeX } // Fill Language arrays - byte[] langdata = new Byte[0x280]; + byte[] langdata = new byte[0x280]; Array.Copy(sav, dexoffset + 0x400, langdata, 0, 0x280); BitArray LangRegion = new BitArray(langdata); for (int b = 0; b < (721); b++) // 721 Species diff --git a/SAV/SAV_PokedexXY.cs b/SAV/SAV_PokedexXY.cs index 7d5825009..8f63bd6a4 100644 --- a/SAV/SAV_PokedexXY.cs +++ b/SAV/SAV_PokedexXY.cs @@ -24,7 +24,7 @@ namespace PKHeX TB_Spinda.Text = BitConverter.ToUInt32(sav, 0x1AA48 + Convert.ToInt16(m_parent.savegame_oras) * 0x38).ToString("X8"); } Form1 m_parent; - public byte[] sav = new Byte[0x100000]; + public byte[] sav = new byte[0x100000]; public int savshift = 0; public bool[,] specbools = new bool[10, 0x60 * 8]; public bool[,] langbools = new bool[7, 0x60 * 8]; @@ -74,7 +74,7 @@ namespace PKHeX // Fill Bit arrays for (int i = 0; i < 0xA; i++) { - byte[] data = new Byte[0x60]; + byte[] data = new byte[0x60]; Array.Copy(sav, savshift + 0x1A408 + 0x60 * i, data, 0, 0x60); BitArray BitRegion = new BitArray(data); for (int b = 0; b < (0x60 * 8); b++) @@ -82,7 +82,7 @@ namespace PKHeX } // Fill Language arrays - byte[] langdata = new Byte[0x280]; + byte[] langdata = new byte[0x280]; Array.Copy(sav, savshift + 0x1A7C8, langdata, 0, 0x280); BitArray LangRegion = new BitArray(langdata); for (int b = 0; b < (721); b++) // 721 Species @@ -91,7 +91,7 @@ namespace PKHeX // Fill Foreign array { - byte[] foreigndata = new Byte[0x52]; + byte[] foreigndata = new byte[0x52]; Array.Copy(sav, savshift + 0x1AA4C, foreigndata, 0, 0x52); BitArray ForeignRegion = new BitArray(foreigndata); for (int b = 0; b < (0x52 * 8); b++) diff --git a/SAV/SAV_Pokepuff.cs b/SAV/SAV_Pokepuff.cs index cdfafbd6b..3a0331863 100644 --- a/SAV/SAV_Pokepuff.cs +++ b/SAV/SAV_Pokepuff.cs @@ -28,7 +28,7 @@ namespace PKHeX ToolTip2.SetToolTip(this.B_All, "Hold CTRL to give Deluxe instead of Supreme."); } Form1 m_parent; - public byte[] sav = new Byte[0x100000]; + public byte[] sav = new byte[0x100000]; public int savindex; public bool editing = false; private string[] pfa = { @@ -97,7 +97,7 @@ namespace PKHeX basepuff = 1; basemod = 0x19; } - byte[] newpuffs = new Byte[100]; + byte[] newpuffs = new byte[100]; for (int i = 0; i < 100; i++) { newpuffs[i] = (byte)(Util.rnd32() % basemod + basepuff); @@ -107,7 +107,7 @@ namespace PKHeX } private void B_None_Click(object sender, EventArgs e) { - byte[] newpuffs = new Byte[100]; + byte[] newpuffs = new byte[100]; newpuffs[0] = 1; newpuffs[1] = 2; newpuffs[2] = 3; @@ -118,7 +118,7 @@ namespace PKHeX } private void B_Sort_Click(object sender, EventArgs e) { - byte[] puffarray = new Byte[100]; + byte[] puffarray = new byte[100]; if (ModifierKeys == Keys.Control) { for (int i = 0; i < 100; i++) @@ -151,7 +151,7 @@ namespace PKHeX } private void B_Save_Click(object sender, EventArgs e) { - byte[] puffarray = new Byte[100]; + byte[] puffarray = new byte[100]; int emptyslots = 0; for (int i = 0; i < 100; i++) { diff --git a/SAV/SAV_SecretBase.cs b/SAV/SAV_SecretBase.cs index 59e3cc4a0..83ea0d253 100644 --- a/SAV/SAV_SecretBase.cs +++ b/SAV/SAV_SecretBase.cs @@ -35,8 +35,8 @@ namespace PKHeX B_SAV2FAV(null, null); } Form1 m_parent; - public byte[] sav = new Byte[0x100000]; - public byte[] wondercard_data = new Byte[0x108]; + public byte[] sav = new byte[0x100000]; + public byte[] wondercard_data = new byte[0x108]; public bool editing = false; public int savindex; int sv = 0; private int fav_offset = 0x23A00; @@ -371,7 +371,7 @@ namespace PKHeX private void changeObjectIndex(object sender, EventArgs e) { int objindex = (int)(NUD_FObject.Value) - 1; - byte[] objinfo = new Byte[12]; + byte[] objinfo = new byte[12]; for (int i = 0; i < 12; i++) objinfo[i] = objdata[objindex, i]; @@ -422,7 +422,7 @@ namespace PKHeX { if (loading || !GB_PKM.Enabled) return; int index = currentpkm; - byte[] pkm = new Byte[0x34]; + byte[] pkm = new byte[0x34]; Array.Copy(BitConverter.GetBytes(Util.getHEXval(TB_EC)), 0, pkm, 0, 4); // EC Array.Copy(BitConverter.GetBytes(Util.getIndex(CB_Species)), 0, pkm, 8, 2); @@ -472,7 +472,7 @@ namespace PKHeX private void loadFavPKM() { int index = currentpkm - 1; - byte[] fpkm = new Byte[0x34]; + byte[] fpkm = new byte[0x34]; for (int i = 0; i < 0x34; i++) fpkm[i] = pkmdata[index, i]; diff --git a/SAV/SAV_SuperTrain.cs b/SAV/SAV_SuperTrain.cs index ff07dec4a..30425f65d 100644 --- a/SAV/SAV_SuperTrain.cs +++ b/SAV/SAV_SuperTrain.cs @@ -32,7 +32,7 @@ namespace PKHeX setup(); } Form1 m_parent; - public byte[] sav = new Byte[0x100000]; + public byte[] sav = new byte[0x100000]; public string[] specieslist; public int savindex; private int data_offset = 0x24600; @@ -142,7 +142,7 @@ namespace PKHeX private void B_Save_Click(object sender, EventArgs e) { // Copy Bags - byte[] bagarray = new Byte[12]; + byte[] bagarray = new byte[12]; int emptyslots = 0; for (int i = 0; i < 12; i++) { diff --git a/SAV/SAV_Trainer.cs b/SAV/SAV_Trainer.cs index 106cec6c9..28d6245d4 100644 --- a/SAV/SAV_Trainer.cs +++ b/SAV/SAV_Trainer.cs @@ -200,7 +200,7 @@ namespace PKHeX } private string[] statdata = new string[] { }; Form1 m_parent; - public byte[] sav = new Byte[0x100000]; + public byte[] sav = new byte[0x100000]; public int savshift; public int savindex; public bool editing = false; diff --git a/SAV/SAV_Wondercard.cs b/SAV/SAV_Wondercard.cs index efe7eb264..45739c16c 100644 --- a/SAV/SAV_Wondercard.cs +++ b/SAV/SAV_Wondercard.cs @@ -31,8 +31,8 @@ namespace PKHeX this.DragDrop += new DragEventHandler(tabMain_DragDrop); } Form1 m_parent; - public byte[] sav = new Byte[0x100000]; - public byte[] wondercard_data = new Byte[0x108]; + public byte[] sav = new byte[0x100000]; + public byte[] wondercard_data = new byte[0x108]; public int savindex; public bool editing = false; private int wcoffset = 0x21100; @@ -104,7 +104,7 @@ namespace PKHeX catch { Util.Error("Loading of data failed... is this really a Wondercard?"); - Array.Copy(new Byte[0x108], wondercard_data, 0x108); + Array.Copy(new byte[0x108], wondercard_data, 0x108); RTB.Clear(); return; } @@ -188,7 +188,7 @@ namespace PKHeX { int index = LB_WCs.SelectedIndex; int offset = wcoffset + savindex * 0x7F000 + index * 0x108; - byte[] zeros = new Byte[0x108]; + byte[] zeros = new byte[0x108]; Array.Copy(zeros, 0, sav, offset, 0x108); populateWClist(); } diff --git a/SAV/frmReport.cs b/SAV/frmReport.cs index f34f271b4..55a29d6ef 100644 --- a/SAV/frmReport.cs +++ b/SAV/frmReport.cs @@ -32,7 +32,7 @@ namespace PKHeX for (int SlotNum = 0; SlotNum < 30; SlotNum++) { int offset = boxoffset + 0xE8 * SlotNum; - byte[] slotdata = new Byte[0xE8]; + byte[] slotdata = new byte[0xE8]; Array.Copy(SaveData, offset, slotdata, 0, 0xE8); byte[] dslotdata = PKX.decryptArray(slotdata); PKX pkm = new PKX(dslotdata);