diff --git a/pk3DS/Game/GameConfig.cs b/pk3DS/Game/GameConfig.cs index 7e73f58..5718510 100644 --- a/pk3DS/Game/GameConfig.cs +++ b/pk3DS/Game/GameConfig.cs @@ -89,6 +89,18 @@ private void getGameData(GameVersion game) public bool SM => Version == GameVersion.SM || Version == GameVersion.SMDEMO; public int MaxSpeciesID => XY || ORAS ? 722 : 802; public int GARCVersion => XY || ORAS ? CTR.GARC.VER_4 : CTR.GARC.VER_6; + public int Generation + { + get + { + if (XY || ORAS) + return 6; + if (SM) + return 7; + return -1; + } + } + public bool IsRebuildable(int fileCount) { switch (fileCount) diff --git a/pk3DS/Main.cs b/pk3DS/Main.cs index 52d0574..0ff60e8 100644 --- a/pk3DS/Main.cs +++ b/pk3DS/Main.cs @@ -236,7 +236,7 @@ private void openQuick(string path) Tab_ExeFS.Enabled = RomFSPath != null && ExeFSPath != null; if (RomFSPath != null) { - B_MoveTutor.Visible = Config.ORAS; // Default false unless loaded + toggleSubEditors(); string newtext = $"Game Loaded: {Config.Version}"; if (L_Game.Text != newtext && Directory.Exists("personal")) { Directory.Delete("personal", true); } // Force reloading of personal data if the game is switched. @@ -274,6 +274,17 @@ private void openQuick(string path) } } + private void toggleSubEditors() + { + switch (Config.Generation) + { + case 6: + B_MoveTutor.Visible = Config.ORAS; // Default false unless loaded + break; + case 7: + break; + } + } private void updateGameInfo() { // 0 - JP @@ -471,7 +482,15 @@ private void B_Personal_Click(object sender, EventArgs e) { string[] files = { "personal" }; fileGet(files, false, true); - Invoke((Action)(() => new PersonalEditor6().ShowDialog())); + switch (Config.Generation) + { + case 6: + Invoke((Action)(() => new PersonalEditor6().ShowDialog())); + break; + case 7: + Invoke((Action)(() => new PersonalEditor7().ShowDialog())); + break; + } // Refresh Personal Stats SpeciesStat = new PersonalTable(File.ReadAllBytes(Directory.GetFiles("personal").Last()), Config.Version).Table; @@ -680,7 +699,16 @@ private void B_Pickup_Click(object sender, EventArgs e) private void B_TMHM_Click(object sender, EventArgs e) { if (threadActive()) return; - if (ExeFSPath != null) new TMHMEditor6().Show(); + if (ExeFSPath != null) + switch (Config.Generation) + { + case 6: + new TMHMEditor6().Show(); + break; + case 7: + new TMEditor7().Show(); + break; + } } private void B_Mart_Click(object sender, EventArgs e) { diff --git a/pk3DS/Structures/PersonalInfo/PersonalInfo.cs b/pk3DS/Structures/PersonalInfo/PersonalInfo.cs index 3c3cd4e..1a77115 100644 --- a/pk3DS/Structures/PersonalInfo/PersonalInfo.cs +++ b/pk3DS/Structures/PersonalInfo/PersonalInfo.cs @@ -32,7 +32,7 @@ public abstract class PersonalInfo public abstract int [] Abilities { get; set; } public abstract int EscapeRate { get; set; } public virtual int FormeCount { get; set; } - protected virtual int FormStatsIndex { get; set; } + protected internal virtual int FormStatsIndex { get; set; } public virtual int FormeSprite { get; set; } public abstract int BaseEXP { get; set; } public abstract int Color { get; set; } diff --git a/pk3DS/Structures/PersonalInfo/PersonalInfoXY.cs b/pk3DS/Structures/PersonalInfo/PersonalInfoXY.cs index 535b2b8..07e32e4 100644 --- a/pk3DS/Structures/PersonalInfo/PersonalInfoXY.cs +++ b/pk3DS/Structures/PersonalInfo/PersonalInfoXY.cs @@ -87,7 +87,7 @@ public override int[] Abilities } } public override int EscapeRate { get { return Data[0x1B]; } set { Data[0x1B] = (byte)value; } } - protected override int FormStatsIndex { get { return BitConverter.ToUInt16(Data, 0x1C); } set { BitConverter.GetBytes((ushort)value).CopyTo(Data, 0x1C); } } + protected internal override int FormStatsIndex { get { return BitConverter.ToUInt16(Data, 0x1C); } set { BitConverter.GetBytes((ushort)value).CopyTo(Data, 0x1C); } } public override int FormeSprite { get { return BitConverter.ToUInt16(Data, 0x1E); } set { BitConverter.GetBytes((ushort)value).CopyTo(Data, 0x1E); } } public override int FormeCount { get { return Data[0x20]; } set { Data[0x20] = (byte)value; } } public override int Color { get { return Data[0x21]; } set { Data[0x21] = (byte)value; } } diff --git a/pk3DS/Structures/PersonalInfo/PersonalTable.cs b/pk3DS/Structures/PersonalInfo/PersonalTable.cs index 752559e..a68d361 100644 --- a/pk3DS/Structures/PersonalInfo/PersonalTable.cs +++ b/pk3DS/Structures/PersonalInfo/PersonalTable.cs @@ -85,5 +85,44 @@ public PersonalInfo getFormeEntry(int species, int forme) { return this[getFormeIndex(species, forme)]; } + + public string[][] getFormList(string[] species, int MaxSpecies) + { + string[][] FormList = new string[MaxSpecies + 1][]; + for (int i = 0; i <= MaxSpecies; i++) + { + int FormCount = this[i].FormeCount; + FormList[i] = new string[FormCount]; + if (FormCount <= 0) continue; + FormList[i][0] = species[i]; + for (int j = 1; j < FormCount; j++) + { + FormList[i][j] = $"{species[i]} " + j; + } + } + + return FormList; + } + public string[] getPersonalEntryList(string[][] AltForms, string[] species, int MaxSpecies, out int[] baseForm, out int[] formVal) + { + string[] result = new string[Table.Length]; + baseForm = new int[result.Length]; + formVal = new int[result.Length]; + for (int i = 0; i <= MaxSpecies; i++) + { + result[i] = species[i]; + if (AltForms[i].Length == 0) continue; + int altformpointer = this[i].FormStatsIndex; + if (altformpointer <= 0) continue; + for (int j = 1; j < AltForms[i].Length; j++) + { + int ptr = altformpointer + j - 1; + baseForm[ptr] = i; + formVal[ptr] = j; + result[ptr] = AltForms[i][j]; + } + } + return result; + } } } diff --git a/pk3DS/Subforms/Gen6/TMHMEditor6.cs b/pk3DS/Subforms/Gen6/TMHMEditor6.cs index 35d1c48..0d05a70 100644 --- a/pk3DS/Subforms/Gen6/TMHMEditor6.cs +++ b/pk3DS/Subforms/Gen6/TMHMEditor6.cs @@ -16,13 +16,14 @@ public TMHMEditor6() if (!File.Exists(files[0]) || !Path.GetFileNameWithoutExtension(files[0]).Contains("code")) { Util.Alert("No .code.bin detected."); Close(); } data = File.ReadAllBytes(files[0]); if (data.Length % 0x200 != 0) { Util.Alert(".code.bin not decompressed. Aborting."); Close(); } - offset = Util.IndexOfBytes(data, new byte[] { 0xD4, 0x00, 0xAE, 0x02, 0xAF, 0x02, 0xB0, 0x02 }, 0x400000, 0) + 8; + offset = Util.IndexOfBytes(data, Signature, 0x400000, 0) + 8; codebin = files[0]; movelist[0] = ""; setupDGV(); getList(); } + private static readonly byte[] Signature = {0xD4, 0x00, 0xAE, 0x02, 0xAF, 0x02, 0xB0, 0x02}; private readonly string codebin; private readonly string[] movelist = Main.getText(TextName.MoveNames); private readonly int offset = Main.Config.ORAS ? 0x004A67EE : 0x00464796; // Default @@ -176,7 +177,7 @@ internal static void getTMHMList(bool oras, ref ushort[] TMs, ref ushort[] HMs) string[] files = Directory.GetFiles(Main.ExeFSPath); if (!File.Exists(files[0]) || !Path.GetFileNameWithoutExtension(files[0]).Contains("code")) return; byte[] data = File.ReadAllBytes(files[0]); - int dataoffset = Util.IndexOfBytes(data, new byte[] { 0xD4, 0x00, 0xAE, 0x02, 0xAF, 0x02, 0xB0, 0x02 }, 0x400000, 0) + 8; + int dataoffset = Util.IndexOfBytes(data, Signature, 0x400000, 0) + 8; if (data.Length % 0x200 != 0) return; List tms = new List(); diff --git a/pk3DS/Subforms/Gen7/PersonalEditor7.Designer.cs b/pk3DS/Subforms/Gen7/PersonalEditor7.Designer.cs new file mode 100644 index 0000000..15e6afd --- /dev/null +++ b/pk3DS/Subforms/Gen7/PersonalEditor7.Designer.cs @@ -0,0 +1,1537 @@ +namespace pk3DS +{ + partial class PersonalEditor7 + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.CB_Species = new System.Windows.Forms.ComboBox(); + this.L_Species_Precursor = new System.Windows.Forms.Label(); + this.TC_Pokemon = new System.Windows.Forms.TabControl(); + this.TP_General = new System.Windows.Forms.TabPage(); + this.TB_RawColor = new System.Windows.Forms.TextBox(); + this.TB_CatchRate = new System.Windows.Forms.MaskedTextBox(); + this.TB_Stage = new System.Windows.Forms.TextBox(); + this.L_Stage = new System.Windows.Forms.Label(); + this.L_WeightKG = new System.Windows.Forms.Label(); + this.L_HeightM = new System.Windows.Forms.Label(); + this.TB_FormeCount = new System.Windows.Forms.TextBox(); + this.L_FormesCount = new System.Windows.Forms.Label(); + this.TB_FormeSprite = new System.Windows.Forms.TextBox(); + this.L_FormeSprite = new System.Windows.Forms.Label(); + this.L_CatchRate = new System.Windows.Forms.Label(); + this.CB_Color = new System.Windows.Forms.ComboBox(); + this.CB_EXPGroup = new System.Windows.Forms.ComboBox(); + this.L_Color = new System.Windows.Forms.Label(); + this.L_EXPGrowth = new System.Windows.Forms.Label(); + this.TB_Weight = new System.Windows.Forms.MaskedTextBox(); + this.TB_Height = new System.Windows.Forms.MaskedTextBox(); + this.L_Weight = new System.Windows.Forms.Label(); + this.L_Height = new System.Windows.Forms.Label(); + this.CB_Ability3 = new System.Windows.Forms.ComboBox(); + this.CB_Ability2 = new System.Windows.Forms.ComboBox(); + this.CB_Ability1 = new System.Windows.Forms.ComboBox(); + this.CB_EggGroup2 = new System.Windows.Forms.ComboBox(); + this.CB_EggGroup1 = new System.Windows.Forms.ComboBox(); + this.L_EggGroup = new System.Windows.Forms.Label(); + this.L_Ability = new System.Windows.Forms.Label(); + this.TB_BaseExp = new System.Windows.Forms.MaskedTextBox(); + this.L_BaseEXP = new System.Windows.Forms.Label(); + this.TB_HatchCycles = new System.Windows.Forms.MaskedTextBox(); + this.L_HatchCycles = new System.Windows.Forms.Label(); + this.TB_Friendship = new System.Windows.Forms.MaskedTextBox(); + this.TB_Gender = new System.Windows.Forms.MaskedTextBox(); + this.L_Friendship = new System.Windows.Forms.Label(); + this.L_Gender = new System.Windows.Forms.Label(); + this.L_Item1 = new System.Windows.Forms.Label(); + this.L_Item5 = new System.Windows.Forms.Label(); + this.L_Item50 = new System.Windows.Forms.Label(); + this.CB_HeldItem3 = new System.Windows.Forms.ComboBox(); + this.CB_HeldItem2 = new System.Windows.Forms.ComboBox(); + this.CB_HeldItem1 = new System.Windows.Forms.ComboBox(); + this.L_HeldItem = new System.Windows.Forms.Label(); + this.CB_Type2 = new System.Windows.Forms.ComboBox(); + this.CB_Type1 = new System.Windows.Forms.ComboBox(); + this.L_Type = new System.Windows.Forms.Label(); + this.TB_SPEEVs = new System.Windows.Forms.MaskedTextBox(); + this.TB_SPDEVs = new System.Windows.Forms.MaskedTextBox(); + this.TB_SPAEVs = new System.Windows.Forms.MaskedTextBox(); + this.TB_DEFEVs = new System.Windows.Forms.MaskedTextBox(); + this.TB_ATKEVs = new System.Windows.Forms.MaskedTextBox(); + this.TB_HPEVs = new System.Windows.Forms.MaskedTextBox(); + this.TB_BaseSPE = new System.Windows.Forms.MaskedTextBox(); + this.TB_BaseSPD = new System.Windows.Forms.MaskedTextBox(); + this.TB_BaseSPA = new System.Windows.Forms.MaskedTextBox(); + this.TB_BaseDEF = new System.Windows.Forms.MaskedTextBox(); + this.TB_BaseATK = new System.Windows.Forms.MaskedTextBox(); + this.TB_BaseHP = new System.Windows.Forms.MaskedTextBox(); + this.Label_HP = new System.Windows.Forms.Label(); + this.Label_ATK = new System.Windows.Forms.Label(); + this.Label_DEF = new System.Windows.Forms.Label(); + this.Label_SPA = new System.Windows.Forms.Label(); + this.Label_SPD = new System.Windows.Forms.Label(); + this.Label_SPE = new System.Windows.Forms.Label(); + this.L_EVYield = new System.Windows.Forms.Label(); + this.L_BaseStats = new System.Windows.Forms.Label(); + this.TP_MoveTutors = new System.Windows.Forms.TabPage(); + this.L_Special = new System.Windows.Forms.Label(); + this.L_TMHM = new System.Windows.Forms.Label(); + this.CLB_MoveTutors = new System.Windows.Forms.CheckedListBox(); + this.CLB_TMHM = new System.Windows.Forms.CheckedListBox(); + this.TP_Randomizer = new System.Windows.Forms.TabPage(); + this.GB_Modifier = new System.Windows.Forms.GroupBox(); + this.CHK_EXP = new System.Windows.Forms.CheckBox(); + this.CHK_Growth = new System.Windows.Forms.CheckBox(); + this.CHK_QuickHatch = new System.Windows.Forms.CheckBox(); + this.L_FinalXP = new System.Windows.Forms.Label(); + this.NUD_EXP = new System.Windows.Forms.NumericUpDown(); + this.CHK_LowCatch = new System.Windows.Forms.CheckBox(); + this.CHK_NoEV = new System.Windows.Forms.CheckBox(); + this.B_ModAll = new System.Windows.Forms.Button(); + this.GB_Randomizer = new System.Windows.Forms.GroupBox(); + this.L_Same = new System.Windows.Forms.Label(); + this.NUD_Egg = new System.Windows.Forms.NumericUpDown(); + this.CHK_WGuard = new System.Windows.Forms.CheckBox(); + this.CHK_Ability = new System.Windows.Forms.CheckBox(); + this.CHK_ORASTutors = new System.Windows.Forms.CheckBox(); + this.CHK_Tutors = new System.Windows.Forms.CheckBox(); + this.CHK_rSPE = new System.Windows.Forms.CheckBox(); + this.CHK_Type = new System.Windows.Forms.CheckBox(); + this.CHK_rSPD = new System.Windows.Forms.CheckBox(); + this.CHK_rSPA = new System.Windows.Forms.CheckBox(); + this.L_SingleType = new System.Windows.Forms.Label(); + this.CHK_rDEF = new System.Windows.Forms.CheckBox(); + this.CHK_rATK = new System.Windows.Forms.CheckBox(); + this.NUD_TypePercent = new System.Windows.Forms.NumericUpDown(); + this.CHK_rHP = new System.Windows.Forms.CheckBox(); + this.CHK_HM = new System.Windows.Forms.CheckBox(); + this.L_StatDev = new System.Windows.Forms.Label(); + this.CHK_TM = new System.Windows.Forms.CheckBox(); + this.NUD_StatDev = new System.Windows.Forms.NumericUpDown(); + this.CHK_Stats = new System.Windows.Forms.CheckBox(); + this.CHK_EggGroup = new System.Windows.Forms.CheckBox(); + this.CHK_CatchRate = new System.Windows.Forms.CheckBox(); + this.CHK_Item = new System.Windows.Forms.CheckBox(); + this.B_Randomize = new System.Windows.Forms.Button(); + this.PB_MonSprite = new System.Windows.Forms.PictureBox(); + this.B_Dump = new System.Windows.Forms.Button(); + this.TC_Pokemon.SuspendLayout(); + this.TP_General.SuspendLayout(); + this.TP_MoveTutors.SuspendLayout(); + this.TP_Randomizer.SuspendLayout(); + this.GB_Modifier.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_EXP)).BeginInit(); + this.GB_Randomizer.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_Egg)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_TypePercent)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_StatDev)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.PB_MonSprite)).BeginInit(); + this.SuspendLayout(); + // + // CB_Species + // + this.CB_Species.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest; + this.CB_Species.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; + this.CB_Species.FormattingEnabled = true; + this.CB_Species.Location = new System.Drawing.Point(107, 12); + this.CB_Species.Name = "CB_Species"; + this.CB_Species.Size = new System.Drawing.Size(160, 21); + this.CB_Species.TabIndex = 2; + this.CB_Species.SelectedIndexChanged += new System.EventHandler(this.CB_Species_SelectedIndexChanged); + // + // L_Species_Precursor + // + this.L_Species_Precursor.AutoSize = true; + this.L_Species_Precursor.Location = new System.Drawing.Point(13, 15); + this.L_Species_Precursor.Name = "L_Species_Precursor"; + this.L_Species_Precursor.Size = new System.Drawing.Size(88, 13); + this.L_Species_Precursor.TabIndex = 3; + this.L_Species_Precursor.Text = "Current Species: "; + // + // TC_Pokemon + // + this.TC_Pokemon.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + | System.Windows.Forms.AnchorStyles.Left))); + this.TC_Pokemon.Controls.Add(this.TP_General); + this.TC_Pokemon.Controls.Add(this.TP_MoveTutors); + this.TC_Pokemon.Controls.Add(this.TP_Randomizer); + this.TC_Pokemon.Location = new System.Drawing.Point(12, 40); + this.TC_Pokemon.Name = "TC_Pokemon"; + this.TC_Pokemon.SelectedIndex = 0; + this.TC_Pokemon.Size = new System.Drawing.Size(445, 365); + this.TC_Pokemon.TabIndex = 416; + // + // TP_General + // + this.TP_General.Controls.Add(this.TB_RawColor); + this.TP_General.Controls.Add(this.TB_CatchRate); + this.TP_General.Controls.Add(this.TB_Stage); + this.TP_General.Controls.Add(this.L_Stage); + this.TP_General.Controls.Add(this.L_WeightKG); + this.TP_General.Controls.Add(this.L_HeightM); + this.TP_General.Controls.Add(this.TB_FormeCount); + this.TP_General.Controls.Add(this.L_FormesCount); + this.TP_General.Controls.Add(this.TB_FormeSprite); + this.TP_General.Controls.Add(this.L_FormeSprite); + this.TP_General.Controls.Add(this.L_CatchRate); + this.TP_General.Controls.Add(this.CB_Color); + this.TP_General.Controls.Add(this.CB_EXPGroup); + this.TP_General.Controls.Add(this.L_Color); + this.TP_General.Controls.Add(this.L_EXPGrowth); + this.TP_General.Controls.Add(this.TB_Weight); + this.TP_General.Controls.Add(this.TB_Height); + this.TP_General.Controls.Add(this.L_Weight); + this.TP_General.Controls.Add(this.L_Height); + this.TP_General.Controls.Add(this.CB_Ability3); + this.TP_General.Controls.Add(this.CB_Ability2); + this.TP_General.Controls.Add(this.CB_Ability1); + this.TP_General.Controls.Add(this.CB_EggGroup2); + this.TP_General.Controls.Add(this.CB_EggGroup1); + this.TP_General.Controls.Add(this.L_EggGroup); + this.TP_General.Controls.Add(this.L_Ability); + this.TP_General.Controls.Add(this.TB_BaseExp); + this.TP_General.Controls.Add(this.L_BaseEXP); + this.TP_General.Controls.Add(this.TB_HatchCycles); + this.TP_General.Controls.Add(this.L_HatchCycles); + this.TP_General.Controls.Add(this.TB_Friendship); + this.TP_General.Controls.Add(this.TB_Gender); + this.TP_General.Controls.Add(this.L_Friendship); + this.TP_General.Controls.Add(this.L_Gender); + this.TP_General.Controls.Add(this.L_Item1); + this.TP_General.Controls.Add(this.L_Item5); + this.TP_General.Controls.Add(this.L_Item50); + this.TP_General.Controls.Add(this.CB_HeldItem3); + this.TP_General.Controls.Add(this.CB_HeldItem2); + this.TP_General.Controls.Add(this.CB_HeldItem1); + this.TP_General.Controls.Add(this.L_HeldItem); + this.TP_General.Controls.Add(this.CB_Type2); + this.TP_General.Controls.Add(this.CB_Type1); + this.TP_General.Controls.Add(this.L_Type); + this.TP_General.Controls.Add(this.TB_SPEEVs); + this.TP_General.Controls.Add(this.TB_SPDEVs); + this.TP_General.Controls.Add(this.TB_SPAEVs); + this.TP_General.Controls.Add(this.TB_DEFEVs); + this.TP_General.Controls.Add(this.TB_ATKEVs); + this.TP_General.Controls.Add(this.TB_HPEVs); + this.TP_General.Controls.Add(this.TB_BaseSPE); + this.TP_General.Controls.Add(this.TB_BaseSPD); + this.TP_General.Controls.Add(this.TB_BaseSPA); + this.TP_General.Controls.Add(this.TB_BaseDEF); + this.TP_General.Controls.Add(this.TB_BaseATK); + this.TP_General.Controls.Add(this.TB_BaseHP); + this.TP_General.Controls.Add(this.Label_HP); + this.TP_General.Controls.Add(this.Label_ATK); + this.TP_General.Controls.Add(this.Label_DEF); + this.TP_General.Controls.Add(this.Label_SPA); + this.TP_General.Controls.Add(this.Label_SPD); + this.TP_General.Controls.Add(this.Label_SPE); + this.TP_General.Controls.Add(this.L_EVYield); + this.TP_General.Controls.Add(this.L_BaseStats); + this.TP_General.Location = new System.Drawing.Point(4, 22); + this.TP_General.Name = "TP_General"; + this.TP_General.Padding = new System.Windows.Forms.Padding(3); + this.TP_General.Size = new System.Drawing.Size(437, 339); + this.TP_General.TabIndex = 0; + this.TP_General.Text = "General Info"; + this.TP_General.UseVisualStyleBackColor = true; + // + // TB_RawColor + // + this.TB_RawColor.Location = new System.Drawing.Point(236, 211); + this.TB_RawColor.Name = "TB_RawColor"; + this.TB_RawColor.ReadOnly = true; + this.TB_RawColor.Size = new System.Drawing.Size(30, 20); + this.TB_RawColor.TabIndex = 88; + this.TB_RawColor.Visible = false; + // + // TB_CatchRate + // + this.TB_CatchRate.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_CatchRate.Location = new System.Drawing.Point(387, 49); + this.TB_CatchRate.Mask = "000"; + this.TB_CatchRate.Name = "TB_CatchRate"; + this.TB_CatchRate.Size = new System.Drawing.Size(31, 20); + this.TB_CatchRate.TabIndex = 87; + this.TB_CatchRate.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_CatchRate.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // TB_Stage + // + this.TB_Stage.Location = new System.Drawing.Point(376, 248); + this.TB_Stage.Name = "TB_Stage"; + this.TB_Stage.ReadOnly = true; + this.TB_Stage.Size = new System.Drawing.Size(30, 20); + this.TB_Stage.TabIndex = 86; + // + // L_Stage + // + this.L_Stage.AutoSize = true; + this.L_Stage.Location = new System.Drawing.Point(290, 251); + this.L_Stage.Name = "L_Stage"; + this.L_Stage.Size = new System.Drawing.Size(85, 13); + this.L_Stage.TabIndex = 85; + this.L_Stage.Text = "Evolution Stage:"; + this.L_Stage.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // L_WeightKG + // + this.L_WeightKG.AutoSize = true; + this.L_WeightKG.Location = new System.Drawing.Point(269, 300); + this.L_WeightKG.Name = "L_WeightKG"; + this.L_WeightKG.Size = new System.Drawing.Size(19, 13); + this.L_WeightKG.TabIndex = 84; + this.L_WeightKG.Text = "kg"; + // + // L_HeightM + // + this.L_HeightM.AutoSize = true; + this.L_HeightM.Location = new System.Drawing.Point(128, 300); + this.L_HeightM.Name = "L_HeightM"; + this.L_HeightM.Size = new System.Drawing.Size(15, 13); + this.L_HeightM.TabIndex = 83; + this.L_HeightM.Text = "m"; + // + // TB_FormeCount + // + this.TB_FormeCount.Location = new System.Drawing.Point(376, 296); + this.TB_FormeCount.Name = "TB_FormeCount"; + this.TB_FormeCount.ReadOnly = true; + this.TB_FormeCount.Size = new System.Drawing.Size(30, 20); + this.TB_FormeCount.TabIndex = 82; + // + // L_FormesCount + // + this.L_FormesCount.AutoSize = true; + this.L_FormesCount.Location = new System.Drawing.Point(300, 300); + this.L_FormesCount.Name = "L_FormesCount"; + this.L_FormesCount.Size = new System.Drawing.Size(75, 13); + this.L_FormesCount.TabIndex = 81; + this.L_FormesCount.Text = "Formes Count:"; + this.L_FormesCount.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // TB_FormeSprite + // + this.TB_FormeSprite.Location = new System.Drawing.Point(376, 272); + this.TB_FormeSprite.Name = "TB_FormeSprite"; + this.TB_FormeSprite.ReadOnly = true; + this.TB_FormeSprite.Size = new System.Drawing.Size(30, 20); + this.TB_FormeSprite.TabIndex = 80; + // + // L_FormeSprite + // + this.L_FormeSprite.AutoSize = true; + this.L_FormeSprite.Location = new System.Drawing.Point(306, 276); + this.L_FormeSprite.Name = "L_FormeSprite"; + this.L_FormeSprite.Size = new System.Drawing.Size(69, 13); + this.L_FormeSprite.TabIndex = 79; + this.L_FormeSprite.Text = "Forme Sprite:"; + this.L_FormeSprite.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // L_CatchRate + // + this.L_CatchRate.AutoSize = true; + this.L_CatchRate.Location = new System.Drawing.Point(322, 52); + this.L_CatchRate.Name = "L_CatchRate"; + this.L_CatchRate.Size = new System.Drawing.Size(64, 13); + this.L_CatchRate.TabIndex = 77; + this.L_CatchRate.Text = "Catch Rate:"; + // + // CB_Color + // + this.CB_Color.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest; + this.CB_Color.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; + this.CB_Color.FormattingEnabled = true; + this.CB_Color.Location = new System.Drawing.Point(311, 211); + this.CB_Color.Name = "CB_Color"; + this.CB_Color.Size = new System.Drawing.Size(105, 21); + this.CB_Color.TabIndex = 76; + // + // CB_EXPGroup + // + this.CB_EXPGroup.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest; + this.CB_EXPGroup.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; + this.CB_EXPGroup.FormattingEnabled = true; + this.CB_EXPGroup.Location = new System.Drawing.Point(91, 210); + this.CB_EXPGroup.Name = "CB_EXPGroup"; + this.CB_EXPGroup.Size = new System.Drawing.Size(101, 21); + this.CB_EXPGroup.TabIndex = 75; + // + // L_Color + // + this.L_Color.AutoSize = true; + this.L_Color.Location = new System.Drawing.Point(276, 214); + this.L_Color.Name = "L_Color"; + this.L_Color.Size = new System.Drawing.Size(34, 13); + this.L_Color.TabIndex = 74; + this.L_Color.Text = "Color:"; + // + // L_EXPGrowth + // + this.L_EXPGrowth.AutoSize = true; + this.L_EXPGrowth.Location = new System.Drawing.Point(27, 214); + this.L_EXPGrowth.Name = "L_EXPGrowth"; + this.L_EXPGrowth.Size = new System.Drawing.Size(63, 13); + this.L_EXPGrowth.TabIndex = 73; + this.L_EXPGrowth.Text = "EXP Group:"; + // + // TB_Weight + // + this.TB_Weight.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_Weight.Location = new System.Drawing.Point(235, 296); + this.TB_Weight.Mask = "000.0"; + this.TB_Weight.Name = "TB_Weight"; + this.TB_Weight.Size = new System.Drawing.Size(31, 20); + this.TB_Weight.TabIndex = 72; + this.TB_Weight.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + // + // TB_Height + // + this.TB_Height.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_Height.Location = new System.Drawing.Point(94, 296); + this.TB_Height.Mask = "00.0"; + this.TB_Height.Name = "TB_Height"; + this.TB_Height.Size = new System.Drawing.Size(31, 20); + this.TB_Height.TabIndex = 71; + this.TB_Height.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + // + // L_Weight + // + this.L_Weight.AutoSize = true; + this.L_Weight.Location = new System.Drawing.Point(190, 300); + this.L_Weight.Name = "L_Weight"; + this.L_Weight.Size = new System.Drawing.Size(44, 13); + this.L_Weight.TabIndex = 70; + this.L_Weight.Text = "Weight:"; + this.L_Weight.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // L_Height + // + this.L_Height.AutoSize = true; + this.L_Height.Location = new System.Drawing.Point(52, 300); + this.L_Height.Name = "L_Height"; + this.L_Height.Size = new System.Drawing.Size(41, 13); + this.L_Height.TabIndex = 69; + this.L_Height.Text = "Height:"; + this.L_Height.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // CB_Ability3 + // + this.CB_Ability3.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest; + this.CB_Ability3.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; + this.CB_Ability3.FormattingEnabled = true; + this.CB_Ability3.Location = new System.Drawing.Point(276, 131); + this.CB_Ability3.Name = "CB_Ability3"; + this.CB_Ability3.Size = new System.Drawing.Size(140, 21); + this.CB_Ability3.TabIndex = 68; + // + // CB_Ability2 + // + this.CB_Ability2.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest; + this.CB_Ability2.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; + this.CB_Ability2.FormattingEnabled = true; + this.CB_Ability2.Location = new System.Drawing.Point(276, 105); + this.CB_Ability2.Name = "CB_Ability2"; + this.CB_Ability2.Size = new System.Drawing.Size(140, 21); + this.CB_Ability2.TabIndex = 67; + // + // CB_Ability1 + // + this.CB_Ability1.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest; + this.CB_Ability1.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; + this.CB_Ability1.FormattingEnabled = true; + this.CB_Ability1.Location = new System.Drawing.Point(276, 79); + this.CB_Ability1.Name = "CB_Ability1"; + this.CB_Ability1.Size = new System.Drawing.Size(140, 21); + this.CB_Ability1.TabIndex = 66; + // + // CB_EggGroup2 + // + this.CB_EggGroup2.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest; + this.CB_EggGroup2.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; + this.CB_EggGroup2.FormattingEnabled = true; + this.CB_EggGroup2.Location = new System.Drawing.Point(295, 184); + this.CB_EggGroup2.Name = "CB_EggGroup2"; + this.CB_EggGroup2.Size = new System.Drawing.Size(121, 21); + this.CB_EggGroup2.TabIndex = 65; + // + // CB_EggGroup1 + // + this.CB_EggGroup1.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest; + this.CB_EggGroup1.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; + this.CB_EggGroup1.FormattingEnabled = true; + this.CB_EggGroup1.Location = new System.Drawing.Point(295, 158); + this.CB_EggGroup1.Name = "CB_EggGroup1"; + this.CB_EggGroup1.Size = new System.Drawing.Size(121, 21); + this.CB_EggGroup1.TabIndex = 64; + // + // L_EggGroup + // + this.L_EggGroup.AutoSize = true; + this.L_EggGroup.Location = new System.Drawing.Point(228, 161); + this.L_EggGroup.Name = "L_EggGroup"; + this.L_EggGroup.Size = new System.Drawing.Size(66, 13); + this.L_EggGroup.TabIndex = 63; + this.L_EggGroup.Text = "Egg Groups:"; + // + // L_Ability + // + this.L_Ability.AutoSize = true; + this.L_Ability.Location = new System.Drawing.Point(230, 83); + this.L_Ability.Name = "L_Ability"; + this.L_Ability.Size = new System.Drawing.Size(45, 13); + this.L_Ability.TabIndex = 62; + this.L_Ability.Text = "Abilities:"; + // + // TB_BaseExp + // + this.TB_BaseExp.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_BaseExp.Location = new System.Drawing.Point(235, 272); + this.TB_BaseExp.Mask = "000"; + this.TB_BaseExp.Name = "TB_BaseExp"; + this.TB_BaseExp.Size = new System.Drawing.Size(31, 20); + this.TB_BaseExp.TabIndex = 61; + this.TB_BaseExp.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_BaseExp.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // L_BaseEXP + // + this.L_BaseEXP.AutoSize = true; + this.L_BaseEXP.Location = new System.Drawing.Point(176, 276); + this.L_BaseEXP.Name = "L_BaseEXP"; + this.L_BaseEXP.Size = new System.Drawing.Size(58, 13); + this.L_BaseEXP.TabIndex = 60; + this.L_BaseEXP.Text = "Base EXP:"; + this.L_BaseEXP.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // TB_HatchCycles + // + this.TB_HatchCycles.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_HatchCycles.Location = new System.Drawing.Point(235, 248); + this.TB_HatchCycles.Mask = "000"; + this.TB_HatchCycles.Name = "TB_HatchCycles"; + this.TB_HatchCycles.Size = new System.Drawing.Size(31, 20); + this.TB_HatchCycles.TabIndex = 58; + this.TB_HatchCycles.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_HatchCycles.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // L_HatchCycles + // + this.L_HatchCycles.AutoSize = true; + this.L_HatchCycles.Location = new System.Drawing.Point(161, 251); + this.L_HatchCycles.Name = "L_HatchCycles"; + this.L_HatchCycles.Size = new System.Drawing.Size(73, 13); + this.L_HatchCycles.TabIndex = 57; + this.L_HatchCycles.Text = "Hatch Cycles:"; + this.L_HatchCycles.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // TB_Friendship + // + this.TB_Friendship.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_Friendship.Location = new System.Drawing.Point(94, 272); + this.TB_Friendship.Mask = "000"; + this.TB_Friendship.Name = "TB_Friendship"; + this.TB_Friendship.Size = new System.Drawing.Size(31, 20); + this.TB_Friendship.TabIndex = 56; + this.TB_Friendship.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_Friendship.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // TB_Gender + // + this.TB_Gender.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_Gender.Location = new System.Drawing.Point(94, 248); + this.TB_Gender.Mask = "000"; + this.TB_Gender.Name = "TB_Gender"; + this.TB_Gender.Size = new System.Drawing.Size(31, 20); + this.TB_Gender.TabIndex = 55; + this.TB_Gender.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_Gender.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // L_Friendship + // + this.L_Friendship.AutoSize = true; + this.L_Friendship.Location = new System.Drawing.Point(35, 276); + this.L_Friendship.Name = "L_Friendship"; + this.L_Friendship.Size = new System.Drawing.Size(58, 13); + this.L_Friendship.TabIndex = 54; + this.L_Friendship.Text = "Friendship:"; + this.L_Friendship.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // L_Gender + // + this.L_Gender.AutoSize = true; + this.L_Gender.Location = new System.Drawing.Point(48, 251); + this.L_Gender.Name = "L_Gender"; + this.L_Gender.Size = new System.Drawing.Size(45, 13); + this.L_Gender.TabIndex = 53; + this.L_Gender.Text = "Gender:"; + this.L_Gender.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // L_Item1 + // + this.L_Item1.AutoSize = true; + this.L_Item1.Location = new System.Drawing.Point(195, 134); + this.L_Item1.Name = "L_Item1"; + this.L_Item1.Size = new System.Drawing.Size(21, 13); + this.L_Item1.TabIndex = 52; + this.L_Item1.Text = "1%"; + // + // L_Item5 + // + this.L_Item5.AutoSize = true; + this.L_Item5.Location = new System.Drawing.Point(195, 107); + this.L_Item5.Name = "L_Item5"; + this.L_Item5.Size = new System.Drawing.Size(21, 13); + this.L_Item5.TabIndex = 51; + this.L_Item5.Text = "5%"; + // + // L_Item50 + // + this.L_Item50.AutoSize = true; + this.L_Item50.Location = new System.Drawing.Point(195, 83); + this.L_Item50.Name = "L_Item50"; + this.L_Item50.Size = new System.Drawing.Size(27, 13); + this.L_Item50.TabIndex = 50; + this.L_Item50.Text = "50%"; + // + // CB_HeldItem3 + // + this.CB_HeldItem3.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest; + this.CB_HeldItem3.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; + this.CB_HeldItem3.FormattingEnabled = true; + this.CB_HeldItem3.Location = new System.Drawing.Point(52, 131); + this.CB_HeldItem3.Name = "CB_HeldItem3"; + this.CB_HeldItem3.Size = new System.Drawing.Size(140, 21); + this.CB_HeldItem3.TabIndex = 49; + // + // CB_HeldItem2 + // + this.CB_HeldItem2.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest; + this.CB_HeldItem2.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; + this.CB_HeldItem2.FormattingEnabled = true; + this.CB_HeldItem2.Location = new System.Drawing.Point(52, 105); + this.CB_HeldItem2.Name = "CB_HeldItem2"; + this.CB_HeldItem2.Size = new System.Drawing.Size(140, 21); + this.CB_HeldItem2.TabIndex = 48; + // + // CB_HeldItem1 + // + this.CB_HeldItem1.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest; + this.CB_HeldItem1.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; + this.CB_HeldItem1.FormattingEnabled = true; + this.CB_HeldItem1.Location = new System.Drawing.Point(52, 79); + this.CB_HeldItem1.Name = "CB_HeldItem1"; + this.CB_HeldItem1.Size = new System.Drawing.Size(140, 21); + this.CB_HeldItem1.TabIndex = 47; + // + // L_HeldItem + // + this.L_HeldItem.AutoSize = true; + this.L_HeldItem.Location = new System.Drawing.Point(16, 82); + this.L_HeldItem.Name = "L_HeldItem"; + this.L_HeldItem.Size = new System.Drawing.Size(35, 13); + this.L_HeldItem.TabIndex = 46; + this.L_HeldItem.Text = "Items:"; + // + // CB_Type2 + // + this.CB_Type2.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest; + this.CB_Type2.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; + this.CB_Type2.FormattingEnabled = true; + this.CB_Type2.Location = new System.Drawing.Point(71, 184); + this.CB_Type2.Name = "CB_Type2"; + this.CB_Type2.Size = new System.Drawing.Size(121, 21); + this.CB_Type2.TabIndex = 45; + // + // CB_Type1 + // + this.CB_Type1.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest; + this.CB_Type1.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; + this.CB_Type1.FormattingEnabled = true; + this.CB_Type1.Location = new System.Drawing.Point(71, 158); + this.CB_Type1.Name = "CB_Type1"; + this.CB_Type1.Size = new System.Drawing.Size(121, 21); + this.CB_Type1.TabIndex = 44; + // + // L_Type + // + this.L_Type.AutoSize = true; + this.L_Type.Location = new System.Drawing.Point(23, 161); + this.L_Type.Name = "L_Type"; + this.L_Type.Size = new System.Drawing.Size(47, 13); + this.L_Type.TabIndex = 43; + this.L_Type.Text = "Typings:"; + // + // TB_SPEEVs + // + this.TB_SPEEVs.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_SPEEVs.Location = new System.Drawing.Point(273, 51); + this.TB_SPEEVs.Mask = "0"; + this.TB_SPEEVs.Name = "TB_SPEEVs"; + this.TB_SPEEVs.Size = new System.Drawing.Size(31, 20); + this.TB_SPEEVs.TabIndex = 42; + this.TB_SPEEVs.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_SPEEVs.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // TB_SPDEVs + // + this.TB_SPDEVs.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_SPDEVs.Location = new System.Drawing.Point(234, 51); + this.TB_SPDEVs.Mask = "0"; + this.TB_SPDEVs.Name = "TB_SPDEVs"; + this.TB_SPDEVs.Size = new System.Drawing.Size(31, 20); + this.TB_SPDEVs.TabIndex = 41; + this.TB_SPDEVs.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_SPDEVs.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // TB_SPAEVs + // + this.TB_SPAEVs.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_SPAEVs.Location = new System.Drawing.Point(195, 51); + this.TB_SPAEVs.Mask = "0"; + this.TB_SPAEVs.Name = "TB_SPAEVs"; + this.TB_SPAEVs.Size = new System.Drawing.Size(31, 20); + this.TB_SPAEVs.TabIndex = 40; + this.TB_SPAEVs.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_SPAEVs.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // TB_DEFEVs + // + this.TB_DEFEVs.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_DEFEVs.Location = new System.Drawing.Point(157, 51); + this.TB_DEFEVs.Mask = "0"; + this.TB_DEFEVs.Name = "TB_DEFEVs"; + this.TB_DEFEVs.Size = new System.Drawing.Size(31, 20); + this.TB_DEFEVs.TabIndex = 39; + this.TB_DEFEVs.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_DEFEVs.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // TB_ATKEVs + // + this.TB_ATKEVs.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_ATKEVs.Location = new System.Drawing.Point(119, 51); + this.TB_ATKEVs.Mask = "0"; + this.TB_ATKEVs.Name = "TB_ATKEVs"; + this.TB_ATKEVs.Size = new System.Drawing.Size(31, 20); + this.TB_ATKEVs.TabIndex = 38; + this.TB_ATKEVs.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_ATKEVs.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // TB_HPEVs + // + this.TB_HPEVs.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_HPEVs.Location = new System.Drawing.Point(80, 51); + this.TB_HPEVs.Mask = "0"; + this.TB_HPEVs.Name = "TB_HPEVs"; + this.TB_HPEVs.Size = new System.Drawing.Size(31, 20); + this.TB_HPEVs.TabIndex = 37; + this.TB_HPEVs.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_HPEVs.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // TB_BaseSPE + // + this.TB_BaseSPE.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_BaseSPE.Location = new System.Drawing.Point(273, 27); + this.TB_BaseSPE.Mask = "000"; + this.TB_BaseSPE.Name = "TB_BaseSPE"; + this.TB_BaseSPE.Size = new System.Drawing.Size(31, 20); + this.TB_BaseSPE.TabIndex = 36; + this.TB_BaseSPE.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_BaseSPE.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // TB_BaseSPD + // + this.TB_BaseSPD.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_BaseSPD.Location = new System.Drawing.Point(234, 27); + this.TB_BaseSPD.Mask = "000"; + this.TB_BaseSPD.Name = "TB_BaseSPD"; + this.TB_BaseSPD.Size = new System.Drawing.Size(31, 20); + this.TB_BaseSPD.TabIndex = 35; + this.TB_BaseSPD.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_BaseSPD.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // TB_BaseSPA + // + this.TB_BaseSPA.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_BaseSPA.Location = new System.Drawing.Point(195, 27); + this.TB_BaseSPA.Mask = "000"; + this.TB_BaseSPA.Name = "TB_BaseSPA"; + this.TB_BaseSPA.Size = new System.Drawing.Size(31, 20); + this.TB_BaseSPA.TabIndex = 34; + this.TB_BaseSPA.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_BaseSPA.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // TB_BaseDEF + // + this.TB_BaseDEF.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_BaseDEF.Location = new System.Drawing.Point(157, 27); + this.TB_BaseDEF.Mask = "000"; + this.TB_BaseDEF.Name = "TB_BaseDEF"; + this.TB_BaseDEF.Size = new System.Drawing.Size(31, 20); + this.TB_BaseDEF.TabIndex = 33; + this.TB_BaseDEF.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_BaseDEF.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // TB_BaseATK + // + this.TB_BaseATK.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_BaseATK.Location = new System.Drawing.Point(119, 27); + this.TB_BaseATK.Mask = "000"; + this.TB_BaseATK.Name = "TB_BaseATK"; + this.TB_BaseATK.Size = new System.Drawing.Size(31, 20); + this.TB_BaseATK.TabIndex = 32; + this.TB_BaseATK.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_BaseATK.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // TB_BaseHP + // + this.TB_BaseHP.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.TB_BaseHP.Location = new System.Drawing.Point(80, 27); + this.TB_BaseHP.Mask = "000"; + this.TB_BaseHP.Name = "TB_BaseHP"; + this.TB_BaseHP.Size = new System.Drawing.Size(31, 20); + this.TB_BaseHP.TabIndex = 31; + this.TB_BaseHP.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.TB_BaseHP.TextChanged += new System.EventHandler(this.ByteLimiter); + // + // Label_HP + // + this.Label_HP.Location = new System.Drawing.Point(77, 11); + this.Label_HP.Name = "Label_HP"; + this.Label_HP.Size = new System.Drawing.Size(31, 13); + this.Label_HP.TabIndex = 25; + this.Label_HP.Text = "HP:"; + this.Label_HP.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // Label_ATK + // + this.Label_ATK.Location = new System.Drawing.Point(119, 11); + this.Label_ATK.Name = "Label_ATK"; + this.Label_ATK.Size = new System.Drawing.Size(31, 13); + this.Label_ATK.TabIndex = 26; + this.Label_ATK.Text = "Atk:"; + this.Label_ATK.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // Label_DEF + // + this.Label_DEF.Location = new System.Drawing.Point(157, 11); + this.Label_DEF.Name = "Label_DEF"; + this.Label_DEF.Size = new System.Drawing.Size(31, 13); + this.Label_DEF.TabIndex = 27; + this.Label_DEF.Text = "Def:"; + this.Label_DEF.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // Label_SPA + // + this.Label_SPA.Location = new System.Drawing.Point(195, 11); + this.Label_SPA.Name = "Label_SPA"; + this.Label_SPA.Size = new System.Drawing.Size(31, 13); + this.Label_SPA.TabIndex = 28; + this.Label_SPA.Text = "SpA:"; + this.Label_SPA.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // Label_SPD + // + this.Label_SPD.Location = new System.Drawing.Point(234, 11); + this.Label_SPD.Name = "Label_SPD"; + this.Label_SPD.Size = new System.Drawing.Size(31, 13); + this.Label_SPD.TabIndex = 29; + this.Label_SPD.Text = "SpD:"; + this.Label_SPD.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // Label_SPE + // + this.Label_SPE.Location = new System.Drawing.Point(271, 11); + this.Label_SPE.Name = "Label_SPE"; + this.Label_SPE.Size = new System.Drawing.Size(31, 13); + this.Label_SPE.TabIndex = 30; + this.Label_SPE.Text = "Spe:"; + this.Label_SPE.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // L_EVYield + // + this.L_EVYield.AutoSize = true; + this.L_EVYield.Location = new System.Drawing.Point(29, 54); + this.L_EVYield.Name = "L_EVYield"; + this.L_EVYield.Size = new System.Drawing.Size(50, 13); + this.L_EVYield.TabIndex = 2; + this.L_EVYield.Text = "EV Yield:"; + // + // L_BaseStats + // + this.L_BaseStats.AutoSize = true; + this.L_BaseStats.Location = new System.Drawing.Point(18, 30); + this.L_BaseStats.Name = "L_BaseStats"; + this.L_BaseStats.Size = new System.Drawing.Size(61, 13); + this.L_BaseStats.TabIndex = 1; + this.L_BaseStats.Text = "Base Stats:"; + // + // TP_MoveTutors + // + this.TP_MoveTutors.Controls.Add(this.L_Special); + this.TP_MoveTutors.Controls.Add(this.L_TMHM); + this.TP_MoveTutors.Controls.Add(this.CLB_MoveTutors); + this.TP_MoveTutors.Controls.Add(this.CLB_TMHM); + this.TP_MoveTutors.Location = new System.Drawing.Point(4, 22); + this.TP_MoveTutors.Name = "TP_MoveTutors"; + this.TP_MoveTutors.Padding = new System.Windows.Forms.Padding(3); + this.TP_MoveTutors.Size = new System.Drawing.Size(437, 339); + this.TP_MoveTutors.TabIndex = 1; + this.TP_MoveTutors.Text = "Move Tutors"; + this.TP_MoveTutors.UseVisualStyleBackColor = true; + // + // L_Special + // + this.L_Special.AutoSize = true; + this.L_Special.Location = new System.Drawing.Point(159, 3); + this.L_Special.Name = "L_Special"; + this.L_Special.Size = new System.Drawing.Size(78, 13); + this.L_Special.TabIndex = 6; + this.L_Special.Text = "Special Tutors:"; + // + // L_TMHM + // + this.L_TMHM.AutoSize = true; + this.L_TMHM.Location = new System.Drawing.Point(6, 3); + this.L_TMHM.Name = "L_TMHM"; + this.L_TMHM.Size = new System.Drawing.Size(26, 13); + this.L_TMHM.TabIndex = 5; + this.L_TMHM.Text = "TM:"; + // + // CLB_MoveTutors + // + this.CLB_MoveTutors.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + | System.Windows.Forms.AnchorStyles.Left))); + this.CLB_MoveTutors.FormattingEnabled = true; + this.CLB_MoveTutors.Location = new System.Drawing.Point(162, 19); + this.CLB_MoveTutors.Name = "CLB_MoveTutors"; + this.CLB_MoveTutors.Size = new System.Drawing.Size(133, 319); + this.CLB_MoveTutors.TabIndex = 3; + // + // CLB_TMHM + // + this.CLB_TMHM.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + | System.Windows.Forms.AnchorStyles.Left))); + this.CLB_TMHM.FormattingEnabled = true; + this.CLB_TMHM.Location = new System.Drawing.Point(9, 19); + this.CLB_TMHM.Name = "CLB_TMHM"; + this.CLB_TMHM.Size = new System.Drawing.Size(147, 319); + this.CLB_TMHM.TabIndex = 2; + // + // TP_Randomizer + // + this.TP_Randomizer.Controls.Add(this.GB_Modifier); + this.TP_Randomizer.Controls.Add(this.B_ModAll); + this.TP_Randomizer.Controls.Add(this.GB_Randomizer); + this.TP_Randomizer.Controls.Add(this.B_Randomize); + this.TP_Randomizer.Location = new System.Drawing.Point(4, 22); + this.TP_Randomizer.Name = "TP_Randomizer"; + this.TP_Randomizer.Size = new System.Drawing.Size(437, 339); + this.TP_Randomizer.TabIndex = 2; + this.TP_Randomizer.Text = "Enhancements"; + this.TP_Randomizer.UseVisualStyleBackColor = true; + // + // GB_Modifier + // + this.GB_Modifier.Controls.Add(this.CHK_EXP); + this.GB_Modifier.Controls.Add(this.CHK_Growth); + this.GB_Modifier.Controls.Add(this.CHK_QuickHatch); + this.GB_Modifier.Controls.Add(this.L_FinalXP); + this.GB_Modifier.Controls.Add(this.NUD_EXP); + this.GB_Modifier.Controls.Add(this.CHK_LowCatch); + this.GB_Modifier.Controls.Add(this.CHK_NoEV); + this.GB_Modifier.Location = new System.Drawing.Point(4, 147); + this.GB_Modifier.Name = "GB_Modifier"; + this.GB_Modifier.Size = new System.Drawing.Size(345, 129); + this.GB_Modifier.TabIndex = 419; + this.GB_Modifier.TabStop = false; + this.GB_Modifier.Text = "Modifier Options"; + // + // CHK_EXP + // + this.CHK_EXP.AutoSize = true; + this.CHK_EXP.Location = new System.Drawing.Point(6, 66); + this.CHK_EXP.Name = "CHK_EXP"; + this.CHK_EXP.Size = new System.Drawing.Size(107, 17); + this.CHK_EXP.TabIndex = 7; + this.CHK_EXP.Text = "Modify EXP Yield"; + this.CHK_EXP.UseVisualStyleBackColor = true; + // + // CHK_Growth + // + this.CHK_Growth.AutoSize = true; + this.CHK_Growth.Location = new System.Drawing.Point(6, 51); + this.CHK_Growth.Name = "CHK_Growth"; + this.CHK_Growth.Size = new System.Drawing.Size(147, 17); + this.CHK_Growth.TabIndex = 8; + this.CHK_Growth.Text = "Lowest EXP Growth Rate"; + this.CHK_Growth.UseVisualStyleBackColor = true; + // + // CHK_QuickHatch + // + this.CHK_QuickHatch.AutoSize = true; + this.CHK_QuickHatch.Checked = true; + this.CHK_QuickHatch.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_QuickHatch.Location = new System.Drawing.Point(204, 21); + this.CHK_QuickHatch.Name = "CHK_QuickHatch"; + this.CHK_QuickHatch.Size = new System.Drawing.Size(113, 17); + this.CHK_QuickHatch.TabIndex = 10; + this.CHK_QuickHatch.Text = "Quick Hatch Eggs"; + this.CHK_QuickHatch.UseVisualStyleBackColor = true; + // + // L_FinalXP + // + this.L_FinalXP.AutoSize = true; + this.L_FinalXP.Location = new System.Drawing.Point(6, 86); + this.L_FinalXP.Name = "L_FinalXP"; + this.L_FinalXP.Size = new System.Drawing.Size(57, 13); + this.L_FinalXP.TabIndex = 6; + this.L_FinalXP.Text = "FinalXP(%)"; + // + // NUD_EXP + // + this.NUD_EXP.Location = new System.Drawing.Point(69, 84); + this.NUD_EXP.Maximum = new decimal(new int[] { + 300, + 0, + 0, + 0}); + this.NUD_EXP.Name = "NUD_EXP"; + this.NUD_EXP.Size = new System.Drawing.Size(46, 20); + this.NUD_EXP.TabIndex = 5; + this.NUD_EXP.Value = new decimal(new int[] { + 28, + 0, + 0, + 0}); + // + // CHK_LowCatch + // + this.CHK_LowCatch.AutoSize = true; + this.CHK_LowCatch.Location = new System.Drawing.Point(6, 36); + this.CHK_LowCatch.Name = "CHK_LowCatch"; + this.CHK_LowCatch.Size = new System.Drawing.Size(117, 17); + this.CHK_LowCatch.TabIndex = 9; + this.CHK_LowCatch.Text = "Lowest Catch Rate"; + this.CHK_LowCatch.UseVisualStyleBackColor = true; + // + // CHK_NoEV + // + this.CHK_NoEV.AutoSize = true; + this.CHK_NoEV.Location = new System.Drawing.Point(6, 21); + this.CHK_NoEV.Name = "CHK_NoEV"; + this.CHK_NoEV.Size = new System.Drawing.Size(114, 17); + this.CHK_NoEV.TabIndex = 0; + this.CHK_NoEV.Text = "Remove EV Yields"; + this.CHK_NoEV.UseVisualStyleBackColor = true; + // + // B_ModAll + // + this.B_ModAll.Location = new System.Drawing.Point(352, 162); + this.B_ModAll.Name = "B_ModAll"; + this.B_ModAll.Size = new System.Drawing.Size(82, 23); + this.B_ModAll.TabIndex = 421; + this.B_ModAll.Text = "Modify All"; + this.B_ModAll.UseVisualStyleBackColor = true; + this.B_ModAll.Click += new System.EventHandler(this.B_ModifyAll); + // + // GB_Randomizer + // + this.GB_Randomizer.Controls.Add(this.L_Same); + this.GB_Randomizer.Controls.Add(this.NUD_Egg); + this.GB_Randomizer.Controls.Add(this.CHK_WGuard); + this.GB_Randomizer.Controls.Add(this.CHK_Ability); + this.GB_Randomizer.Controls.Add(this.CHK_ORASTutors); + this.GB_Randomizer.Controls.Add(this.CHK_Tutors); + this.GB_Randomizer.Controls.Add(this.CHK_rSPE); + this.GB_Randomizer.Controls.Add(this.CHK_Type); + this.GB_Randomizer.Controls.Add(this.CHK_rSPD); + this.GB_Randomizer.Controls.Add(this.CHK_rSPA); + this.GB_Randomizer.Controls.Add(this.L_SingleType); + this.GB_Randomizer.Controls.Add(this.CHK_rDEF); + this.GB_Randomizer.Controls.Add(this.CHK_rATK); + this.GB_Randomizer.Controls.Add(this.NUD_TypePercent); + this.GB_Randomizer.Controls.Add(this.CHK_rHP); + this.GB_Randomizer.Controls.Add(this.CHK_HM); + this.GB_Randomizer.Controls.Add(this.L_StatDev); + this.GB_Randomizer.Controls.Add(this.CHK_TM); + this.GB_Randomizer.Controls.Add(this.NUD_StatDev); + this.GB_Randomizer.Controls.Add(this.CHK_Stats); + this.GB_Randomizer.Controls.Add(this.CHK_EggGroup); + this.GB_Randomizer.Controls.Add(this.CHK_CatchRate); + this.GB_Randomizer.Controls.Add(this.CHK_Item); + this.GB_Randomizer.Location = new System.Drawing.Point(4, 12); + this.GB_Randomizer.Name = "GB_Randomizer"; + this.GB_Randomizer.Size = new System.Drawing.Size(345, 129); + this.GB_Randomizer.TabIndex = 418; + this.GB_Randomizer.TabStop = false; + this.GB_Randomizer.Text = "Randomizer Options"; + // + // L_Same + // + this.L_Same.AutoSize = true; + this.L_Same.Location = new System.Drawing.Point(201, 100); + this.L_Same.Name = "L_Same"; + this.L_Same.Size = new System.Drawing.Size(48, 13); + this.L_Same.TabIndex = 23; + this.L_Same.Text = "Same(%)"; + // + // NUD_Egg + // + this.NUD_Egg.Location = new System.Drawing.Point(252, 98); + this.NUD_Egg.Name = "NUD_Egg"; + this.NUD_Egg.Size = new System.Drawing.Size(46, 20); + this.NUD_Egg.TabIndex = 22; + this.NUD_Egg.Value = new decimal(new int[] { + 50, + 0, + 0, + 0}); + // + // CHK_WGuard + // + this.CHK_WGuard.AutoSize = true; + this.CHK_WGuard.Location = new System.Drawing.Point(118, 49); + this.CHK_WGuard.Name = "CHK_WGuard"; + this.CHK_WGuard.Size = new System.Drawing.Size(72, 17); + this.CHK_WGuard.TabIndex = 10; + this.CHK_WGuard.Text = "W. Guard"; + this.CHK_WGuard.UseVisualStyleBackColor = true; + // + // CHK_Ability + // + this.CHK_Ability.AutoSize = true; + this.CHK_Ability.Checked = true; + this.CHK_Ability.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_Ability.Location = new System.Drawing.Point(118, 34); + this.CHK_Ability.Name = "CHK_Ability"; + this.CHK_Ability.Size = new System.Drawing.Size(61, 17); + this.CHK_Ability.TabIndex = 1; + this.CHK_Ability.Text = "Abilities"; + this.CHK_Ability.UseVisualStyleBackColor = true; + this.CHK_Ability.CheckedChanged += new System.EventHandler(this.CHK_Ability_CheckedChanged); + // + // CHK_ORASTutors + // + this.CHK_ORASTutors.AutoSize = true; + this.CHK_ORASTutors.Checked = true; + this.CHK_ORASTutors.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_ORASTutors.Location = new System.Drawing.Point(204, 49); + this.CHK_ORASTutors.Name = "CHK_ORASTutors"; + this.CHK_ORASTutors.Size = new System.Drawing.Size(79, 17); + this.CHK_ORASTutors.TabIndex = 9; + this.CHK_ORASTutors.Text = "R/S Tutors"; + this.CHK_ORASTutors.UseVisualStyleBackColor = true; + // + // CHK_Tutors + // + this.CHK_Tutors.AutoSize = true; + this.CHK_Tutors.Checked = true; + this.CHK_Tutors.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_Tutors.Location = new System.Drawing.Point(204, 34); + this.CHK_Tutors.Name = "CHK_Tutors"; + this.CHK_Tutors.Size = new System.Drawing.Size(94, 17); + this.CHK_Tutors.TabIndex = 8; + this.CHK_Tutors.Text = "Special Tutors"; + this.CHK_Tutors.UseVisualStyleBackColor = true; + // + // CHK_rSPE + // + this.CHK_rSPE.AutoSize = true; + this.CHK_rSPE.Checked = true; + this.CHK_rSPE.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_rSPE.Location = new System.Drawing.Point(45, 65); + this.CHK_rSPE.Name = "CHK_rSPE"; + this.CHK_rSPE.Size = new System.Drawing.Size(45, 17); + this.CHK_rSPE.TabIndex = 19; + this.CHK_rSPE.Text = "Spe"; + this.CHK_rSPE.UseVisualStyleBackColor = true; + // + // CHK_Type + // + this.CHK_Type.AutoSize = true; + this.CHK_Type.Checked = true; + this.CHK_Type.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_Type.Location = new System.Drawing.Point(118, 65); + this.CHK_Type.Name = "CHK_Type"; + this.CHK_Type.Size = new System.Drawing.Size(55, 17); + this.CHK_Type.TabIndex = 6; + this.CHK_Type.Text = "Types"; + this.CHK_Type.UseVisualStyleBackColor = true; + // + // CHK_rSPD + // + this.CHK_rSPD.AutoSize = true; + this.CHK_rSPD.Checked = true; + this.CHK_rSPD.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_rSPD.Location = new System.Drawing.Point(6, 65); + this.CHK_rSPD.Name = "CHK_rSPD"; + this.CHK_rSPD.Size = new System.Drawing.Size(45, 17); + this.CHK_rSPD.TabIndex = 18; + this.CHK_rSPD.Text = "Spd"; + this.CHK_rSPD.UseVisualStyleBackColor = true; + // + // CHK_rSPA + // + this.CHK_rSPA.AutoSize = true; + this.CHK_rSPA.Checked = true; + this.CHK_rSPA.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_rSPA.Location = new System.Drawing.Point(45, 49); + this.CHK_rSPA.Name = "CHK_rSPA"; + this.CHK_rSPA.Size = new System.Drawing.Size(45, 17); + this.CHK_rSPA.TabIndex = 17; + this.CHK_rSPA.Text = "Spa"; + this.CHK_rSPA.UseVisualStyleBackColor = true; + // + // L_SingleType + // + this.L_SingleType.AutoSize = true; + this.L_SingleType.Location = new System.Drawing.Point(115, 82); + this.L_SingleType.Name = "L_SingleType"; + this.L_SingleType.Size = new System.Drawing.Size(74, 13); + this.L_SingleType.TabIndex = 21; + this.L_SingleType.Text = "SingleType(%)"; + // + // CHK_rDEF + // + this.CHK_rDEF.AutoSize = true; + this.CHK_rDEF.Checked = true; + this.CHK_rDEF.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_rDEF.Location = new System.Drawing.Point(6, 49); + this.CHK_rDEF.Name = "CHK_rDEF"; + this.CHK_rDEF.Size = new System.Drawing.Size(43, 17); + this.CHK_rDEF.TabIndex = 16; + this.CHK_rDEF.Text = "Def"; + this.CHK_rDEF.UseVisualStyleBackColor = true; + // + // CHK_rATK + // + this.CHK_rATK.AutoSize = true; + this.CHK_rATK.Checked = true; + this.CHK_rATK.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_rATK.Location = new System.Drawing.Point(45, 34); + this.CHK_rATK.Name = "CHK_rATK"; + this.CHK_rATK.Size = new System.Drawing.Size(42, 17); + this.CHK_rATK.TabIndex = 15; + this.CHK_rATK.Text = "Atk"; + this.CHK_rATK.UseVisualStyleBackColor = true; + // + // NUD_TypePercent + // + this.NUD_TypePercent.Location = new System.Drawing.Point(134, 98); + this.NUD_TypePercent.Name = "NUD_TypePercent"; + this.NUD_TypePercent.Size = new System.Drawing.Size(46, 20); + this.NUD_TypePercent.TabIndex = 20; + this.NUD_TypePercent.Value = new decimal(new int[] { + 50, + 0, + 0, + 0}); + // + // CHK_rHP + // + this.CHK_rHP.AutoSize = true; + this.CHK_rHP.Checked = true; + this.CHK_rHP.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_rHP.Location = new System.Drawing.Point(6, 34); + this.CHK_rHP.Name = "CHK_rHP"; + this.CHK_rHP.Size = new System.Drawing.Size(41, 17); + this.CHK_rHP.TabIndex = 14; + this.CHK_rHP.Text = "HP"; + this.CHK_rHP.UseVisualStyleBackColor = true; + // + // CHK_HM + // + this.CHK_HM.AutoSize = true; + this.CHK_HM.Checked = true; + this.CHK_HM.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_HM.Location = new System.Drawing.Point(252, 19); + this.CHK_HM.Name = "CHK_HM"; + this.CHK_HM.Size = new System.Drawing.Size(43, 17); + this.CHK_HM.TabIndex = 7; + this.CHK_HM.Text = "HM"; + this.CHK_HM.UseVisualStyleBackColor = true; + // + // L_StatDev + // + this.L_StatDev.AutoSize = true; + this.L_StatDev.Location = new System.Drawing.Point(6, 82); + this.L_StatDev.Name = "L_StatDev"; + this.L_StatDev.Size = new System.Drawing.Size(67, 13); + this.L_StatDev.TabIndex = 4; + this.L_StatDev.Text = "Deviance(%)"; + // + // CHK_TM + // + this.CHK_TM.AutoSize = true; + this.CHK_TM.Checked = true; + this.CHK_TM.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_TM.Location = new System.Drawing.Point(204, 19); + this.CHK_TM.Name = "CHK_TM"; + this.CHK_TM.Size = new System.Drawing.Size(42, 17); + this.CHK_TM.TabIndex = 0; + this.CHK_TM.Text = "TM"; + this.CHK_TM.UseVisualStyleBackColor = true; + // + // NUD_StatDev + // + this.NUD_StatDev.Location = new System.Drawing.Point(27, 98); + this.NUD_StatDev.Name = "NUD_StatDev"; + this.NUD_StatDev.Size = new System.Drawing.Size(46, 20); + this.NUD_StatDev.TabIndex = 3; + this.NUD_StatDev.Value = new decimal(new int[] { + 25, + 0, + 0, + 0}); + // + // CHK_Stats + // + this.CHK_Stats.AutoSize = true; + this.CHK_Stats.Checked = true; + this.CHK_Stats.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_Stats.Location = new System.Drawing.Point(6, 19); + this.CHK_Stats.Name = "CHK_Stats"; + this.CHK_Stats.Size = new System.Drawing.Size(106, 17); + this.CHK_Stats.TabIndex = 2; + this.CHK_Stats.Text = "Randomize Stats"; + this.CHK_Stats.UseVisualStyleBackColor = true; + this.CHK_Stats.CheckedChanged += new System.EventHandler(this.CHK_Stats_CheckedChanged); + // + // CHK_EggGroup + // + this.CHK_EggGroup.AutoSize = true; + this.CHK_EggGroup.Checked = true; + this.CHK_EggGroup.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_EggGroup.Location = new System.Drawing.Point(203, 80); + this.CHK_EggGroup.Name = "CHK_EggGroup"; + this.CHK_EggGroup.Size = new System.Drawing.Size(77, 17); + this.CHK_EggGroup.TabIndex = 13; + this.CHK_EggGroup.Text = "Egg Group"; + this.CHK_EggGroup.UseVisualStyleBackColor = true; + // + // CHK_CatchRate + // + this.CHK_CatchRate.AutoSize = true; + this.CHK_CatchRate.Checked = true; + this.CHK_CatchRate.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_CatchRate.Location = new System.Drawing.Point(203, 65); + this.CHK_CatchRate.Name = "CHK_CatchRate"; + this.CHK_CatchRate.Size = new System.Drawing.Size(80, 17); + this.CHK_CatchRate.TabIndex = 11; + this.CHK_CatchRate.Text = "Catch Rate"; + this.CHK_CatchRate.UseVisualStyleBackColor = true; + // + // CHK_Item + // + this.CHK_Item.AutoSize = true; + this.CHK_Item.Checked = true; + this.CHK_Item.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_Item.Location = new System.Drawing.Point(118, 19); + this.CHK_Item.Name = "CHK_Item"; + this.CHK_Item.Size = new System.Drawing.Size(76, 17); + this.CHK_Item.TabIndex = 5; + this.CHK_Item.Text = "Held Items"; + this.CHK_Item.UseVisualStyleBackColor = true; + // + // B_Randomize + // + this.B_Randomize.Location = new System.Drawing.Point(352, 25); + this.B_Randomize.Name = "B_Randomize"; + this.B_Randomize.Size = new System.Drawing.Size(82, 23); + this.B_Randomize.TabIndex = 417; + this.B_Randomize.Text = "Randomize"; + this.B_Randomize.UseVisualStyleBackColor = true; + this.B_Randomize.Click += new System.EventHandler(this.B_Randomize_Click); + // + // PB_MonSprite + // + this.PB_MonSprite.Location = new System.Drawing.Point(285, 0); + this.PB_MonSprite.Name = "PB_MonSprite"; + this.PB_MonSprite.Size = new System.Drawing.Size(80, 60); + this.PB_MonSprite.TabIndex = 89; + this.PB_MonSprite.TabStop = false; + // + // B_Dump + // + this.B_Dump.Location = new System.Drawing.Point(368, 10); + this.B_Dump.Name = "B_Dump"; + this.B_Dump.Size = new System.Drawing.Size(82, 23); + this.B_Dump.TabIndex = 418; + this.B_Dump.Text = "Dump All"; + this.B_Dump.UseVisualStyleBackColor = true; + this.B_Dump.Click += new System.EventHandler(this.B_Dump_Click); + // + // PersonalEditor7 + // + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.ClientSize = new System.Drawing.Size(469, 416); + this.Controls.Add(this.B_Dump); + this.Controls.Add(this.PB_MonSprite); + this.Controls.Add(this.TC_Pokemon); + this.Controls.Add(this.L_Species_Precursor); + this.Controls.Add(this.CB_Species); + this.MaximizeBox = false; + this.MaximumSize = new System.Drawing.Size(485, 455); + this.MinimumSize = new System.Drawing.Size(485, 455); + this.Name = "PersonalEditor7"; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; + this.Text = "Personal Stats Editor"; + this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.formClosing); + this.TC_Pokemon.ResumeLayout(false); + this.TP_General.ResumeLayout(false); + this.TP_General.PerformLayout(); + this.TP_MoveTutors.ResumeLayout(false); + this.TP_MoveTutors.PerformLayout(); + this.TP_Randomizer.ResumeLayout(false); + this.GB_Modifier.ResumeLayout(false); + this.GB_Modifier.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_EXP)).EndInit(); + this.GB_Randomizer.ResumeLayout(false); + this.GB_Randomizer.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_Egg)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_TypePercent)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_StatDev)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.PB_MonSprite)).EndInit(); + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + + private System.Windows.Forms.ComboBox CB_Species; + private System.Windows.Forms.Label L_Species_Precursor; + private System.Windows.Forms.TabControl TC_Pokemon; + private System.Windows.Forms.TabPage TP_General; + private System.Windows.Forms.TabPage TP_MoveTutors; + private System.Windows.Forms.MaskedTextBox TB_SPEEVs; + private System.Windows.Forms.MaskedTextBox TB_SPDEVs; + private System.Windows.Forms.MaskedTextBox TB_SPAEVs; + private System.Windows.Forms.MaskedTextBox TB_DEFEVs; + private System.Windows.Forms.MaskedTextBox TB_ATKEVs; + private System.Windows.Forms.MaskedTextBox TB_HPEVs; + private System.Windows.Forms.MaskedTextBox TB_BaseSPE; + private System.Windows.Forms.MaskedTextBox TB_BaseSPD; + private System.Windows.Forms.MaskedTextBox TB_BaseSPA; + private System.Windows.Forms.MaskedTextBox TB_BaseDEF; + private System.Windows.Forms.MaskedTextBox TB_BaseATK; + private System.Windows.Forms.MaskedTextBox TB_BaseHP; + private System.Windows.Forms.Label Label_HP; + private System.Windows.Forms.Label Label_ATK; + private System.Windows.Forms.Label Label_DEF; + private System.Windows.Forms.Label Label_SPA; + private System.Windows.Forms.Label Label_SPD; + private System.Windows.Forms.Label Label_SPE; + private System.Windows.Forms.Label L_EVYield; + private System.Windows.Forms.Label L_BaseStats; + private System.Windows.Forms.ComboBox CB_HeldItem1; + private System.Windows.Forms.Label L_HeldItem; + private System.Windows.Forms.ComboBox CB_Type2; + private System.Windows.Forms.ComboBox CB_Type1; + private System.Windows.Forms.Label L_Type; + private System.Windows.Forms.Label L_Item1; + private System.Windows.Forms.Label L_Item5; + private System.Windows.Forms.Label L_Item50; + private System.Windows.Forms.ComboBox CB_HeldItem3; + private System.Windows.Forms.ComboBox CB_HeldItem2; + private System.Windows.Forms.MaskedTextBox TB_Weight; + private System.Windows.Forms.MaskedTextBox TB_Height; + private System.Windows.Forms.Label L_Weight; + private System.Windows.Forms.Label L_Height; + private System.Windows.Forms.ComboBox CB_Ability3; + private System.Windows.Forms.ComboBox CB_Ability2; + private System.Windows.Forms.ComboBox CB_Ability1; + private System.Windows.Forms.ComboBox CB_EggGroup2; + private System.Windows.Forms.ComboBox CB_EggGroup1; + private System.Windows.Forms.Label L_EggGroup; + private System.Windows.Forms.Label L_Ability; + private System.Windows.Forms.MaskedTextBox TB_BaseExp; + private System.Windows.Forms.Label L_BaseEXP; + private System.Windows.Forms.MaskedTextBox TB_HatchCycles; + private System.Windows.Forms.Label L_HatchCycles; + private System.Windows.Forms.MaskedTextBox TB_Friendship; + private System.Windows.Forms.MaskedTextBox TB_Gender; + private System.Windows.Forms.Label L_Friendship; + private System.Windows.Forms.Label L_Gender; + private System.Windows.Forms.ComboBox CB_Color; + private System.Windows.Forms.ComboBox CB_EXPGroup; + private System.Windows.Forms.Label L_Color; + private System.Windows.Forms.Label L_EXPGrowth; + private System.Windows.Forms.Label L_CatchRate; + private System.Windows.Forms.Label L_WeightKG; + private System.Windows.Forms.Label L_HeightM; + private System.Windows.Forms.TextBox TB_FormeCount; + private System.Windows.Forms.Label L_FormesCount; + private System.Windows.Forms.TextBox TB_FormeSprite; + private System.Windows.Forms.Label L_FormeSprite; + private System.Windows.Forms.TextBox TB_Stage; + private System.Windows.Forms.Label L_Stage; + private System.Windows.Forms.MaskedTextBox TB_CatchRate; + private System.Windows.Forms.TextBox TB_RawColor; + private System.Windows.Forms.CheckedListBox CLB_TMHM; + private System.Windows.Forms.CheckedListBox CLB_MoveTutors; + private System.Windows.Forms.Label L_Special; + private System.Windows.Forms.Label L_TMHM; + private System.Windows.Forms.PictureBox PB_MonSprite; + private System.Windows.Forms.Button B_Randomize; + private System.Windows.Forms.Button B_Dump; + private System.Windows.Forms.CheckBox CHK_TM; + private System.Windows.Forms.CheckBox CHK_Ability; + private System.Windows.Forms.CheckBox CHK_Stats; + private System.Windows.Forms.NumericUpDown NUD_StatDev; + private System.Windows.Forms.Label L_StatDev; + private System.Windows.Forms.CheckBox CHK_Item; + private System.Windows.Forms.CheckBox CHK_Type; + private System.Windows.Forms.CheckBox CHK_HM; + private System.Windows.Forms.CheckBox CHK_ORASTutors; + private System.Windows.Forms.CheckBox CHK_Tutors; + private System.Windows.Forms.CheckBox CHK_WGuard; + private System.Windows.Forms.CheckBox CHK_CatchRate; + private System.Windows.Forms.CheckBox CHK_rSPE; + private System.Windows.Forms.CheckBox CHK_rSPD; + private System.Windows.Forms.CheckBox CHK_rSPA; + private System.Windows.Forms.CheckBox CHK_rDEF; + private System.Windows.Forms.CheckBox CHK_rATK; + private System.Windows.Forms.CheckBox CHK_rHP; + private System.Windows.Forms.CheckBox CHK_EggGroup; + private System.Windows.Forms.Button B_ModAll; + private System.Windows.Forms.CheckBox CHK_NoEV; + private System.Windows.Forms.TabPage TP_Randomizer; + private System.Windows.Forms.Label L_SingleType; + private System.Windows.Forms.NumericUpDown NUD_TypePercent; + private System.Windows.Forms.GroupBox GB_Randomizer; + private System.Windows.Forms.GroupBox GB_Modifier; + private System.Windows.Forms.CheckBox CHK_EXP; + private System.Windows.Forms.Label L_FinalXP; + private System.Windows.Forms.NumericUpDown NUD_EXP; + private System.Windows.Forms.CheckBox CHK_Growth; + private System.Windows.Forms.CheckBox CHK_LowCatch; + private System.Windows.Forms.CheckBox CHK_QuickHatch; + private System.Windows.Forms.Label L_Same; + private System.Windows.Forms.NumericUpDown NUD_Egg; + } +} diff --git a/pk3DS/Subforms/Gen7/PersonalEditor7.cs b/pk3DS/Subforms/Gen7/PersonalEditor7.cs new file mode 100644 index 0000000..28d1eac --- /dev/null +++ b/pk3DS/Subforms/Gen7/PersonalEditor7.cs @@ -0,0 +1,446 @@ +using System; +using System.Drawing; +using System.IO; +using System.Linq; +using System.Media; +using System.Text; +using System.Windows.Forms; +using pk3DS.Properties; + +namespace pk3DS +{ + public partial class PersonalEditor7 : Form + { + public PersonalEditor7() + { + InitializeComponent(); + helditem_boxes = new[] { CB_HeldItem1, CB_HeldItem2, CB_HeldItem3 }; + ability_boxes = new[] { CB_Ability1, CB_Ability2, CB_Ability3 }; + typing_boxes = new[] { CB_Type1, CB_Type2 }; + eggGroup_boxes = new[] { CB_EggGroup1, CB_EggGroup2 }; + byte_boxes = new[] { TB_BaseHP, TB_BaseATK, TB_BaseDEF, TB_BaseSPA, TB_BaseSPD, TB_BaseSPE, TB_Gender, TB_HatchCycles, TB_Friendship, TB_CatchRate }; + ev_boxes = new[] { TB_HPEVs, TB_ATKEVs, TB_DEFEVs, TB_SPEEVs, TB_SPAEVs, TB_SPDEVs }; + rstat_boxes = new[] { CHK_rHP, CHK_rATK, CHK_rDEF, CHK_rSPA, CHK_rSPD, CHK_rSPE }; + + data = File.ReadAllBytes(paths.Last()); // Load last to data. + Personal = new PersonalTable(data, GameVersion.SM); + species[0] = "---"; + abilities[0] = items[0] = moves[0] = ""; + AltForms = Personal.getFormList(species, Main.Config.MaxSpeciesID); + entryNames = Personal.getPersonalEntryList(AltForms, species, Main.Config.MaxSpeciesID, out baseForms, out formVal); + + Setup(); + CB_Species.SelectedIndex = 1; + } + #region Global Variables + private readonly string[] paths = Directory.GetFiles("personal", "*.*", SearchOption.TopDirectoryOnly); + + private readonly string[] items = Main.getText(TextName.ItemNames); + private readonly string[] moves = Main.getText(TextName.MoveNames); + private readonly string[] species = Main.getText(TextName.SpeciesNames); + private readonly string[] abilities = Main.getText(TextName.AbilityNames); + private readonly string[] forms = Main.getText(TextName.Forms); + private readonly string[] types = Main.getText(TextName.Types); + + private readonly byte[] data; + private readonly string[] entryNames; + + private readonly ComboBox[] helditem_boxes; + private readonly ComboBox[] ability_boxes; + private readonly ComboBox[] typing_boxes; + private readonly ComboBox[] eggGroup_boxes; + + private readonly MaskedTextBox[] byte_boxes; + private readonly MaskedTextBox[] ev_boxes; + private readonly CheckBox[] rstat_boxes; + + private readonly string[] eggGroups = { "---", "Monster", "Water 1", "Bug", "Flying", "Field", "Fairy", "Grass", "Human-Like", "Water 3", "Mineral", "Amorphous", "Water 2", "Ditto", "Dragon", "Undiscovered" }; + private readonly string[] EXPGroups = { "Medium-Fast", "Erratic", "Fluctuating", "Medium-Slow", "Fast", "Slow" }; + private readonly string[] colors = { "Red", "Blue", "Yellow", "Green", "Black", "Brown", "Purple", "Gray", "White", "Pink" }; + private readonly ushort[] tutormoves = { 338, 307, 308, 520, 519, 518, 434, 620 }; + + private readonly PersonalTable Personal; + private string[][] AltForms; + private int[] baseForms, formVal; + int entry = -1; + #endregion + private void Setup() + { + ushort[] TMs = new ushort[0]; + TMEditor7.getTMHMList(ref TMs); + CLB_TMHM.Items.Clear(); + + if (TMs.Length == 0) // No ExeFS to grab TMs from. + { + for (int i = 1; i <= 100; i++) + CLB_TMHM.Items.Add("TM" + i.ToString("00")); + } + else // Use TMHM moves. + { + for (int i = 1; i <= 100; i++) + CLB_TMHM.Items.Add($"TM{i.ToString("00")} {moves[TMs[i - 1]]}"); + } + foreach (ushort m in tutormoves) + CLB_MoveTutors.Items.Add(moves[m]); + + for (int i = 0; i < entryNames.Length; i++) + CB_Species.Items.Add($"{entryNames[i]} - {i.ToString("000")}"); + + foreach (ComboBox cb in helditem_boxes) + foreach (string it in items) + cb.Items.Add(it); + + foreach (ComboBox cb in ability_boxes) + foreach (string ab in abilities) + cb.Items.Add(ab); + + foreach (ComboBox cb in typing_boxes) + foreach (string ty in types) + cb.Items.Add(ty); + + foreach (ComboBox cb in eggGroup_boxes) + foreach (string eg in eggGroups) + cb.Items.Add(eg); + + foreach (string co in colors) + CB_Color.Items.Add(co); + + foreach (string eg in EXPGroups) + CB_EXPGroup.Items.Add(eg); + } + + private void CB_Species_SelectedIndexChanged(object sender, EventArgs e) + { + if (entry > -1 && !dumping) saveEntry(); + entry = CB_Species.SelectedIndex; + readEntry(); + } + private void ByteLimiter(object sender, EventArgs e) + { + MaskedTextBox mtb = sender as MaskedTextBox; + int val; + int.TryParse(mtb.Text, out val); + if (Array.IndexOf(byte_boxes, mtb) > -1 && val > 255) + mtb.Text = "255"; + else if (Array.IndexOf(ev_boxes, mtb) > -1 && val > 3) + mtb.Text = "3"; + } + + private PersonalInfo pkm; + private void readInfo() + { + pkm = Main.SpeciesStat[entry]; + + TB_BaseHP.Text = pkm.HP.ToString("000"); + TB_BaseATK.Text = pkm.ATK.ToString("000"); + TB_BaseDEF.Text = pkm.DEF.ToString("000"); + TB_BaseSPE.Text = pkm.SPE.ToString("000"); + TB_BaseSPA.Text = pkm.SPA.ToString("000"); + TB_BaseSPD.Text = pkm.SPD.ToString("000"); + TB_HPEVs.Text = pkm.EV_HP.ToString("0"); + TB_ATKEVs.Text = pkm.EV_ATK.ToString("0"); + TB_DEFEVs.Text = pkm.EV_DEF.ToString("0"); + TB_SPEEVs.Text = pkm.EV_SPE.ToString("0"); + TB_SPAEVs.Text = pkm.EV_SPA.ToString("0"); + TB_SPDEVs.Text = pkm.EV_SPD.ToString("0"); + + CB_Type1.SelectedIndex = pkm.Types[0]; + CB_Type2.SelectedIndex = pkm.Types[1]; + + TB_CatchRate.Text = pkm.CatchRate.ToString("000"); + TB_Stage.Text = pkm.EvoStage.ToString("0"); + + CB_HeldItem1.SelectedIndex = pkm.Items[0]; + CB_HeldItem2.SelectedIndex = pkm.Items[1]; + CB_HeldItem3.SelectedIndex = pkm.Items[2]; + + TB_Gender.Text = pkm.Gender.ToString("000"); + TB_HatchCycles.Text = pkm.HatchCycles.ToString("000"); + TB_Friendship.Text = pkm.BaseFriendship.ToString("000"); + + CB_EXPGroup.SelectedIndex = pkm.EXPGrowth; + + CB_EggGroup1.SelectedIndex = pkm.EggGroups[0]; + CB_EggGroup2.SelectedIndex = pkm.EggGroups[1]; + + CB_Ability1.SelectedIndex = pkm.Abilities[0]; + CB_Ability2.SelectedIndex = pkm.Abilities[1]; + CB_Ability3.SelectedIndex = pkm.Abilities[2]; + + TB_FormeCount.Text = pkm.FormeCount.ToString("000"); + TB_FormeSprite.Text = pkm.FormeSprite.ToString("000"); + + TB_RawColor.Text = pkm.Color.ToString("000"); + CB_Color.SelectedIndex = pkm.Color & 0xF; + + TB_BaseExp.Text = pkm.BaseEXP.ToString("000"); + + TB_Height.Text = (pkm.Height / 100).ToString("00.0"); + TB_Weight.Text = (pkm.Weight / 10).ToString("000.0"); + + for (int i = 0; i < CLB_TMHM.Items.Count; i++) + CLB_TMHM.SetItemChecked(i, pkm.TMHM[i]); // Bitflags for TMHM + + for (int i = 0; i < CLB_MoveTutors.Items.Count; i++) + CLB_MoveTutors.SetItemChecked(i, pkm.TypeTutors[i]); // Bitflags for Tutors + } + private void readEntry() + { + readInfo(); + + if (dumping) return; + int s = baseForms[entry]; + int f = formVal[entry]; + if (entry <= Main.Config.MaxSpeciesID) + s = entry; + int[] specForm = {s, f}; + string filename = "_" + specForm[0] + (CB_Species.SelectedIndex > Main.Config.MaxSpeciesID ? "_" + (specForm[1] + 1) : ""); + Bitmap rawImg = (Bitmap)Resources.ResourceManager.GetObject(filename) ?? Resources.unknown; + Bitmap bigImg = new Bitmap(rawImg.Width * 2, rawImg.Height * 2); + for (int x = 0; x < rawImg.Width; x++) + { + for (int y = 0; y < rawImg.Height; y++) + { + Color c = rawImg.GetPixel(x, y); + bigImg.SetPixel(2 * x, 2 * y, c); + bigImg.SetPixel(2 * x + 1, 2 * y, c); + bigImg.SetPixel(2 * x, 2 * y + 1, c); + bigImg.SetPixel(2 * x + 1, 2 * y + 1, c); + } + } + PB_MonSprite.Image = bigImg; + } + private void savePersonal() + { + pkm.HP = Convert.ToByte(TB_BaseHP.Text); + pkm.ATK = Convert.ToByte(TB_BaseATK.Text); + pkm.DEF = Convert.ToByte(TB_BaseDEF.Text); + pkm.SPE = Convert.ToByte(TB_BaseSPE.Text); + pkm.SPA = Convert.ToByte(TB_BaseSPA.Text); + pkm.SPD = Convert.ToByte(TB_BaseSPD.Text); + + pkm.EV_HP = Convert.ToByte(TB_HPEVs.Text); + pkm.EV_ATK = Convert.ToByte(TB_ATKEVs.Text); + pkm.EV_DEF = Convert.ToByte(TB_DEFEVs.Text); + pkm.EV_SPE = Convert.ToByte(TB_SPEEVs.Text); + pkm.EV_SPA = Convert.ToByte(TB_SPAEVs.Text); + pkm.EV_SPD = Convert.ToByte(TB_SPDEVs.Text); + + pkm.CatchRate = Convert.ToByte(TB_CatchRate.Text); + pkm.EvoStage = Convert.ToByte(TB_Stage.Text); + + pkm.Types[0] = (byte) CB_Type1.SelectedIndex; + pkm.Types[1] = (byte) CB_Type2.SelectedIndex; + pkm.Items[0] = (ushort) CB_HeldItem1.SelectedIndex; + pkm.Items[1] = (ushort) CB_HeldItem2.SelectedIndex; + pkm.Items[2] = (ushort) CB_HeldItem3.SelectedIndex; + + pkm.Gender = Convert.ToByte(TB_Gender.Text); + pkm.HatchCycles = Convert.ToByte(TB_HatchCycles.Text); + pkm.BaseFriendship = Convert.ToByte(TB_Friendship.Text); + pkm.EXPGrowth = (byte) CB_EXPGroup.SelectedIndex; + pkm.EggGroups[0] = (byte) CB_EggGroup1.SelectedIndex; + pkm.EggGroups[1] = (byte) CB_EggGroup2.SelectedIndex; + + pkm.Abilities[0] = (byte) CB_Ability1.SelectedIndex; + pkm.Abilities[1] = (byte) CB_Ability2.SelectedIndex; + pkm.Abilities[2] = (byte) CB_Ability3.SelectedIndex; + + pkm.FormeSprite = Convert.ToUInt16(TB_FormeSprite.Text); + pkm.FormeCount = Convert.ToByte(TB_FormeCount.Text); + pkm.Color = (byte) (Convert.ToByte(CB_Color.SelectedIndex) | (Convert.ToByte(TB_RawColor.Text) & 0xF0)); + pkm.BaseEXP = Convert.ToUInt16(TB_BaseExp.Text); + + pkm.Height = (int)Convert.ToDouble(TB_Height.Text)*100; + pkm.Weight = (int)Convert.ToDouble(TB_Weight.Text)*10; + + for (int i = 0; i < CLB_TMHM.Items.Count; i++) + pkm.TMHM[i] = CLB_TMHM.GetItemChecked(i); + + for (int t = 0; t < CLB_MoveTutors.Items.Count; t++) + pkm.TypeTutors[t] = CLB_MoveTutors.GetItemChecked(t); + } + private void saveEntry() + { + savePersonal(); + byte[] edits = pkm.Write(); + File.WriteAllBytes(paths[entry], edits); + Array.Copy(edits, 0, data, entry * edits.Length, edits.Length); + File.WriteAllBytes(paths[paths.Length - 1], data); + } + + private void B_Randomize_Click(object sender, EventArgs e) + { + Random rnd = new Random(); + const int TMPercent = 35; // Average Learnable TMs is 35.260. + const int TutorPercent = 2; //136 special tutor moves learnable by species in Untouched ORAS. + ushort[] itemlist = Main.Config.ORAS ? Legal.Pouch_Items_ORAS : Legal.Pouch_Items_XY; + ushort[] berrylist = Legal.Pouch_Berry_XY; + Array.Resize(ref itemlist, itemlist.Length + berrylist.Length); + Array.Copy(berrylist, 0, itemlist, itemlist.Length - berrylist.Length, berrylist.Length); + + int itemlen = itemlist.Length; + int abillen = CB_Ability1.Items.Count; + int typelen = CB_Type1.Items.Count; + + for (int i = 1; i < CB_Species.Items.Count; i++) + { + CB_Species.SelectedIndex = i; // Get new Species + + // Fiddle with TM Learnsets + if (CHK_TM.Checked) + for (int t = 0; t < 100; t++) + CLB_TMHM.SetItemCheckState(t, rnd.Next(0, 100) < TMPercent ? CheckState.Checked : CheckState.Unchecked); + if (CHK_HM.Checked) + for (int t = 100; t < CLB_TMHM.Items.Count;t++) + CLB_TMHM.SetItemCheckState(t, rnd.Next(0, 100) < TMPercent ? CheckState.Checked : CheckState.Unchecked); + if (CHK_Tutors.Checked) + { + for (int t = 0; t < CLB_MoveTutors.Items.Count; t++) + CLB_MoveTutors.SetItemCheckState(t, rnd.Next(0, 100) < TutorPercent ? CheckState.Checked : CheckState.Unchecked); + if (Main.Config.ORAS && (CB_Species.SelectedIndex == 384 || CB_Species.SelectedIndex == 814)) //Make sure Rayquaza can learn Dragon Ascent. + CLB_MoveTutors.SetItemCheckState(CLB_MoveTutors.Items.Count-1, CheckState.Checked); + } + + // Abilities: + if (CHK_Ability.Checked) + { + ComboBox[] abils = {CB_Ability1, CB_Ability2, CB_Ability3}; + for (int a = 0; a < 3; a++) // Set 3 New Abilities, none being Wonder Guard (25) unless CHK_WGuard is checked. + { + int newabil = rnd.Next(1, abillen); + while (newabil == 25 && !CHK_WGuard.Checked) + newabil = rnd.Next(1, abillen); + if (abils[a].SelectedIndex != 25 || CHK_WGuard.Checked) abils[a].SelectedIndex = newabil; + } + } + + // Fiddle with Base Stats, don't muck with Shedinja. + if (CHK_Stats.Checked) + { + if (Convert.ToByte(byte_boxes[0].Text) != 1) + for (int z = 0; z < 6; z++) + if (rstat_boxes[z].Checked) + byte_boxes[z].Text = + Math.Max(5,rnd.Next( + Math.Min(255, (int) (Convert.ToByte(byte_boxes[z].Text)*(1 - NUD_StatDev.Value/100))), + Math.Min(255, (int) (Convert.ToByte(byte_boxes[z].Text)*(1 + NUD_StatDev.Value/100))) + )).ToString("000"); + } + // EV yield stays the same... + + if (CHK_CatchRate.Checked) + TB_CatchRate.Text = rnd.Next(3, 251).ToString("000"); //Random Catch Rate between 3 and 250. Should I make this normally distributed? + if (CHK_EggGroup.Checked) + { + if (rnd.Next(0, 100) < NUD_Egg.Value) // 50% chance to have either One or Two Egg Groups + CB_EggGroup1.SelectedIndex = CB_EggGroup2.SelectedIndex = rnd.Next(1, CB_EggGroup1.Items.Count); + else + { + CB_EggGroup1.SelectedIndex = rnd.Next(1, CB_EggGroup1.Items.Count); + CB_EggGroup2.SelectedIndex = rnd.Next(1, CB_EggGroup1.Items.Count); + } + } + + // Items + if (CHK_Item.Checked) + { + CB_HeldItem1.SelectedIndex = itemlist[rnd.Next(1, itemlen)]; + CB_HeldItem2.SelectedIndex = itemlist[rnd.Next(1, itemlen)]; + CB_HeldItem3.SelectedIndex = itemlist[rnd.Next(1, itemlen)]; + } + + // Type + if (CHK_Type.Checked) + { + if (rnd.Next(0, 100) < NUD_TypePercent.Value) // 50% chance to have either Single or Dual Typing + CB_Type1.SelectedIndex = CB_Type2.SelectedIndex = rnd.Next(0, typelen); + else + { + CB_Type1.SelectedIndex = rnd.Next(0, typelen); + CB_Type2.SelectedIndex = rnd.Next(0, typelen); + } + } + } + saveEntry(); + Util.Alert("All relevant Pokemon Personal Entries have been randomized!"); + } + private void B_ModifyAll(object sender, EventArgs e) + { + for (int i = 1; i < CB_Species.Items.Count; i++) + { + CB_Species.SelectedIndex = i; // Get new Species + + if (CHK_NoEV.Checked) + for (int z = 0; z < 6; z++) + ev_boxes[z].Text = 0.ToString(); + if (CHK_LowCatch.Checked) + TB_CatchRate.Text = 3.ToString("000"); + if (CHK_Growth.Checked) + CB_EXPGroup.SelectedIndex = 5; + if (CHK_EXP.Checked) + TB_BaseExp.Text = ((float)NUD_EXP.Value*(Convert.ToUInt16(TB_BaseExp.Text)/100f)).ToString("000"); + + if (CHK_QuickHatch.Checked) + TB_HatchCycles.Text = 1.ToString(); + } + CB_Species.SelectedIndex = 1; + Util.Alert("All species modified to specification!"); + } + private bool dumping; + private void B_Dump_Click(object sender, EventArgs e) + { + + if (DialogResult.Yes != Util.Prompt(MessageBoxButtons.YesNo, "Dump all Personal Entries to Text File?")) + return; + + dumping = true; + string result = ""; + for (int i = 0; i < CB_Species.Items.Count; i++) + { + CB_Species.SelectedIndex = i; // Get new Species + result += "======" + Environment.NewLine + entry + " " + CB_Species.Text + Environment.NewLine + "======" + Environment.NewLine; + + result += + $"Base Stats: {TB_BaseHP.Text}.{TB_BaseATK.Text}.{TB_BaseDEF.Text}.{TB_BaseSPA.Text}.{TB_BaseSPD.Text}.{TB_BaseSPE.Text} (BST: {pkm.BST})" + Environment.NewLine; + result += + $"EV Yield: {TB_HPEVs.Text}.{TB_ATKEVs.Text}.{TB_DEFEVs.Text}.{TB_SPAEVs.Text}.{TB_SPDEVs.Text}.{TB_SPEEVs.Text}" + Environment.NewLine; + result += $"Abilities: {CB_Ability1.Text} (1) | {CB_Ability2.Text} (2) | {CB_Ability3.Text} (H)" + Environment.NewLine; + + result += string.Format(CB_Type1.SelectedIndex != CB_Type2.SelectedIndex ? "Type: {0} / {1}" : "Type: {0}", CB_Type1.Text, CB_Type2.Text); + + result += $"Item 1 (50%): {CB_HeldItem1.Text}" + Environment.NewLine; + result += $"Item 2 (5%): {CB_HeldItem2.Text}" + Environment.NewLine; + result += $"Item 3 (1%): {CB_HeldItem3.Text}" + Environment.NewLine; + // I don't want to add anything else. Should be pretty easy for anyone else to expand. + + result += Environment.NewLine; + } + + SaveFileDialog sfd = new SaveFileDialog {FileName = "Personal Entries.txt", Filter = "Text File|*.txt"}; + + SystemSounds.Asterisk.Play(); + if (sfd.ShowDialog() == DialogResult.OK) + { + string path = sfd.FileName; + File.WriteAllText(path, result, Encoding.Unicode); + } + dumping = false; + } + private void CHK_Stats_CheckedChanged(object sender, EventArgs e) + { + L_StatDev.Visible = NUD_StatDev.Visible = CHK_Stats.Checked; + } + private void CHK_Ability_CheckedChanged(object sender, EventArgs e) + { + CHK_WGuard.Enabled = CHK_Ability.Checked; + if (!CHK_WGuard.Enabled) + CHK_WGuard.Checked = false; + } + + private void formClosing(object sender, FormClosingEventArgs e) + { + if (entry > -1) saveEntry(); + } + } +} \ No newline at end of file diff --git a/pk3DS/Subforms/Gen7/PersonalEditor7.resx b/pk3DS/Subforms/Gen7/PersonalEditor7.resx new file mode 100644 index 0000000..1af7de1 --- /dev/null +++ b/pk3DS/Subforms/Gen7/PersonalEditor7.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/pk3DS/Subforms/Gen7/TMEditor7.Designer.cs b/pk3DS/Subforms/Gen7/TMEditor7.Designer.cs new file mode 100644 index 0000000..350bf49 --- /dev/null +++ b/pk3DS/Subforms/Gen7/TMEditor7.Designer.cs @@ -0,0 +1,97 @@ +namespace pk3DS +{ + partial class TMEditor7 + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.dgvTM = new System.Windows.Forms.DataGridView(); + this.L_TM = new System.Windows.Forms.Label(); + this.B_RTM = new System.Windows.Forms.Button(); + ((System.ComponentModel.ISupportInitialize)(this.dgvTM)).BeginInit(); + this.SuspendLayout(); + // + // dgvTM + // + this.dgvTM.AllowUserToAddRows = false; + this.dgvTM.AllowUserToDeleteRows = false; + this.dgvTM.AllowUserToResizeColumns = false; + this.dgvTM.AllowUserToResizeRows = false; + this.dgvTM.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + | System.Windows.Forms.AnchorStyles.Left))); + this.dgvTM.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; + this.dgvTM.Location = new System.Drawing.Point(9, 25); + this.dgvTM.Name = "dgvTM"; + this.dgvTM.Size = new System.Drawing.Size(240, 299); + this.dgvTM.TabIndex = 1; + // + // L_TM + // + this.L_TM.AutoSize = true; + this.L_TM.Location = new System.Drawing.Point(9, 9); + this.L_TM.Name = "L_TM"; + this.L_TM.Size = new System.Drawing.Size(26, 13); + this.L_TM.TabIndex = 2; + this.L_TM.Text = "TM:"; + // + // B_RTM + // + this.B_RTM.Location = new System.Drawing.Point(41, 1); + this.B_RTM.Name = "B_RTM"; + this.B_RTM.Size = new System.Drawing.Size(75, 23); + this.B_RTM.TabIndex = 5; + this.B_RTM.Text = "Randomize"; + this.B_RTM.UseVisualStyleBackColor = true; + this.B_RTM.Click += new System.EventHandler(this.B_RandomTM_Click); + // + // TMHMEditor7 + // + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.ClientSize = new System.Drawing.Size(259, 331); + this.Controls.Add(this.B_RTM); + this.Controls.Add(this.L_TM); + this.Controls.Add(this.dgvTM); + this.MaximizeBox = false; + this.MaximumSize = new System.Drawing.Size(520, 670); + this.MinimumSize = new System.Drawing.Size(275, 370); + this.Name = "TMHMEditor7"; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; + this.Text = "TM Editor"; + this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.formClosing); + ((System.ComponentModel.ISupportInitialize)(this.dgvTM)).EndInit(); + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + + private System.Windows.Forms.DataGridView dgvTM; + private System.Windows.Forms.Label L_TM; + private System.Windows.Forms.Button B_RTM; + } +} \ No newline at end of file diff --git a/pk3DS/Subforms/Gen7/TMEditor7.cs b/pk3DS/Subforms/Gen7/TMEditor7.cs new file mode 100644 index 0000000..5123aec --- /dev/null +++ b/pk3DS/Subforms/Gen7/TMEditor7.cs @@ -0,0 +1,132 @@ +using System; +using System.Collections.Generic; +using System.IO; +using System.Windows.Forms; +using System.Linq; + +namespace pk3DS +{ + public partial class TMEditor7 : Form + { + public TMEditor7() + { + InitializeComponent(); + if (Main.ExeFSPath == null) { Util.Alert("No exeFS code to load."); Close(); } + string[] files = Directory.GetFiles(Main.ExeFSPath); + if (!File.Exists(files[0]) || !Path.GetFileNameWithoutExtension(files[0]).Contains("code")) { Util.Alert("No .code.bin detected."); Close(); } + data = File.ReadAllBytes(files[0]); + if (data.Length % 0x200 != 0) { Util.Alert(".code.bin not decompressed. Aborting."); Close(); } + offset = Util.IndexOfBytes(data, Signature, 0x500000, 0) + 8; + codebin = files[0]; + movelist[0] = ""; + setupDGV(); + getList(); + } + + private static readonly byte[] Signature = {0x03, 0x40, 0x03, 0x41, 0x03, 0x42, 0x03, 0x43, 0x03}; // tail end of item::ITEM_CheckBeads + private readonly string codebin; + private readonly string[] movelist = Main.getText(TextName.MoveNames); + private readonly int offset = 0x0059795A; // Default + private readonly byte[] data; + private int dataoffset; + private void getDataOffset() + { + dataoffset = offset; // reset + } + private void setupDGV() + { + dgvTM.Columns.Clear(); + DataGridViewColumn dgvIndex = new DataGridViewTextBoxColumn(); + { + dgvIndex.HeaderText = "Index"; + dgvIndex.DisplayIndex = 0; + dgvIndex.Width = 45; + dgvIndex.ReadOnly = true; + dgvIndex.DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter; + dgvIndex.SortMode = DataGridViewColumnSortMode.NotSortable; + } + DataGridViewComboBoxColumn dgvMove = new DataGridViewComboBoxColumn(); + { + dgvMove.HeaderText = "Move"; + dgvMove.DisplayIndex = 1; + foreach (string t in movelist) + dgvMove.Items.Add(t); // add only the Names + + dgvMove.Width = 133; + dgvMove.FlatStyle = FlatStyle.Flat; + dgvIndex.SortMode = DataGridViewColumnSortMode.NotSortable; + } + dgvTM.Columns.Add(dgvIndex); + dgvTM.Columns.Add(dgvMove); + } + + private List tms = new List(); + + private void getList() + { + tms = new List(); + dgvTM.Rows.Clear(); + + getDataOffset(); + for (int i = 0; i < 100; i++) // TMs stored sequentially + tms.Add(BitConverter.ToUInt16(data, dataoffset + 2 * i)); + + ushort[] tmlist = tms.ToArray(); + for (int i = 0; i < tmlist.Length; i++) + { dgvTM.Rows.Add(); dgvTM.Rows[i].Cells[0].Value = (i + 1).ToString(); dgvTM.Rows[i].Cells[1].Value = movelist[tmlist[i]]; } + } + private void setList() + { + // Gather TM/HM list. + tms = new List(); + for (int i = 0; i < dgvTM.Rows.Count; i++) + tms.Add((ushort)Array.IndexOf(movelist, dgvTM.Rows[i].Cells[1].Value)); + + ushort[] tmlist = tms.ToArray(); + + // Set TM/HM list in + for (int i = 0; i < 100; i++) + Array.Copy(BitConverter.GetBytes(tmlist[i]), 0, data, offset + 2 * i, 2); + } + + private void formClosing(object sender, FormClosingEventArgs e) + { + setList(); + File.WriteAllBytes(codebin, data); + } + + private void B_RandomTM_Click(object sender, EventArgs e) + { + int[] randomMoves = Enumerable.Range(1, movelist.Length - 1).Select(i => i).ToArray(); + Util.Shuffle(randomMoves); + + int[] banned = { 15, 19, 57, 70, 127, 249, 291, 148 }; + int ctr = 0; + + for (int i = 0; i < dgvTM.Rows.Count; i++) + { + int val = Array.IndexOf(movelist, dgvTM.Rows[i].Cells[1].Value); + if (banned.Contains(val)) continue; + while (banned.Contains(randomMoves[ctr])) ctr++; + + dgvTM.Rows[i].Cells[1].Value = movelist[randomMoves[ctr++]]; + } + } + + internal static void getTMHMList(ref ushort[] TMs) + { + if (Main.ExeFSPath == null) return; + string[] files = Directory.GetFiles(Main.ExeFSPath); + if (!File.Exists(files[0]) || !Path.GetFileNameWithoutExtension(files[0]).Contains("code")) return; + byte[] data = File.ReadAllBytes(files[0]); + int dataoffset = Util.IndexOfBytes(data, Signature, 0x500000, 0) + 8; + if (data.Length % 0x200 != 0) return; + + List tms = new List(); + + for (int i = 0; i < 100; i++) // TMs stored sequentially + tms.Add(BitConverter.ToUInt16(data, dataoffset + 2 * i)); + TMs = tms.ToArray(); + } + } +} \ No newline at end of file diff --git a/pk3DS/Subforms/Gen7/TMEditor7.resx b/pk3DS/Subforms/Gen7/TMEditor7.resx new file mode 100644 index 0000000..1af7de1 --- /dev/null +++ b/pk3DS/Subforms/Gen7/TMEditor7.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/pk3DS/pk3DS.csproj b/pk3DS/pk3DS.csproj index 96cc11e..b364024 100644 --- a/pk3DS/pk3DS.csproj +++ b/pk3DS/pk3DS.csproj @@ -60,6 +60,7 @@ + @@ -73,8 +74,11 @@ - + + + + @@ -88,6 +92,12 @@ + + Form + + + PersonalEditor7.cs + Form @@ -118,6 +128,12 @@ MapPermView.cs + + Form + + + TMEditor7.cs + Form @@ -293,6 +309,9 @@ About.cs + + PersonalEditor7.cs + SMTE.cs @@ -308,6 +327,9 @@ MapPermView.cs + + TMEditor7.cs + Shuffler.cs