From 99b51f84d0a29598ad752c0a526f8f65ac9c7ee8 Mon Sep 17 00:00:00 2001 From: sora10pls Date: Tue, 19 Dec 2017 20:56:50 -0500 Subject: [PATCH 1/2] Update gen6 static/gift editors --- pk3DS/Subforms/Gen6/GiftEditor6.Designer.cs | 778 +++++++++--------- pk3DS/Subforms/Gen6/GiftEditor6.cs | 35 +- .../Gen6/StaticEncounterEditor6.Designer.cs | 448 +++++----- pk3DS/Subforms/Gen6/StaticEncounterEditor6.cs | 29 +- pk3DS/Subforms/Gen7/StaticEncounterEditor7.cs | 1 - 5 files changed, 655 insertions(+), 636 deletions(-) diff --git a/pk3DS/Subforms/Gen6/GiftEditor6.Designer.cs b/pk3DS/Subforms/Gen6/GiftEditor6.Designer.cs index 77c5d01..a1d3aed 100644 --- a/pk3DS/Subforms/Gen6/GiftEditor6.Designer.cs +++ b/pk3DS/Subforms/Gen6/GiftEditor6.Designer.cs @@ -33,26 +33,13 @@ private void InitializeComponent() this.LB_Gifts = new System.Windows.Forms.ListBox(); this.CB_Species = new System.Windows.Forms.ComboBox(); this.CB_HeldItem = new System.Windows.Forms.ComboBox(); - this.NUD_IV0 = new System.Windows.Forms.NumericUpDown(); - this.NUD_IV1 = new System.Windows.Forms.NumericUpDown(); - this.NUD_IV2 = new System.Windows.Forms.NumericUpDown(); - this.NUD_IV3 = new System.Windows.Forms.NumericUpDown(); - this.NUD_IV4 = new System.Windows.Forms.NumericUpDown(); - this.NUD_IV5 = new System.Windows.Forms.NumericUpDown(); this.L_Species = new System.Windows.Forms.Label(); this.L_HeldItem = new System.Windows.Forms.Label(); this.NUD_Level = new System.Windows.Forms.NumericUpDown(); this.L_Level = new System.Windows.Forms.Label(); this.NUD_Form = new System.Windows.Forms.NumericUpDown(); this.L_Form = new System.Windows.Forms.Label(); - this.L_HP = new System.Windows.Forms.Label(); - this.L_ATK = new System.Windows.Forms.Label(); - this.L_DEF = new System.Windows.Forms.Label(); - this.L_SPA = new System.Windows.Forms.Label(); - this.L_SPE = new System.Windows.Forms.Label(); - this.L_SPD = new System.Windows.Forms.Label(); this.L_Nature = new System.Windows.Forms.Label(); - this.NUD_Nature = new System.Windows.Forms.NumericUpDown(); this.L_Ability = new System.Windows.Forms.Label(); this.NUD_Ability = new System.Windows.Forms.NumericUpDown(); this.L_Gender = new System.Windows.Forms.Label(); @@ -61,12 +48,28 @@ private void InitializeComponent() this.tabControl1 = new System.Windows.Forms.TabControl(); this.tabPage1 = new System.Windows.Forms.TabPage(); this.CHK_ShinyLock = new System.Windows.Forms.CheckBox(); - this.label1 = new System.Windows.Forms.Label(); - this.L_Hint = new System.Windows.Forms.Label(); this.tabPage2 = new System.Windows.Forms.TabPage(); this.L_Mega = new System.Windows.Forms.Label(); - this.CHK_Mega = new System.Windows.Forms.CheckBox(); + this.CHK_ReplaceMega = new System.Windows.Forms.CheckBox(); + this.NUD_LevelBoost = new System.Windows.Forms.NumericUpDown(); + this.CHK_Level = new System.Windows.Forms.CheckBox(); + this.GB_EIVs = new System.Windows.Forms.GroupBox(); + this.L_HP = new System.Windows.Forms.Label(); + this.NUD_IV3 = new System.Windows.Forms.NumericUpDown(); + this.NUD_IV4 = new System.Windows.Forms.NumericUpDown(); + this.NUD_IV5 = new System.Windows.Forms.NumericUpDown(); + this.L_SPD = new System.Windows.Forms.Label(); + this.L_SPE = new System.Windows.Forms.Label(); + this.L_SPA = new System.Windows.Forms.Label(); + this.NUD_IV2 = new System.Windows.Forms.NumericUpDown(); + this.NUD_IV1 = new System.Windows.Forms.NumericUpDown(); + this.NUD_IV0 = new System.Windows.Forms.NumericUpDown(); + this.L_ATK = new System.Windows.Forms.Label(); + this.L_DEF = new System.Windows.Forms.Label(); + this.CB_Nature = new System.Windows.Forms.ComboBox(); this.GB_Tweak = new System.Windows.Forms.GroupBox(); + this.CHK_RemoveShinyLock = new System.Windows.Forms.CheckBox(); + this.CHK_AllowMega = new System.Windows.Forms.CheckBox(); this.CHK_Item = new System.Windows.Forms.CheckBox(); this.L_RandOpt = new System.Windows.Forms.Label(); this.CHK_BST = new System.Windows.Forms.CheckBox(); @@ -78,31 +81,29 @@ private void InitializeComponent() this.CHK_G3 = new System.Windows.Forms.CheckBox(); this.CHK_G2 = new System.Windows.Forms.CheckBox(); this.CHK_G1 = new System.Windows.Forms.CheckBox(); - this.NUD_LevelBoost = new System.Windows.Forms.NumericUpDown(); - this.CHK_Level = new System.Windows.Forms.CheckBox(); - this.CHK_RemoveShinyLock = new System.Windows.Forms.CheckBox(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_IV0)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_IV1)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_IV2)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_IV3)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_IV4)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_IV5)).BeginInit(); + this.B_ModifyLevel = new System.Windows.Forms.Button(); ((System.ComponentModel.ISupportInitialize)(this.NUD_Level)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.NUD_Form)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_Nature)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.NUD_Ability)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.NUD_Gender)).BeginInit(); this.tabControl1.SuspendLayout(); this.tabPage1.SuspendLayout(); this.tabPage2.SuspendLayout(); - this.GB_Tweak.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.NUD_LevelBoost)).BeginInit(); + this.GB_EIVs.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_IV3)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_IV4)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_IV5)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_IV2)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_IV1)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_IV0)).BeginInit(); + this.GB_Tweak.SuspendLayout(); this.SuspendLayout(); // // B_Cancel // this.B_Cancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); - this.B_Cancel.Location = new System.Drawing.Point(264, 269); + this.B_Cancel.Location = new System.Drawing.Point(264, 338); this.B_Cancel.Name = "B_Cancel"; this.B_Cancel.Size = new System.Drawing.Size(70, 23); this.B_Cancel.TabIndex = 467; @@ -113,7 +114,7 @@ private void InitializeComponent() // B_Save // this.B_Save.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); - this.B_Save.Location = new System.Drawing.Point(335, 269); + this.B_Save.Location = new System.Drawing.Point(335, 338); this.B_Save.Name = "B_Save"; this.B_Save.Size = new System.Drawing.Size(70, 23); this.B_Save.TabIndex = 466; @@ -128,14 +129,14 @@ private void InitializeComponent() this.LB_Gifts.FormattingEnabled = true; this.LB_Gifts.Location = new System.Drawing.Point(12, 12); this.LB_Gifts.Name = "LB_Gifts"; - this.LB_Gifts.Size = new System.Drawing.Size(110, 277); + this.LB_Gifts.Size = new System.Drawing.Size(110, 342); this.LB_Gifts.TabIndex = 468; this.LB_Gifts.SelectedIndexChanged += new System.EventHandler(this.changeIndex); // // CB_Species // this.CB_Species.FormattingEnabled = true; - this.CB_Species.Location = new System.Drawing.Point(106, 3); + this.CB_Species.Location = new System.Drawing.Point(65, 7); this.CB_Species.Name = "CB_Species"; this.CB_Species.Size = new System.Drawing.Size(121, 21); this.CB_Species.TabIndex = 469; @@ -144,164 +145,32 @@ private void InitializeComponent() // CB_HeldItem // this.CB_HeldItem.FormattingEnabled = true; - this.CB_HeldItem.Location = new System.Drawing.Point(106, 28); + this.CB_HeldItem.Location = new System.Drawing.Point(65, 118); this.CB_HeldItem.Name = "CB_HeldItem"; this.CB_HeldItem.Size = new System.Drawing.Size(121, 21); this.CB_HeldItem.TabIndex = 470; // - // NUD_IV0 - // - this.NUD_IV0.Location = new System.Drawing.Point(139, 152); - this.NUD_IV0.Maximum = new decimal(new int[] { - 31, - 0, - 0, - 0}); - this.NUD_IV0.Minimum = new decimal(new int[] { - 1, - 0, - 0, - -2147483648}); - this.NUD_IV0.Name = "NUD_IV0"; - this.NUD_IV0.Size = new System.Drawing.Size(34, 20); - this.NUD_IV0.TabIndex = 471; - this.NUD_IV0.Value = new decimal(new int[] { - 31, - 0, - 0, - 0}); - // - // NUD_IV1 - // - this.NUD_IV1.Location = new System.Drawing.Point(139, 175); - this.NUD_IV1.Maximum = new decimal(new int[] { - 31, - 0, - 0, - 0}); - this.NUD_IV1.Minimum = new decimal(new int[] { - 1, - 0, - 0, - -2147483648}); - this.NUD_IV1.Name = "NUD_IV1"; - this.NUD_IV1.Size = new System.Drawing.Size(34, 20); - this.NUD_IV1.TabIndex = 472; - this.NUD_IV1.Value = new decimal(new int[] { - 31, - 0, - 0, - 0}); - // - // NUD_IV2 - // - this.NUD_IV2.Location = new System.Drawing.Point(139, 198); - this.NUD_IV2.Maximum = new decimal(new int[] { - 31, - 0, - 0, - 0}); - this.NUD_IV2.Minimum = new decimal(new int[] { - 1, - 0, - 0, - -2147483648}); - this.NUD_IV2.Name = "NUD_IV2"; - this.NUD_IV2.Size = new System.Drawing.Size(34, 20); - this.NUD_IV2.TabIndex = 473; - this.NUD_IV2.Value = new decimal(new int[] { - 31, - 0, - 0, - 0}); - // - // NUD_IV3 - // - this.NUD_IV3.Location = new System.Drawing.Point(220, 152); - this.NUD_IV3.Maximum = new decimal(new int[] { - 31, - 0, - 0, - 0}); - this.NUD_IV3.Minimum = new decimal(new int[] { - 1, - 0, - 0, - -2147483648}); - this.NUD_IV3.Name = "NUD_IV3"; - this.NUD_IV3.Size = new System.Drawing.Size(34, 20); - this.NUD_IV3.TabIndex = 474; - this.NUD_IV3.Value = new decimal(new int[] { - 31, - 0, - 0, - 0}); - // - // NUD_IV4 - // - this.NUD_IV4.Location = new System.Drawing.Point(220, 175); - this.NUD_IV4.Maximum = new decimal(new int[] { - 31, - 0, - 0, - 0}); - this.NUD_IV4.Minimum = new decimal(new int[] { - 1, - 0, - 0, - -2147483648}); - this.NUD_IV4.Name = "NUD_IV4"; - this.NUD_IV4.Size = new System.Drawing.Size(34, 20); - this.NUD_IV4.TabIndex = 475; - this.NUD_IV4.Value = new decimal(new int[] { - 31, - 0, - 0, - 0}); - // - // NUD_IV5 - // - this.NUD_IV5.Location = new System.Drawing.Point(220, 198); - this.NUD_IV5.Maximum = new decimal(new int[] { - 31, - 0, - 0, - 0}); - this.NUD_IV5.Minimum = new decimal(new int[] { - 1, - 0, - 0, - -2147483648}); - this.NUD_IV5.Name = "NUD_IV5"; - this.NUD_IV5.Size = new System.Drawing.Size(34, 20); - this.NUD_IV5.TabIndex = 476; - this.NUD_IV5.Value = new decimal(new int[] { - 31, - 0, - 0, - 0}); - // // L_Species // - this.L_Species.Location = new System.Drawing.Point(6, 2); + this.L_Species.Location = new System.Drawing.Point(9, 6); this.L_Species.Name = "L_Species"; - this.L_Species.Size = new System.Drawing.Size(94, 21); + this.L_Species.Size = new System.Drawing.Size(55, 23); this.L_Species.TabIndex = 477; this.L_Species.Text = "Species:"; this.L_Species.TextAlign = System.Drawing.ContentAlignment.MiddleRight; // // L_HeldItem // - this.L_HeldItem.Location = new System.Drawing.Point(6, 27); + this.L_HeldItem.Location = new System.Drawing.Point(9, 117); this.L_HeldItem.Name = "L_HeldItem"; - this.L_HeldItem.Size = new System.Drawing.Size(94, 21); + this.L_HeldItem.Size = new System.Drawing.Size(55, 23); this.L_HeldItem.TabIndex = 478; this.L_HeldItem.Text = "Held Item:"; this.L_HeldItem.TextAlign = System.Drawing.ContentAlignment.MiddleRight; // // NUD_Level // - this.NUD_Level.Location = new System.Drawing.Point(133, 77); + this.NUD_Level.Location = new System.Drawing.Point(65, 30); this.NUD_Level.Name = "NUD_Level"; this.NUD_Level.Size = new System.Drawing.Size(41, 20); this.NUD_Level.TabIndex = 479; @@ -313,128 +182,52 @@ private void InitializeComponent() // // L_Level // - this.L_Level.Location = new System.Drawing.Point(38, 75); + this.L_Level.Location = new System.Drawing.Point(9, 27); this.L_Level.Name = "L_Level"; - this.L_Level.Size = new System.Drawing.Size(94, 21); + this.L_Level.Size = new System.Drawing.Size(55, 23); this.L_Level.TabIndex = 480; this.L_Level.Text = "Level:"; this.L_Level.TextAlign = System.Drawing.ContentAlignment.MiddleRight; // // NUD_Form // - this.NUD_Form.Location = new System.Drawing.Point(220, 77); + this.NUD_Form.Location = new System.Drawing.Point(65, 52); this.NUD_Form.Name = "NUD_Form"; - this.NUD_Form.Size = new System.Drawing.Size(34, 20); + this.NUD_Form.Size = new System.Drawing.Size(41, 20); this.NUD_Form.TabIndex = 481; // // L_Form // - this.L_Form.Location = new System.Drawing.Point(126, 75); + this.L_Form.Location = new System.Drawing.Point(9, 49); this.L_Form.Name = "L_Form"; - this.L_Form.Size = new System.Drawing.Size(94, 21); + this.L_Form.Size = new System.Drawing.Size(55, 23); this.L_Form.TabIndex = 482; this.L_Form.Text = "Form:"; this.L_Form.TextAlign = System.Drawing.ContentAlignment.MiddleRight; // - // L_HP - // - this.L_HP.Location = new System.Drawing.Point(45, 150); - this.L_HP.Name = "L_HP"; - this.L_HP.Size = new System.Drawing.Size(94, 21); - this.L_HP.TabIndex = 483; - this.L_HP.Text = "HP:"; - this.L_HP.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // L_ATK - // - this.L_ATK.Location = new System.Drawing.Point(45, 173); - this.L_ATK.Name = "L_ATK"; - this.L_ATK.Size = new System.Drawing.Size(94, 21); - this.L_ATK.TabIndex = 484; - this.L_ATK.Text = "Atk:"; - this.L_ATK.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // L_DEF - // - this.L_DEF.Location = new System.Drawing.Point(45, 196); - this.L_DEF.Name = "L_DEF"; - this.L_DEF.Size = new System.Drawing.Size(94, 21); - this.L_DEF.TabIndex = 485; - this.L_DEF.Text = "Def:"; - this.L_DEF.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // L_SPA - // - this.L_SPA.Location = new System.Drawing.Point(126, 150); - this.L_SPA.Name = "L_SPA"; - this.L_SPA.Size = new System.Drawing.Size(94, 21); - this.L_SPA.TabIndex = 486; - this.L_SPA.Text = "SpA:"; - this.L_SPA.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // L_SPE - // - this.L_SPE.Location = new System.Drawing.Point(126, 196); - this.L_SPE.Name = "L_SPE"; - this.L_SPE.Size = new System.Drawing.Size(94, 21); - this.L_SPE.TabIndex = 487; - this.L_SPE.Text = "Spe:"; - this.L_SPE.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // L_SPD - // - this.L_SPD.Location = new System.Drawing.Point(126, 173); - this.L_SPD.Name = "L_SPD"; - this.L_SPD.Size = new System.Drawing.Size(94, 21); - this.L_SPD.TabIndex = 488; - this.L_SPD.Text = "SpD:"; - this.L_SPD.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // // L_Nature // - this.L_Nature.Location = new System.Drawing.Point(37, 97); + this.L_Nature.Location = new System.Drawing.Point(9, 140); this.L_Nature.Name = "L_Nature"; - this.L_Nature.Size = new System.Drawing.Size(94, 21); + this.L_Nature.Size = new System.Drawing.Size(55, 23); this.L_Nature.TabIndex = 490; this.L_Nature.Text = "Nature:"; this.L_Nature.TextAlign = System.Drawing.ContentAlignment.MiddleRight; // - // NUD_Nature - // - this.NUD_Nature.Location = new System.Drawing.Point(133, 99); - this.NUD_Nature.Maximum = new decimal(new int[] { - 24, - 0, - 0, - 0}); - this.NUD_Nature.Minimum = new decimal(new int[] { - 1, - 0, - 0, - -2147483648}); - this.NUD_Nature.Name = "NUD_Nature"; - this.NUD_Nature.Size = new System.Drawing.Size(34, 20); - this.NUD_Nature.TabIndex = 491; - this.NUD_Nature.Value = new decimal(new int[] { - 1, - 0, - 0, - -2147483648}); - // // L_Ability // - this.L_Ability.Location = new System.Drawing.Point(126, 97); + this.L_Ability.Location = new System.Drawing.Point(9, 71); this.L_Ability.Name = "L_Ability"; - this.L_Ability.Size = new System.Drawing.Size(94, 21); + this.L_Ability.Size = new System.Drawing.Size(55, 23); this.L_Ability.TabIndex = 493; this.L_Ability.Text = "Ability:"; this.L_Ability.TextAlign = System.Drawing.ContentAlignment.MiddleRight; // // NUD_Ability // - this.NUD_Ability.Location = new System.Drawing.Point(220, 99); + this.NUD_Ability.Location = new System.Drawing.Point(65, 74); this.NUD_Ability.Maximum = new decimal(new int[] { - 2, + 3, 0, 0, 0}); @@ -444,34 +237,34 @@ private void InitializeComponent() 0, -2147483648}); this.NUD_Ability.Name = "NUD_Ability"; - this.NUD_Ability.Size = new System.Drawing.Size(34, 20); + this.NUD_Ability.Size = new System.Drawing.Size(41, 20); this.NUD_Ability.TabIndex = 492; // // L_Gender // - this.L_Gender.Location = new System.Drawing.Point(126, 120); + this.L_Gender.Location = new System.Drawing.Point(9, 96); this.L_Gender.Name = "L_Gender"; - this.L_Gender.Size = new System.Drawing.Size(94, 21); + this.L_Gender.Size = new System.Drawing.Size(55, 23); this.L_Gender.TabIndex = 495; this.L_Gender.Text = "Gender:"; this.L_Gender.TextAlign = System.Drawing.ContentAlignment.MiddleRight; // // NUD_Gender // - this.NUD_Gender.Location = new System.Drawing.Point(220, 122); + this.NUD_Gender.Location = new System.Drawing.Point(65, 96); this.NUD_Gender.Maximum = new decimal(new int[] { 2, 0, 0, 0}); this.NUD_Gender.Name = "NUD_Gender"; - this.NUD_Gender.Size = new System.Drawing.Size(34, 20); + this.NUD_Gender.Size = new System.Drawing.Size(41, 20); this.NUD_Gender.TabIndex = 494; // // B_RandAll // this.B_RandAll.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); - this.B_RandAll.Location = new System.Drawing.Point(181, 269); + this.B_RandAll.Location = new System.Drawing.Point(181, 338); this.B_RandAll.Name = "B_RandAll"; this.B_RandAll.Size = new System.Drawing.Size(83, 23); this.B_RandAll.TabIndex = 496; @@ -486,30 +279,20 @@ private void InitializeComponent() this.tabControl1.Location = new System.Drawing.Point(128, 12); this.tabControl1.Name = "tabControl1"; this.tabControl1.SelectedIndex = 0; - this.tabControl1.Size = new System.Drawing.Size(280, 251); + this.tabControl1.Size = new System.Drawing.Size(277, 322); this.tabControl1.TabIndex = 502; // // tabPage1 // + this.tabPage1.Controls.Add(this.CB_Nature); + this.tabPage1.Controls.Add(this.GB_EIVs); this.tabPage1.Controls.Add(this.CHK_ShinyLock); - this.tabPage1.Controls.Add(this.label1); - this.tabPage1.Controls.Add(this.L_DEF); - this.tabPage1.Controls.Add(this.L_ATK); - this.tabPage1.Controls.Add(this.L_Hint); - this.tabPage1.Controls.Add(this.L_HP); - this.tabPage1.Controls.Add(this.NUD_IV0); - this.tabPage1.Controls.Add(this.NUD_IV1); - this.tabPage1.Controls.Add(this.NUD_IV2); this.tabPage1.Controls.Add(this.L_Gender); this.tabPage1.Controls.Add(this.CB_Species); this.tabPage1.Controls.Add(this.NUD_Gender); this.tabPage1.Controls.Add(this.NUD_Ability); - this.tabPage1.Controls.Add(this.NUD_Nature); this.tabPage1.Controls.Add(this.L_Ability); - this.tabPage1.Controls.Add(this.L_SPA); this.tabPage1.Controls.Add(this.L_Nature); - this.tabPage1.Controls.Add(this.L_SPE); - this.tabPage1.Controls.Add(this.L_SPD); this.tabPage1.Controls.Add(this.L_Species); this.tabPage1.Controls.Add(this.L_HeldItem); this.tabPage1.Controls.Add(this.NUD_Level); @@ -517,13 +300,10 @@ private void InitializeComponent() this.tabPage1.Controls.Add(this.L_Form); this.tabPage1.Controls.Add(this.CB_HeldItem); this.tabPage1.Controls.Add(this.NUD_Form); - this.tabPage1.Controls.Add(this.NUD_IV5); - this.tabPage1.Controls.Add(this.NUD_IV4); - this.tabPage1.Controls.Add(this.NUD_IV3); this.tabPage1.Location = new System.Drawing.Point(4, 22); this.tabPage1.Name = "tabPage1"; this.tabPage1.Padding = new System.Windows.Forms.Padding(3); - this.tabPage1.Size = new System.Drawing.Size(272, 225); + this.tabPage1.Size = new System.Drawing.Size(269, 296); this.tabPage1.TabIndex = 0; this.tabPage1.Text = "Editor"; this.tabPage1.UseVisualStyleBackColor = true; @@ -531,70 +311,304 @@ private void InitializeComponent() // CHK_ShinyLock // this.CHK_ShinyLock.AutoSize = true; - this.CHK_ShinyLock.Location = new System.Drawing.Point(106, 54); + this.CHK_ShinyLock.Location = new System.Drawing.Point(65, 165); this.CHK_ShinyLock.Name = "CHK_ShinyLock"; this.CHK_ShinyLock.Size = new System.Drawing.Size(79, 17); this.CHK_ShinyLock.TabIndex = 503; this.CHK_ShinyLock.Text = "Shiny Lock"; this.CHK_ShinyLock.UseVisualStyleBackColor = true; // - // label1 - // - this.label1.AutoSize = true; - this.label1.Location = new System.Drawing.Point(6, 155); - this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(83, 65); - this.label1.TabIndex = 502; - this.label1.Text = "Ability:\r\n0: Random\r\n1: Ability 1\r\n2: Ability 2\r\n3: Hidden Ability"; - // - // L_Hint - // - this.L_Hint.AutoSize = true; - this.L_Hint.Location = new System.Drawing.Point(7, 99); - this.L_Hint.Name = "L_Hint"; - this.L_Hint.Size = new System.Drawing.Size(67, 52); - this.L_Hint.TabIndex = 500; - this.L_Hint.Text = "Gender:\r\n0: Random/-\r\n1: Male\r\n2: Female"; - // // tabPage2 // - this.tabPage2.Controls.Add(this.L_Mega); - this.tabPage2.Controls.Add(this.CHK_Mega); + this.tabPage2.Controls.Add(this.B_ModifyLevel); this.tabPage2.Controls.Add(this.GB_Tweak); + this.tabPage2.Controls.Add(this.L_Mega); + this.tabPage2.Controls.Add(this.CHK_ReplaceMega); this.tabPage2.Controls.Add(this.NUD_LevelBoost); this.tabPage2.Controls.Add(this.CHK_Level); this.tabPage2.Location = new System.Drawing.Point(4, 22); this.tabPage2.Name = "tabPage2"; this.tabPage2.Padding = new System.Windows.Forms.Padding(3); - this.tabPage2.Size = new System.Drawing.Size(272, 225); + this.tabPage2.Size = new System.Drawing.Size(269, 296); this.tabPage2.TabIndex = 1; this.tabPage2.Text = "Randomizer Options"; this.tabPage2.UseVisualStyleBackColor = true; // // L_Mega // - this.L_Mega.Location = new System.Drawing.Point(26, 190); + this.L_Mega.Location = new System.Drawing.Point(24, 261); this.L_Mega.Name = "L_Mega"; this.L_Mega.Size = new System.Drawing.Size(113, 33); this.L_Mega.TabIndex = 512; this.L_Mega.Text = "XY - Lucario\nORAS - Latias/Latios"; this.L_Mega.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; // - // CHK_Mega + // CHK_ReplaceMega // - this.CHK_Mega.AutoSize = true; - this.CHK_Mega.Checked = true; - this.CHK_Mega.CheckState = System.Windows.Forms.CheckState.Checked; - this.CHK_Mega.Location = new System.Drawing.Point(9, 176); - this.CHK_Mega.Name = "CHK_Mega"; - this.CHK_Mega.Size = new System.Drawing.Size(264, 17); - this.CHK_Mega.TabIndex = 511; - this.CHK_Mega.Text = "Replace Megas with Another Mega (via Held Item)"; - this.CHK_Mega.UseVisualStyleBackColor = true; + this.CHK_ReplaceMega.AutoSize = true; + this.CHK_ReplaceMega.Checked = true; + this.CHK_ReplaceMega.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_ReplaceMega.Location = new System.Drawing.Point(7, 247); + this.CHK_ReplaceMega.Name = "CHK_ReplaceMega"; + this.CHK_ReplaceMega.Size = new System.Drawing.Size(264, 17); + this.CHK_ReplaceMega.TabIndex = 511; + this.CHK_ReplaceMega.Text = "Replace Megas with Another Mega (via Held Item)"; + this.CHK_ReplaceMega.UseVisualStyleBackColor = true; + // + // NUD_LevelBoost + // + this.NUD_LevelBoost.DecimalPlaces = 2; + this.NUD_LevelBoost.Increment = new decimal(new int[] { + 5, + 0, + 0, + 131072}); + this.NUD_LevelBoost.Location = new System.Drawing.Point(140, 6); + this.NUD_LevelBoost.Maximum = new decimal(new int[] { + 3, + 0, + 0, + 0}); + this.NUD_LevelBoost.Name = "NUD_LevelBoost"; + this.NUD_LevelBoost.Size = new System.Drawing.Size(43, 20); + this.NUD_LevelBoost.TabIndex = 303; + this.NUD_LevelBoost.Value = new decimal(new int[] { + 1, + 0, + 0, + 0}); + // + // CHK_Level + // + this.CHK_Level.AutoSize = true; + this.CHK_Level.Checked = true; + this.CHK_Level.CheckState = System.Windows.Forms.CheckState.Checked; + this.CHK_Level.Location = new System.Drawing.Point(9, 7); + this.CHK_Level.Name = "CHK_Level"; + this.CHK_Level.Size = new System.Drawing.Size(130, 17); + this.CHK_Level.TabIndex = 302; + this.CHK_Level.Text = "Multiply PKM Level by"; + this.CHK_Level.UseVisualStyleBackColor = true; + // + // GB_EIVs + // + this.GB_EIVs.Controls.Add(this.L_HP); + this.GB_EIVs.Controls.Add(this.NUD_IV3); + this.GB_EIVs.Controls.Add(this.NUD_IV4); + this.GB_EIVs.Controls.Add(this.NUD_IV5); + this.GB_EIVs.Controls.Add(this.L_SPD); + this.GB_EIVs.Controls.Add(this.L_SPE); + this.GB_EIVs.Controls.Add(this.L_SPA); + this.GB_EIVs.Controls.Add(this.NUD_IV2); + this.GB_EIVs.Controls.Add(this.NUD_IV1); + this.GB_EIVs.Controls.Add(this.NUD_IV0); + this.GB_EIVs.Controls.Add(this.L_ATK); + this.GB_EIVs.Controls.Add(this.L_DEF); + this.GB_EIVs.Location = new System.Drawing.Point(12, 179); + this.GB_EIVs.Name = "GB_EIVs"; + this.GB_EIVs.Size = new System.Drawing.Size(148, 112); + this.GB_EIVs.TabIndex = 504; + this.GB_EIVs.TabStop = false; + this.GB_EIVs.Text = "IVs"; + // + // L_HP + // + this.L_HP.Location = new System.Drawing.Point(4, 16); + this.L_HP.Name = "L_HP"; + this.L_HP.Size = new System.Drawing.Size(29, 21); + this.L_HP.TabIndex = 495; + this.L_HP.Text = "HP:"; + this.L_HP.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // NUD_IV3 + // + this.NUD_IV3.Location = new System.Drawing.Point(104, 18); + this.NUD_IV3.Maximum = new decimal(new int[] { + 31, + 0, + 0, + 0}); + this.NUD_IV3.Minimum = new decimal(new int[] { + 1, + 0, + 0, + -2147483648}); + this.NUD_IV3.Name = "NUD_IV3"; + this.NUD_IV3.Size = new System.Drawing.Size(34, 20); + this.NUD_IV3.TabIndex = 492; + this.NUD_IV3.Value = new decimal(new int[] { + 31, + 0, + 0, + 0}); + // + // NUD_IV4 + // + this.NUD_IV4.Location = new System.Drawing.Point(104, 49); + this.NUD_IV4.Maximum = new decimal(new int[] { + 31, + 0, + 0, + 0}); + this.NUD_IV4.Minimum = new decimal(new int[] { + 1, + 0, + 0, + -2147483648}); + this.NUD_IV4.Name = "NUD_IV4"; + this.NUD_IV4.Size = new System.Drawing.Size(34, 20); + this.NUD_IV4.TabIndex = 493; + this.NUD_IV4.Value = new decimal(new int[] { + 31, + 0, + 0, + 0}); + // + // NUD_IV5 + // + this.NUD_IV5.Location = new System.Drawing.Point(104, 80); + this.NUD_IV5.Maximum = new decimal(new int[] { + 31, + 0, + 0, + 0}); + this.NUD_IV5.Minimum = new decimal(new int[] { + 1, + 0, + 0, + -2147483648}); + this.NUD_IV5.Name = "NUD_IV5"; + this.NUD_IV5.Size = new System.Drawing.Size(34, 20); + this.NUD_IV5.TabIndex = 494; + this.NUD_IV5.Value = new decimal(new int[] { + 31, + 0, + 0, + 0}); + // + // L_SPD + // + this.L_SPD.Location = new System.Drawing.Point(73, 47); + this.L_SPD.Name = "L_SPD"; + this.L_SPD.Size = new System.Drawing.Size(31, 21); + this.L_SPD.TabIndex = 500; + this.L_SPD.Text = "SpD:"; + this.L_SPD.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // L_SPE + // + this.L_SPE.Location = new System.Drawing.Point(73, 78); + this.L_SPE.Name = "L_SPE"; + this.L_SPE.Size = new System.Drawing.Size(31, 21); + this.L_SPE.TabIndex = 499; + this.L_SPE.Text = "Spe:"; + this.L_SPE.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // L_SPA + // + this.L_SPA.Location = new System.Drawing.Point(73, 16); + this.L_SPA.Name = "L_SPA"; + this.L_SPA.Size = new System.Drawing.Size(31, 21); + this.L_SPA.TabIndex = 498; + this.L_SPA.Text = "SpA:"; + this.L_SPA.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // NUD_IV2 + // + this.NUD_IV2.Location = new System.Drawing.Point(33, 80); + this.NUD_IV2.Maximum = new decimal(new int[] { + 31, + 0, + 0, + 0}); + this.NUD_IV2.Minimum = new decimal(new int[] { + 1, + 0, + 0, + -2147483648}); + this.NUD_IV2.Name = "NUD_IV2"; + this.NUD_IV2.Size = new System.Drawing.Size(34, 20); + this.NUD_IV2.TabIndex = 491; + this.NUD_IV2.Value = new decimal(new int[] { + 31, + 0, + 0, + 0}); + // + // NUD_IV1 + // + this.NUD_IV1.Location = new System.Drawing.Point(33, 49); + this.NUD_IV1.Maximum = new decimal(new int[] { + 31, + 0, + 0, + 0}); + this.NUD_IV1.Minimum = new decimal(new int[] { + 1, + 0, + 0, + -2147483648}); + this.NUD_IV1.Name = "NUD_IV1"; + this.NUD_IV1.Size = new System.Drawing.Size(34, 20); + this.NUD_IV1.TabIndex = 490; + this.NUD_IV1.Value = new decimal(new int[] { + 31, + 0, + 0, + 0}); + // + // NUD_IV0 + // + this.NUD_IV0.Location = new System.Drawing.Point(33, 18); + this.NUD_IV0.Maximum = new decimal(new int[] { + 31, + 0, + 0, + 0}); + this.NUD_IV0.Minimum = new decimal(new int[] { + 1, + 0, + 0, + -2147483648}); + this.NUD_IV0.Name = "NUD_IV0"; + this.NUD_IV0.Size = new System.Drawing.Size(34, 20); + this.NUD_IV0.TabIndex = 489; + this.NUD_IV0.Value = new decimal(new int[] { + 31, + 0, + 0, + 0}); + // + // L_ATK + // + this.L_ATK.Location = new System.Drawing.Point(7, 47); + this.L_ATK.Name = "L_ATK"; + this.L_ATK.Size = new System.Drawing.Size(26, 21); + this.L_ATK.TabIndex = 496; + this.L_ATK.Text = "Atk:"; + this.L_ATK.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // L_DEF + // + this.L_DEF.Location = new System.Drawing.Point(4, 78); + this.L_DEF.Name = "L_DEF"; + this.L_DEF.Size = new System.Drawing.Size(29, 21); + this.L_DEF.TabIndex = 497; + this.L_DEF.Text = "Def:"; + this.L_DEF.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // CB_Nature + // + this.CB_Nature.FormattingEnabled = true; + this.CB_Nature.Location = new System.Drawing.Point(65, 141); + this.CB_Nature.Name = "CB_Nature"; + this.CB_Nature.Size = new System.Drawing.Size(121, 21); + this.CB_Nature.TabIndex = 505; // // GB_Tweak // this.GB_Tweak.Controls.Add(this.CHK_RemoveShinyLock); + this.GB_Tweak.Controls.Add(this.CHK_AllowMega); this.GB_Tweak.Controls.Add(this.CHK_Item); this.GB_Tweak.Controls.Add(this.L_RandOpt); this.GB_Tweak.Controls.Add(this.CHK_BST); @@ -606,13 +620,33 @@ private void InitializeComponent() this.GB_Tweak.Controls.Add(this.CHK_G3); this.GB_Tweak.Controls.Add(this.CHK_G2); this.GB_Tweak.Controls.Add(this.CHK_G1); - this.GB_Tweak.Location = new System.Drawing.Point(7, 52); + this.GB_Tweak.Location = new System.Drawing.Point(5, 83); this.GB_Tweak.Name = "GB_Tweak"; - this.GB_Tweak.Size = new System.Drawing.Size(258, 113); - this.GB_Tweak.TabIndex = 509; + this.GB_Tweak.Size = new System.Drawing.Size(258, 129); + this.GB_Tweak.TabIndex = 513; this.GB_Tweak.TabStop = false; this.GB_Tweak.Text = "Extra Randomization Tweaks"; // + // CHK_RemoveShinyLock + // + this.CHK_RemoveShinyLock.AutoSize = true; + this.CHK_RemoveShinyLock.Location = new System.Drawing.Point(9, 109); + this.CHK_RemoveShinyLock.Name = "CHK_RemoveShinyLock"; + this.CHK_RemoveShinyLock.Size = new System.Drawing.Size(127, 17); + this.CHK_RemoveShinyLock.TabIndex = 297; + this.CHK_RemoveShinyLock.Text = "Remove Shiny Locks"; + this.CHK_RemoveShinyLock.UseVisualStyleBackColor = true; + // + // CHK_AllowMega + // + this.CHK_AllowMega.AutoSize = true; + this.CHK_AllowMega.Location = new System.Drawing.Point(9, 94); + this.CHK_AllowMega.Name = "CHK_AllowMega"; + this.CHK_AllowMega.Size = new System.Drawing.Size(155, 17); + this.CHK_AllowMega.TabIndex = 296; + this.CHK_AllowMega.Text = "Allow Random Mega Forms"; + this.CHK_AllowMega.UseVisualStyleBackColor = true; + // // CHK_Item // this.CHK_Item.AutoSize = true; @@ -621,7 +655,7 @@ private void InitializeComponent() this.CHK_Item.Location = new System.Drawing.Point(9, 79); this.CHK_Item.Name = "CHK_Item"; this.CHK_Item.Size = new System.Drawing.Size(119, 17); - this.CHK_Item.TabIndex = 296; + this.CHK_Item.TabIndex = 295; this.CHK_Item.Text = "Random Held Items"; this.CHK_Item.UseVisualStyleBackColor = true; // @@ -740,56 +774,21 @@ private void InitializeComponent() this.CHK_G1.Text = "Gen 1"; this.CHK_G1.UseVisualStyleBackColor = true; // - // NUD_LevelBoost + // B_ModifyLevel // - this.NUD_LevelBoost.DecimalPlaces = 2; - this.NUD_LevelBoost.Increment = new decimal(new int[] { - 5, - 0, - 0, - 131072}); - this.NUD_LevelBoost.Location = new System.Drawing.Point(140, 6); - this.NUD_LevelBoost.Maximum = new decimal(new int[] { - 3, - 0, - 0, - 0}); - this.NUD_LevelBoost.Name = "NUD_LevelBoost"; - this.NUD_LevelBoost.Size = new System.Drawing.Size(43, 20); - this.NUD_LevelBoost.TabIndex = 303; - this.NUD_LevelBoost.Value = new decimal(new int[] { - 1, - 0, - 0, - 0}); - // - // CHK_Level - // - this.CHK_Level.AutoSize = true; - this.CHK_Level.Checked = true; - this.CHK_Level.CheckState = System.Windows.Forms.CheckState.Checked; - this.CHK_Level.Location = new System.Drawing.Point(9, 7); - this.CHK_Level.Name = "CHK_Level"; - this.CHK_Level.Size = new System.Drawing.Size(130, 17); - this.CHK_Level.TabIndex = 302; - this.CHK_Level.Text = "Multiply PKM Level by"; - this.CHK_Level.UseVisualStyleBackColor = true; - // - // CHK_RemoveShinyLock - // - this.CHK_RemoveShinyLock.AutoSize = true; - this.CHK_RemoveShinyLock.Location = new System.Drawing.Point(9, 94); - this.CHK_RemoveShinyLock.Name = "CHK_RemoveShinyLock"; - this.CHK_RemoveShinyLock.Size = new System.Drawing.Size(127, 17); - this.CHK_RemoveShinyLock.TabIndex = 297; - this.CHK_RemoveShinyLock.Text = "Random Shiny Locks"; - this.CHK_RemoveShinyLock.UseVisualStyleBackColor = true; + this.B_ModifyLevel.Location = new System.Drawing.Point(189, 5); + this.B_ModifyLevel.Name = "B_ModifyLevel"; + this.B_ModifyLevel.Size = new System.Drawing.Size(70, 23); + this.B_ModifyLevel.TabIndex = 514; + this.B_ModifyLevel.Text = "× Current"; + this.B_ModifyLevel.UseVisualStyleBackColor = true; + this.B_ModifyLevel.Click += new System.EventHandler(this.ModifyLevels); // // GiftEditor6 // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(417, 304); + this.ClientSize = new System.Drawing.Size(417, 370); this.Controls.Add(this.tabControl1); this.Controls.Add(this.B_RandAll); this.Controls.Add(this.LB_Gifts); @@ -802,15 +801,8 @@ private void InitializeComponent() this.Name = "GiftEditor6"; this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; this.Text = "Gift Editor"; - ((System.ComponentModel.ISupportInitialize)(this.NUD_IV0)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_IV1)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_IV2)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_IV3)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_IV4)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_IV5)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.NUD_Level)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.NUD_Form)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_Nature)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.NUD_Ability)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.NUD_Gender)).EndInit(); this.tabControl1.ResumeLayout(false); @@ -818,9 +810,16 @@ private void InitializeComponent() this.tabPage1.PerformLayout(); this.tabPage2.ResumeLayout(false); this.tabPage2.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_LevelBoost)).EndInit(); + this.GB_EIVs.ResumeLayout(false); + ((System.ComponentModel.ISupportInitialize)(this.NUD_IV3)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_IV4)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_IV5)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_IV2)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_IV1)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_IV0)).EndInit(); this.GB_Tweak.ResumeLayout(false); this.GB_Tweak.PerformLayout(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_LevelBoost)).EndInit(); this.ResumeLayout(false); } @@ -832,26 +831,13 @@ private void InitializeComponent() private System.Windows.Forms.ListBox LB_Gifts; private System.Windows.Forms.ComboBox CB_Species; private System.Windows.Forms.ComboBox CB_HeldItem; - private System.Windows.Forms.NumericUpDown NUD_IV0; - private System.Windows.Forms.NumericUpDown NUD_IV1; - private System.Windows.Forms.NumericUpDown NUD_IV2; - private System.Windows.Forms.NumericUpDown NUD_IV3; - private System.Windows.Forms.NumericUpDown NUD_IV4; - private System.Windows.Forms.NumericUpDown NUD_IV5; private System.Windows.Forms.Label L_Species; private System.Windows.Forms.Label L_HeldItem; private System.Windows.Forms.NumericUpDown NUD_Level; private System.Windows.Forms.Label L_Level; private System.Windows.Forms.NumericUpDown NUD_Form; private System.Windows.Forms.Label L_Form; - private System.Windows.Forms.Label L_HP; - private System.Windows.Forms.Label L_ATK; - private System.Windows.Forms.Label L_DEF; - private System.Windows.Forms.Label L_SPA; - private System.Windows.Forms.Label L_SPE; - private System.Windows.Forms.Label L_SPD; private System.Windows.Forms.Label L_Nature; - private System.Windows.Forms.NumericUpDown NUD_Nature; private System.Windows.Forms.Label L_Ability; private System.Windows.Forms.NumericUpDown NUD_Ability; private System.Windows.Forms.Label L_Gender; @@ -862,9 +848,27 @@ private void InitializeComponent() private System.Windows.Forms.TabPage tabPage2; private System.Windows.Forms.NumericUpDown NUD_LevelBoost; private System.Windows.Forms.CheckBox CHK_Level; - private System.Windows.Forms.Label label1; - private System.Windows.Forms.Label L_Hint; + private System.Windows.Forms.CheckBox CHK_ReplaceMega; + private System.Windows.Forms.Label L_Mega; + private System.Windows.Forms.CheckBox CHK_ShinyLock; + private System.Windows.Forms.GroupBox GB_EIVs; + private System.Windows.Forms.Label L_HP; + private System.Windows.Forms.NumericUpDown NUD_IV3; + private System.Windows.Forms.NumericUpDown NUD_IV4; + private System.Windows.Forms.NumericUpDown NUD_IV5; + private System.Windows.Forms.Label L_SPD; + private System.Windows.Forms.Label L_SPE; + private System.Windows.Forms.Label L_SPA; + private System.Windows.Forms.NumericUpDown NUD_IV2; + private System.Windows.Forms.NumericUpDown NUD_IV1; + private System.Windows.Forms.NumericUpDown NUD_IV0; + private System.Windows.Forms.Label L_ATK; + private System.Windows.Forms.Label L_DEF; + private System.Windows.Forms.ComboBox CB_Nature; private System.Windows.Forms.GroupBox GB_Tweak; + private System.Windows.Forms.CheckBox CHK_RemoveShinyLock; + private System.Windows.Forms.CheckBox CHK_AllowMega; + private System.Windows.Forms.CheckBox CHK_Item; private System.Windows.Forms.Label L_RandOpt; private System.Windows.Forms.CheckBox CHK_BST; private System.Windows.Forms.CheckBox CHK_E; @@ -875,10 +879,6 @@ private void InitializeComponent() private System.Windows.Forms.CheckBox CHK_G3; private System.Windows.Forms.CheckBox CHK_G2; private System.Windows.Forms.CheckBox CHK_G1; - private System.Windows.Forms.CheckBox CHK_Mega; - private System.Windows.Forms.Label L_Mega; - private System.Windows.Forms.CheckBox CHK_Item; - private System.Windows.Forms.CheckBox CHK_ShinyLock; - private System.Windows.Forms.CheckBox CHK_RemoveShinyLock; + private System.Windows.Forms.Button B_ModifyLevel; } } \ No newline at end of file diff --git a/pk3DS/Subforms/Gen6/GiftEditor6.cs b/pk3DS/Subforms/Gen6/GiftEditor6.cs index 8344334..2c57d88 100644 --- a/pk3DS/Subforms/Gen6/GiftEditor6.cs +++ b/pk3DS/Subforms/Gen6/GiftEditor6.cs @@ -26,7 +26,7 @@ public GiftEditor6() MegaDictionary = megaDictionary; specieslist[0] = "---"; - abilitylist[0] = itemlist[0] = movelist[0] = "(None)"; // blank == -1 + itemlist[0] = "(None)"; // blank == -1 CB_Species.Items.Clear(); foreach (string s in specieslist) @@ -34,6 +34,8 @@ public GiftEditor6() CB_HeldItem.Items.Clear(); foreach (string s in itemlist) CB_HeldItem.Items.Add(s); + CB_Nature.Items.Add("Random"); + CB_Nature.Items.AddRange(natureslist.Take(25).ToArray()); loadData(); } @@ -54,6 +56,7 @@ public GiftEditor6() private readonly string[] movelist = Main.Config.getText(TextName.MoveNames); private readonly string[] itemlist = Main.Config.getText(TextName.ItemNames); private readonly string[] specieslist = Main.Config.getText(TextName.SpeciesNames); + private readonly string[] natureslist = Main.Config.getText(TextName.Natures); private readonly Dictionary MegaDictionary; private void B_Save_Click(object sender, EventArgs e) { @@ -132,11 +135,12 @@ private void loadEntry() { bool oldloaded = loaded; loaded = false; + CB_Species.SelectedIndex = GiftData[entry].Species; CB_HeldItem.SelectedIndex = GiftData[entry].HeldItem; NUD_Level.Value = GiftData[entry].Level; NUD_Form.Value = GiftData[entry].Form; - NUD_Nature.Value = GiftData[entry].Nature; + CB_Nature.SelectedIndex = GiftData[entry].Nature + 1; NUD_Ability.Value = GiftData[entry].Ability; NUD_Gender.Value = GiftData[entry].Gender; CHK_ShinyLock.Checked = GiftData[entry].ShinyLock; @@ -147,6 +151,10 @@ private void loadEntry() NUD_IV3.Value = GiftData[entry].IVs[3]; NUD_IV4.Value = GiftData[entry].IVs[4]; NUD_IV5.Value = GiftData[entry].IVs[5]; + + if (GiftData[entry].HeldItem < 0) + CB_HeldItem.SelectedIndex = 0; // no item = 0xFFFF, set to 0 (None) + loaded |= oldloaded; } private void saveEntry() @@ -155,7 +163,7 @@ private void saveEntry() GiftData[entry].HeldItem = CB_HeldItem.SelectedIndex; GiftData[entry].Level = (byte)NUD_Level.Value; GiftData[entry].Form = (byte)NUD_Form.Value; - GiftData[entry].Nature = (sbyte)NUD_Nature.Value; + GiftData[entry].Nature = (sbyte)(CB_Nature.SelectedIndex - 1); GiftData[entry].Ability = (sbyte)NUD_Ability.Value; GiftData[entry].Gender = (sbyte)NUD_Gender.Value; GiftData[entry].ShinyLock = CHK_ShinyLock.Checked; @@ -197,7 +205,7 @@ private void B_RandAll_Click(object sender, EventArgs e) if (MegaDictionary.Values.Any(z => z.Contains(CB_HeldItem.SelectedIndex))) // Mega Stone Gifts (Lucario, Latias/Latios) { - if (!CHK_Mega.Checked) + if (!CHK_ReplaceMega.Checked) continue; // skip Lucario, battle needs to Mega Evolve int[] items = GetRandomMega(out species); @@ -211,9 +219,16 @@ private void B_RandAll_Click(object sender, EventArgs e) CB_HeldItem.SelectedIndex = helditems[Util.rnd32() % helditems.Length]; } + if (CHK_AllowMega.Checked) + formrand.AllowMega = true; + CB_Species.SelectedIndex = species; NUD_Form.Value = formrand.GetRandomForme(species); NUD_Gender.Value = 0; // random + CB_Nature.SelectedIndex = 0; // random + + if (MegaDictionary.Values.Any(z => z.Contains(CB_HeldItem.SelectedIndex)) && NUD_Form.Value > 0) + NUD_Form.Value = 0; // don't allow Mega Stone Gifts to be form 1 if (CHK_RemoveShinyLock.Checked) CHK_ShinyLock.Checked = false; @@ -289,5 +304,17 @@ private void changeSpecies(object sender, EventArgs e) int index = LB_Gifts.SelectedIndex; LB_Gifts.Items[index] = index.ToString("00") + " - " + CB_Species.Text; } + + private void ModifyLevels(object sender, EventArgs e) + { + if (WinFormsUtil.Prompt(MessageBoxButtons.YesNo, "Modify all current Levels?", "Cannot undo.") != DialogResult.Yes) return; + + for (int i = 0; i < LB_Gifts.Items.Count; i++) + { + LB_Gifts.SelectedIndex = i; + NUD_Level.Value = Randomizer.getModifiedLevel((int)NUD_Level.Value, NUD_LevelBoost.Value); + } + WinFormsUtil.Alert("Modified all Levels according to specification!"); + } } } \ No newline at end of file diff --git a/pk3DS/Subforms/Gen6/StaticEncounterEditor6.Designer.cs b/pk3DS/Subforms/Gen6/StaticEncounterEditor6.Designer.cs index dac85c1..f53a3d6 100644 --- a/pk3DS/Subforms/Gen6/StaticEncounterEditor6.Designer.cs +++ b/pk3DS/Subforms/Gen6/StaticEncounterEditor6.Designer.cs @@ -31,28 +31,26 @@ private void InitializeComponent() this.B_Cancel = new System.Windows.Forms.Button(); this.B_Save = new System.Windows.Forms.Button(); this.LB_Encounters = new System.Windows.Forms.ListBox(); - this.CB_Species = new System.Windows.Forms.ComboBox(); - this.L_Species = new System.Windows.Forms.Label(); - this.NUD_Level = new System.Windows.Forms.NumericUpDown(); - this.L_Level = new System.Windows.Forms.Label(); - this.NUD_Form = new System.Windows.Forms.NumericUpDown(); - this.L_Form = new System.Windows.Forms.Label(); this.B_RandAll = new System.Windows.Forms.Button(); - this.L_HeldItem = new System.Windows.Forms.Label(); - this.CB_HeldItem = new System.Windows.Forms.ComboBox(); - this.NUD_Ability = new System.Windows.Forms.NumericUpDown(); - this.L_Ability = new System.Windows.Forms.Label(); - this.NUD_Gender = new System.Windows.Forms.NumericUpDown(); - this.L_Gender = new System.Windows.Forms.Label(); - this.CHK_3IV = new System.Windows.Forms.CheckBox(); - this.CHK_NoShiny = new System.Windows.Forms.CheckBox(); - this.CHK_3IV_2 = new System.Windows.Forms.CheckBox(); - this.L_Hint = new System.Windows.Forms.Label(); this.tabControl1 = new System.Windows.Forms.TabControl(); this.tabPage1 = new System.Windows.Forms.TabPage(); - this.label1 = new System.Windows.Forms.Label(); + this.CHK_ShinyLock = new System.Windows.Forms.CheckBox(); + this.L_Gender = new System.Windows.Forms.Label(); + this.CB_Species = new System.Windows.Forms.ComboBox(); + this.NUD_Gender = new System.Windows.Forms.NumericUpDown(); + this.NUD_Ability = new System.Windows.Forms.NumericUpDown(); + this.L_Ability = new System.Windows.Forms.Label(); + this.L_Species = new System.Windows.Forms.Label(); + this.L_HeldItem = new System.Windows.Forms.Label(); + this.NUD_Level = new System.Windows.Forms.NumericUpDown(); + this.L_Level = new System.Windows.Forms.Label(); + this.L_Form = new System.Windows.Forms.Label(); + this.CB_HeldItem = new System.Windows.Forms.ComboBox(); + this.NUD_Form = new System.Windows.Forms.NumericUpDown(); this.tabPage2 = new System.Windows.Forms.TabPage(); + this.B_ModifyLevel = new System.Windows.Forms.Button(); this.GB_Tweak = new System.Windows.Forms.GroupBox(); + this.CHK_RemoveShinyLock = new System.Windows.Forms.CheckBox(); this.CHK_AllowMega = new System.Windows.Forms.CheckBox(); this.CHK_Item = new System.Windows.Forms.CheckBox(); this.L_RandOpt = new System.Windows.Forms.Label(); @@ -67,13 +65,13 @@ private void InitializeComponent() this.CHK_G1 = new System.Windows.Forms.CheckBox(); this.NUD_LevelBoost = new System.Windows.Forms.NumericUpDown(); this.CHK_Level = new System.Windows.Forms.CheckBox(); - this.CHK_RemoveShinyLock = new System.Windows.Forms.CheckBox(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_Level)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_Form)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_Ability)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_Gender)).BeginInit(); + this.CHK_IV3 = new System.Windows.Forms.CheckBox(); this.tabControl1.SuspendLayout(); this.tabPage1.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_Gender)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_Ability)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_Level)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_Form)).BeginInit(); this.tabPage2.SuspendLayout(); this.GB_Tweak.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.NUD_LevelBoost)).BeginInit(); @@ -82,7 +80,7 @@ private void InitializeComponent() // B_Cancel // this.B_Cancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); - this.B_Cancel.Location = new System.Drawing.Point(261, 296); + this.B_Cancel.Location = new System.Drawing.Point(264, 338); this.B_Cancel.Name = "B_Cancel"; this.B_Cancel.Size = new System.Drawing.Size(70, 23); this.B_Cancel.TabIndex = 467; @@ -93,7 +91,7 @@ private void InitializeComponent() // B_Save // this.B_Save.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); - this.B_Save.Location = new System.Drawing.Point(332, 296); + this.B_Save.Location = new System.Drawing.Point(335, 338); this.B_Save.Name = "B_Save"; this.B_Save.Size = new System.Drawing.Size(70, 23); this.B_Save.TabIndex = 466; @@ -108,69 +106,14 @@ private void InitializeComponent() this.LB_Encounters.FormattingEnabled = true; this.LB_Encounters.Location = new System.Drawing.Point(12, 12); this.LB_Encounters.Name = "LB_Encounters"; - this.LB_Encounters.Size = new System.Drawing.Size(110, 303); + this.LB_Encounters.Size = new System.Drawing.Size(110, 342); this.LB_Encounters.TabIndex = 468; this.LB_Encounters.SelectedIndexChanged += new System.EventHandler(this.changeIndex); // - // CB_Species - // - this.CB_Species.FormattingEnabled = true; - this.CB_Species.Location = new System.Drawing.Point(106, 3); - this.CB_Species.Name = "CB_Species"; - this.CB_Species.Size = new System.Drawing.Size(121, 21); - this.CB_Species.TabIndex = 469; - this.CB_Species.SelectedIndexChanged += new System.EventHandler(this.changeSpecies); - // - // L_Species - // - this.L_Species.Location = new System.Drawing.Point(6, 3); - this.L_Species.Name = "L_Species"; - this.L_Species.Size = new System.Drawing.Size(94, 21); - this.L_Species.TabIndex = 477; - this.L_Species.Text = "Species:"; - this.L_Species.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // NUD_Level - // - this.NUD_Level.Location = new System.Drawing.Point(106, 57); - this.NUD_Level.Name = "NUD_Level"; - this.NUD_Level.Size = new System.Drawing.Size(41, 20); - this.NUD_Level.TabIndex = 479; - this.NUD_Level.Value = new decimal(new int[] { - 100, - 0, - 0, - 0}); - // - // L_Level - // - this.L_Level.Location = new System.Drawing.Point(9, 55); - this.L_Level.Name = "L_Level"; - this.L_Level.Size = new System.Drawing.Size(92, 21); - this.L_Level.TabIndex = 480; - this.L_Level.Text = "Level:"; - this.L_Level.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // NUD_Form - // - this.NUD_Form.Location = new System.Drawing.Point(193, 57); - this.NUD_Form.Name = "NUD_Form"; - this.NUD_Form.Size = new System.Drawing.Size(34, 20); - this.NUD_Form.TabIndex = 481; - // - // L_Form - // - this.L_Form.Location = new System.Drawing.Point(99, 55); - this.L_Form.Name = "L_Form"; - this.L_Form.Size = new System.Drawing.Size(94, 21); - this.L_Form.TabIndex = 482; - this.L_Form.Text = "Form:"; - this.L_Form.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // // B_RandAll // this.B_RandAll.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); - this.B_RandAll.Location = new System.Drawing.Point(178, 296); + this.B_RandAll.Location = new System.Drawing.Point(181, 338); this.B_RandAll.Name = "B_RandAll"; this.B_RandAll.Size = new System.Drawing.Size(83, 23); this.B_RandAll.TabIndex = 496; @@ -178,104 +121,6 @@ private void InitializeComponent() this.B_RandAll.UseVisualStyleBackColor = true; this.B_RandAll.Click += new System.EventHandler(this.B_RandAll_Click); // - // L_HeldItem - // - this.L_HeldItem.Location = new System.Drawing.Point(6, 29); - this.L_HeldItem.Name = "L_HeldItem"; - this.L_HeldItem.Size = new System.Drawing.Size(94, 21); - this.L_HeldItem.TabIndex = 478; - this.L_HeldItem.Text = "Held Item:"; - this.L_HeldItem.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // CB_HeldItem - // - this.CB_HeldItem.FormattingEnabled = true; - this.CB_HeldItem.Location = new System.Drawing.Point(106, 30); - this.CB_HeldItem.Name = "CB_HeldItem"; - this.CB_HeldItem.Size = new System.Drawing.Size(121, 21); - this.CB_HeldItem.TabIndex = 470; - // - // NUD_Ability - // - this.NUD_Ability.Location = new System.Drawing.Point(194, 82); - this.NUD_Ability.Maximum = new decimal(new int[] { - 3, - 0, - 0, - 0}); - this.NUD_Ability.Name = "NUD_Ability"; - this.NUD_Ability.Size = new System.Drawing.Size(34, 20); - this.NUD_Ability.TabIndex = 492; - // - // L_Ability - // - this.L_Ability.Location = new System.Drawing.Point(100, 80); - this.L_Ability.Name = "L_Ability"; - this.L_Ability.Size = new System.Drawing.Size(94, 21); - this.L_Ability.TabIndex = 493; - this.L_Ability.Text = "Ability:"; - this.L_Ability.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // NUD_Gender - // - this.NUD_Gender.Location = new System.Drawing.Point(194, 108); - this.NUD_Gender.Maximum = new decimal(new int[] { - 2, - 0, - 0, - 0}); - this.NUD_Gender.Name = "NUD_Gender"; - this.NUD_Gender.Size = new System.Drawing.Size(34, 20); - this.NUD_Gender.TabIndex = 494; - // - // L_Gender - // - this.L_Gender.Location = new System.Drawing.Point(100, 106); - this.L_Gender.Name = "L_Gender"; - this.L_Gender.Size = new System.Drawing.Size(94, 21); - this.L_Gender.TabIndex = 495; - this.L_Gender.Text = "Gender:"; - this.L_Gender.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // CHK_3IV - // - this.CHK_3IV.AutoSize = true; - this.CHK_3IV.Location = new System.Drawing.Point(9, 106); - this.CHK_3IV.Name = "CHK_3IV"; - this.CHK_3IV.Size = new System.Drawing.Size(42, 17); - this.CHK_3IV.TabIndex = 497; - this.CHK_3IV.Text = "3IV"; - this.CHK_3IV.UseVisualStyleBackColor = true; - // - // CHK_NoShiny - // - this.CHK_NoShiny.AutoSize = true; - this.CHK_NoShiny.Location = new System.Drawing.Point(9, 83); - this.CHK_NoShiny.Name = "CHK_NoShiny"; - this.CHK_NoShiny.Size = new System.Drawing.Size(79, 17); - this.CHK_NoShiny.TabIndex = 498; - this.CHK_NoShiny.Text = "Shiny Lock"; - this.CHK_NoShiny.UseVisualStyleBackColor = true; - // - // CHK_3IV_2 - // - this.CHK_3IV_2.AutoSize = true; - this.CHK_3IV_2.Location = new System.Drawing.Point(9, 129); - this.CHK_3IV_2.Name = "CHK_3IV_2"; - this.CHK_3IV_2.Size = new System.Drawing.Size(54, 17); - this.CHK_3IV_2.TabIndex = 499; - this.CHK_3IV_2.Text = "3IV_2"; - this.CHK_3IV_2.UseVisualStyleBackColor = true; - // - // L_Hint - // - this.L_Hint.AutoSize = true; - this.L_Hint.Location = new System.Drawing.Point(161, 148); - this.L_Hint.Name = "L_Hint"; - this.L_Hint.Size = new System.Drawing.Size(67, 52); - this.L_Hint.TabIndex = 500; - this.L_Hint.Text = "Gender:\r\n0: Random/-\r\n1: Male\r\n2: Female"; - // // tabControl1 // this.tabControl1.Controls.Add(this.tabPage1); @@ -283,58 +128,185 @@ private void InitializeComponent() this.tabControl1.Location = new System.Drawing.Point(128, 12); this.tabControl1.Name = "tabControl1"; this.tabControl1.SelectedIndex = 0; - this.tabControl1.Size = new System.Drawing.Size(280, 260); + this.tabControl1.Size = new System.Drawing.Size(277, 322); this.tabControl1.TabIndex = 501; // // tabPage1 // - this.tabPage1.Controls.Add(this.label1); - this.tabPage1.Controls.Add(this.L_Hint); - this.tabPage1.Controls.Add(this.CB_Species); - this.tabPage1.Controls.Add(this.NUD_Ability); - this.tabPage1.Controls.Add(this.CHK_3IV_2); - this.tabPage1.Controls.Add(this.CHK_NoShiny); - this.tabPage1.Controls.Add(this.L_Species); - this.tabPage1.Controls.Add(this.CHK_3IV); - this.tabPage1.Controls.Add(this.L_HeldItem); - this.tabPage1.Controls.Add(this.L_Level); + this.tabPage1.Controls.Add(this.CHK_IV3); + this.tabPage1.Controls.Add(this.CHK_ShinyLock); this.tabPage1.Controls.Add(this.L_Gender); - this.tabPage1.Controls.Add(this.CB_HeldItem); + this.tabPage1.Controls.Add(this.CB_Species); this.tabPage1.Controls.Add(this.NUD_Gender); - this.tabPage1.Controls.Add(this.NUD_Form); - this.tabPage1.Controls.Add(this.NUD_Level); + this.tabPage1.Controls.Add(this.NUD_Ability); this.tabPage1.Controls.Add(this.L_Ability); + this.tabPage1.Controls.Add(this.L_Species); + this.tabPage1.Controls.Add(this.L_HeldItem); + this.tabPage1.Controls.Add(this.NUD_Level); + this.tabPage1.Controls.Add(this.L_Level); this.tabPage1.Controls.Add(this.L_Form); + this.tabPage1.Controls.Add(this.CB_HeldItem); + this.tabPage1.Controls.Add(this.NUD_Form); this.tabPage1.Location = new System.Drawing.Point(4, 22); this.tabPage1.Name = "tabPage1"; this.tabPage1.Padding = new System.Windows.Forms.Padding(3); - this.tabPage1.Size = new System.Drawing.Size(272, 234); + this.tabPage1.Size = new System.Drawing.Size(269, 296); this.tabPage1.TabIndex = 0; this.tabPage1.Text = "Editor"; this.tabPage1.UseVisualStyleBackColor = true; // - // label1 + // CHK_ShinyLock // - this.label1.AutoSize = true; - this.label1.Location = new System.Drawing.Point(90, 148); - this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(59, 65); - this.label1.TabIndex = 502; - this.label1.Text = "Ability:\r\n0: Random\r\n1: Ability 0\r\n2: Ability 1\r\n3: Hidden"; + this.CHK_ShinyLock.AutoSize = true; + this.CHK_ShinyLock.Location = new System.Drawing.Point(65, 141); + this.CHK_ShinyLock.Name = "CHK_ShinyLock"; + this.CHK_ShinyLock.Size = new System.Drawing.Size(79, 17); + this.CHK_ShinyLock.TabIndex = 519; + this.CHK_ShinyLock.Text = "Shiny Lock"; + this.CHK_ShinyLock.UseVisualStyleBackColor = true; + // + // L_Gender + // + this.L_Gender.Location = new System.Drawing.Point(9, 96); + this.L_Gender.Name = "L_Gender"; + this.L_Gender.Size = new System.Drawing.Size(55, 23); + this.L_Gender.TabIndex = 518; + this.L_Gender.Text = "Gender:"; + this.L_Gender.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // CB_Species + // + this.CB_Species.FormattingEnabled = true; + this.CB_Species.Location = new System.Drawing.Point(65, 7); + this.CB_Species.Name = "CB_Species"; + this.CB_Species.Size = new System.Drawing.Size(121, 21); + this.CB_Species.TabIndex = 506; + // + // NUD_Gender + // + this.NUD_Gender.Location = new System.Drawing.Point(65, 96); + this.NUD_Gender.Maximum = new decimal(new int[] { + 2, + 0, + 0, + 0}); + this.NUD_Gender.Name = "NUD_Gender"; + this.NUD_Gender.Size = new System.Drawing.Size(41, 20); + this.NUD_Gender.TabIndex = 517; + // + // NUD_Ability + // + this.NUD_Ability.Location = new System.Drawing.Point(65, 74); + this.NUD_Ability.Maximum = new decimal(new int[] { + 3, + 0, + 0, + 0}); + this.NUD_Ability.Minimum = new decimal(new int[] { + 1, + 0, + 0, + -2147483648}); + this.NUD_Ability.Name = "NUD_Ability"; + this.NUD_Ability.Size = new System.Drawing.Size(41, 20); + this.NUD_Ability.TabIndex = 515; + // + // L_Ability + // + this.L_Ability.Location = new System.Drawing.Point(9, 71); + this.L_Ability.Name = "L_Ability"; + this.L_Ability.Size = new System.Drawing.Size(55, 23); + this.L_Ability.TabIndex = 516; + this.L_Ability.Text = "Ability:"; + this.L_Ability.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // L_Species + // + this.L_Species.Location = new System.Drawing.Point(9, 6); + this.L_Species.Name = "L_Species"; + this.L_Species.Size = new System.Drawing.Size(55, 23); + this.L_Species.TabIndex = 508; + this.L_Species.Text = "Species:"; + this.L_Species.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // L_HeldItem + // + this.L_HeldItem.Location = new System.Drawing.Point(9, 117); + this.L_HeldItem.Name = "L_HeldItem"; + this.L_HeldItem.Size = new System.Drawing.Size(55, 23); + this.L_HeldItem.TabIndex = 509; + this.L_HeldItem.Text = "Held Item:"; + this.L_HeldItem.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // NUD_Level + // + this.NUD_Level.Location = new System.Drawing.Point(65, 30); + this.NUD_Level.Name = "NUD_Level"; + this.NUD_Level.Size = new System.Drawing.Size(41, 20); + this.NUD_Level.TabIndex = 510; + this.NUD_Level.Value = new decimal(new int[] { + 100, + 0, + 0, + 0}); + // + // L_Level + // + this.L_Level.Location = new System.Drawing.Point(9, 27); + this.L_Level.Name = "L_Level"; + this.L_Level.Size = new System.Drawing.Size(55, 23); + this.L_Level.TabIndex = 511; + this.L_Level.Text = "Level:"; + this.L_Level.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // L_Form + // + this.L_Form.Location = new System.Drawing.Point(9, 49); + this.L_Form.Name = "L_Form"; + this.L_Form.Size = new System.Drawing.Size(55, 23); + this.L_Form.TabIndex = 513; + this.L_Form.Text = "Form:"; + this.L_Form.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // CB_HeldItem + // + this.CB_HeldItem.FormattingEnabled = true; + this.CB_HeldItem.Location = new System.Drawing.Point(65, 118); + this.CB_HeldItem.Name = "CB_HeldItem"; + this.CB_HeldItem.Size = new System.Drawing.Size(121, 21); + this.CB_HeldItem.TabIndex = 507; + // + // NUD_Form + // + this.NUD_Form.Location = new System.Drawing.Point(65, 52); + this.NUD_Form.Name = "NUD_Form"; + this.NUD_Form.Size = new System.Drawing.Size(41, 20); + this.NUD_Form.TabIndex = 512; // // tabPage2 // + this.tabPage2.Controls.Add(this.B_ModifyLevel); this.tabPage2.Controls.Add(this.GB_Tweak); this.tabPage2.Controls.Add(this.NUD_LevelBoost); this.tabPage2.Controls.Add(this.CHK_Level); this.tabPage2.Location = new System.Drawing.Point(4, 22); this.tabPage2.Name = "tabPage2"; this.tabPage2.Padding = new System.Windows.Forms.Padding(3); - this.tabPage2.Size = new System.Drawing.Size(272, 234); + this.tabPage2.Size = new System.Drawing.Size(269, 296); this.tabPage2.TabIndex = 1; this.tabPage2.Text = "Randomizer Options"; this.tabPage2.UseVisualStyleBackColor = true; // + // B_ModifyLevel + // + this.B_ModifyLevel.Location = new System.Drawing.Point(189, 5); + this.B_ModifyLevel.Name = "B_ModifyLevel"; + this.B_ModifyLevel.Size = new System.Drawing.Size(70, 23); + this.B_ModifyLevel.TabIndex = 502; + this.B_ModifyLevel.Text = "× Current"; + this.B_ModifyLevel.UseVisualStyleBackColor = true; + this.B_ModifyLevel.Click += new System.EventHandler(this.ModifyLevels); + // // GB_Tweak // this.GB_Tweak.Controls.Add(this.CHK_RemoveShinyLock); @@ -350,13 +322,23 @@ private void InitializeComponent() this.GB_Tweak.Controls.Add(this.CHK_G3); this.GB_Tweak.Controls.Add(this.CHK_G2); this.GB_Tweak.Controls.Add(this.CHK_G1); - this.GB_Tweak.Location = new System.Drawing.Point(7, 58); + this.GB_Tweak.Location = new System.Drawing.Point(5, 83); this.GB_Tweak.Name = "GB_Tweak"; this.GB_Tweak.Size = new System.Drawing.Size(258, 129); this.GB_Tweak.TabIndex = 509; this.GB_Tweak.TabStop = false; this.GB_Tweak.Text = "Extra Randomization Tweaks"; // + // CHK_RemoveShinyLock + // + this.CHK_RemoveShinyLock.AutoSize = true; + this.CHK_RemoveShinyLock.Location = new System.Drawing.Point(9, 109); + this.CHK_RemoveShinyLock.Name = "CHK_RemoveShinyLock"; + this.CHK_RemoveShinyLock.Size = new System.Drawing.Size(127, 17); + this.CHK_RemoveShinyLock.TabIndex = 297; + this.CHK_RemoveShinyLock.Text = "Remove Shiny Locks"; + this.CHK_RemoveShinyLock.UseVisualStyleBackColor = true; + // // CHK_AllowMega // this.CHK_AllowMega.AutoSize = true; @@ -522,28 +504,28 @@ private void InitializeComponent() this.CHK_Level.AutoSize = true; this.CHK_Level.Checked = true; this.CHK_Level.CheckState = System.Windows.Forms.CheckState.Checked; - this.CHK_Level.Location = new System.Drawing.Point(8, 7); + this.CHK_Level.Location = new System.Drawing.Point(9, 7); this.CHK_Level.Name = "CHK_Level"; this.CHK_Level.Size = new System.Drawing.Size(130, 17); this.CHK_Level.TabIndex = 302; this.CHK_Level.Text = "Multiply PKM Level by"; this.CHK_Level.UseVisualStyleBackColor = true; // - // CHK_RemoveShinyLock + // CHK_IV3 // - this.CHK_RemoveShinyLock.AutoSize = true; - this.CHK_RemoveShinyLock.Location = new System.Drawing.Point(9, 109); - this.CHK_RemoveShinyLock.Name = "CHK_RemoveShinyLock"; - this.CHK_RemoveShinyLock.Size = new System.Drawing.Size(127, 17); - this.CHK_RemoveShinyLock.TabIndex = 297; - this.CHK_RemoveShinyLock.Text = "Remove Shiny Locks"; - this.CHK_RemoveShinyLock.UseVisualStyleBackColor = true; + this.CHK_IV3.AutoSize = true; + this.CHK_IV3.Location = new System.Drawing.Point(65, 156); + this.CHK_IV3.Name = "CHK_IV3"; + this.CHK_IV3.Size = new System.Drawing.Size(42, 17); + this.CHK_IV3.TabIndex = 522; + this.CHK_IV3.Text = "3IV"; + this.CHK_IV3.UseVisualStyleBackColor = true; // // StaticEncounterEditor6 // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(414, 331); + this.ClientSize = new System.Drawing.Size(417, 370); this.Controls.Add(this.tabControl1); this.Controls.Add(this.B_RandAll); this.Controls.Add(this.LB_Encounters); @@ -556,13 +538,13 @@ private void InitializeComponent() this.Name = "StaticEncounterEditor6"; this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; this.Text = "Static Encounter Editor"; - ((System.ComponentModel.ISupportInitialize)(this.NUD_Level)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_Form)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_Ability)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.NUD_Gender)).EndInit(); this.tabControl1.ResumeLayout(false); this.tabPage1.ResumeLayout(false); this.tabPage1.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_Gender)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_Ability)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_Level)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.NUD_Form)).EndInit(); this.tabPage2.ResumeLayout(false); this.tabPage2.PerformLayout(); this.GB_Tweak.ResumeLayout(false); @@ -577,27 +559,10 @@ private void InitializeComponent() private System.Windows.Forms.Button B_Cancel; private System.Windows.Forms.Button B_Save; private System.Windows.Forms.ListBox LB_Encounters; - private System.Windows.Forms.ComboBox CB_Species; - private System.Windows.Forms.Label L_Species; - private System.Windows.Forms.NumericUpDown NUD_Level; - private System.Windows.Forms.Label L_Level; - private System.Windows.Forms.NumericUpDown NUD_Form; - private System.Windows.Forms.Label L_Form; private System.Windows.Forms.Button B_RandAll; - private System.Windows.Forms.Label L_Gender; - private System.Windows.Forms.NumericUpDown NUD_Gender; - private System.Windows.Forms.Label L_Ability; - private System.Windows.Forms.NumericUpDown NUD_Ability; - private System.Windows.Forms.ComboBox CB_HeldItem; - private System.Windows.Forms.Label L_HeldItem; - private System.Windows.Forms.CheckBox CHK_3IV; - private System.Windows.Forms.CheckBox CHK_NoShiny; - private System.Windows.Forms.CheckBox CHK_3IV_2; - private System.Windows.Forms.Label L_Hint; private System.Windows.Forms.TabControl tabControl1; private System.Windows.Forms.TabPage tabPage1; private System.Windows.Forms.TabPage tabPage2; - private System.Windows.Forms.Label label1; private System.Windows.Forms.NumericUpDown NUD_LevelBoost; private System.Windows.Forms.CheckBox CHK_Level; private System.Windows.Forms.GroupBox GB_Tweak; @@ -614,5 +579,20 @@ private void InitializeComponent() private System.Windows.Forms.CheckBox CHK_Item; private System.Windows.Forms.CheckBox CHK_AllowMega; private System.Windows.Forms.CheckBox CHK_RemoveShinyLock; + private System.Windows.Forms.CheckBox CHK_ShinyLock; + private System.Windows.Forms.Label L_Gender; + private System.Windows.Forms.ComboBox CB_Species; + private System.Windows.Forms.NumericUpDown NUD_Gender; + private System.Windows.Forms.NumericUpDown NUD_Ability; + private System.Windows.Forms.Label L_Ability; + private System.Windows.Forms.Label L_Species; + private System.Windows.Forms.Label L_HeldItem; + private System.Windows.Forms.NumericUpDown NUD_Level; + private System.Windows.Forms.Label L_Level; + private System.Windows.Forms.Label L_Form; + private System.Windows.Forms.ComboBox CB_HeldItem; + private System.Windows.Forms.NumericUpDown NUD_Form; + private System.Windows.Forms.Button B_ModifyLevel; + private System.Windows.Forms.CheckBox CHK_IV3; } } \ No newline at end of file diff --git a/pk3DS/Subforms/Gen6/StaticEncounterEditor6.cs b/pk3DS/Subforms/Gen6/StaticEncounterEditor6.cs index 27506aa..3fdde0b 100644 --- a/pk3DS/Subforms/Gen6/StaticEncounterEditor6.cs +++ b/pk3DS/Subforms/Gen6/StaticEncounterEditor6.cs @@ -92,16 +92,19 @@ private void loadEntry() { bool oldloaded = loaded; loaded = false; + CB_Species.SelectedIndex = EncounterData[entry].Species; CB_HeldItem.SelectedIndex = EncounterData[entry].HeldItem; NUD_Level.Value = EncounterData[entry].Level; NUD_Form.Value = EncounterData[entry].Form; NUD_Ability.Value = EncounterData[entry].Ability; NUD_Gender.Value = EncounterData[entry].Gender; + CHK_ShinyLock.Checked = EncounterData[entry].ShinyLock; + CHK_IV3.Checked = EncounterData[entry].IV3; + + if (EncounterData[entry].HeldItem < 0) + CB_HeldItem.SelectedIndex = 0; // no item = 0xFFFF, set to 0 (None) - CHK_NoShiny.Checked = EncounterData[entry].ShinyLock; - CHK_3IV.Checked = EncounterData[entry].IV3; - CHK_3IV_2.Checked = EncounterData[entry].IV3_1; loaded |= oldloaded; } private void saveEntry() @@ -112,10 +115,8 @@ private void saveEntry() EncounterData[entry].Form = (byte)NUD_Form.Value; EncounterData[entry].Ability = (sbyte)NUD_Ability.Value; EncounterData[entry].Gender = (sbyte)NUD_Gender.Value; - - EncounterData[entry].ShinyLock = CHK_NoShiny.Checked; - EncounterData[entry].IV3 = CHK_3IV.Checked; - EncounterData[entry].IV3_1 = CHK_3IV_2.Checked; + EncounterData[entry].ShinyLock = CHK_ShinyLock.Checked; + EncounterData[entry].IV3 = CHK_IV3.Checked; } private void B_RandAll_Click(object sender, EventArgs e) @@ -160,7 +161,7 @@ private void B_RandAll_Click(object sender, EventArgs e) NUD_Level.Value = Randomizer.getModifiedLevel((int)NUD_Level.Value, NUD_LevelBoost.Value); if (CHK_RemoveShinyLock.Checked) - CHK_NoShiny.Checked = false; + CHK_ShinyLock.Checked = false; } WinFormsUtil.Alert("Randomized all Static Encounters according to specification!"); } @@ -170,5 +171,17 @@ private void changeSpecies(object sender, EventArgs e) int index = LB_Encounters.SelectedIndex; LB_Encounters.Items[index] = index.ToString("00") + " - " + CB_Species.Text; } + + private void ModifyLevels(object sender, EventArgs e) + { + if (WinFormsUtil.Prompt(MessageBoxButtons.YesNo, "Modify all current Levels?", "Cannot undo.") != DialogResult.Yes) return; + + for (int i = 0; i < LB_Encounters.Items.Count; i++) + { + LB_Encounters.SelectedIndex = i; + NUD_Level.Value = Randomizer.getModifiedLevel((int)NUD_Level.Value, NUD_LevelBoost.Value); + } + WinFormsUtil.Alert("Modified all Levels according to specification!"); + } } } \ No newline at end of file diff --git a/pk3DS/Subforms/Gen7/StaticEncounterEditor7.cs b/pk3DS/Subforms/Gen7/StaticEncounterEditor7.cs index 94c8fc5..647d543 100644 --- a/pk3DS/Subforms/Gen7/StaticEncounterEditor7.cs +++ b/pk3DS/Subforms/Gen7/StaticEncounterEditor7.cs @@ -472,7 +472,6 @@ private void B_RandAll_Click(object sender, EventArgs e) var formrand = new FormRandomizer(Main.Config) { AllowMega = false, AllowAlolanForm = true }; var move = new LearnsetRandomizer(Main.Config, Main.Config.Learnsets); var items = Randomizer.getRandomItemList(); - var aurarand = aura; for (int i = 3; i < Gifts.Length; i++) // Skip Starters { From 67f67ac6e97cb54a379e3722a35eb5e5edfe3f72 Mon Sep 17 00:00:00 2001 From: sora10pls Date: Tue, 19 Dec 2017 22:09:13 -0500 Subject: [PATCH 2/2] Add static7 level boost button --- .../Gen7/StaticEncounterEditor7.Designer.cs | 83 +++++++++---------- pk3DS/Subforms/Gen7/StaticEncounterEditor7.cs | 41 ++++++++- 2 files changed, 76 insertions(+), 48 deletions(-) diff --git a/pk3DS/Subforms/Gen7/StaticEncounterEditor7.Designer.cs b/pk3DS/Subforms/Gen7/StaticEncounterEditor7.Designer.cs index 28c3737..06734a2 100644 --- a/pk3DS/Subforms/Gen7/StaticEncounterEditor7.Designer.cs +++ b/pk3DS/Subforms/Gen7/StaticEncounterEditor7.Designer.cs @@ -30,6 +30,8 @@ private void InitializeComponent() { this.TC_Tabs = new System.Windows.Forms.TabControl(); this.Tab_Gifts = new System.Windows.Forms.TabPage(); + this.CB_GNature = new System.Windows.Forms.ComboBox(); + this.L_GNature = new System.Windows.Forms.Label(); this.CHK_IsEgg = new System.Windows.Forms.CheckBox(); this.CHK_GIV3 = new System.Windows.Forms.CheckBox(); this.CB_SpecialMove = new System.Windows.Forms.ComboBox(); @@ -124,6 +126,7 @@ private void InitializeComponent() this.NUD_TLevel = new System.Windows.Forms.NumericUpDown(); this.LB_Trade = new System.Windows.Forms.ListBox(); this.Tab_Randomizer = new System.Windows.Forms.TabPage(); + this.B_ModifyLevel = new System.Windows.Forms.Button(); this.NUD_LevelBoost = new System.Windows.Forms.NumericUpDown(); this.CHK_Level = new System.Windows.Forms.CheckBox(); this.B_RandAll = new System.Windows.Forms.Button(); @@ -145,8 +148,6 @@ private void InitializeComponent() this.B_Starters = new System.Windows.Forms.Button(); this.B_Save = new System.Windows.Forms.Button(); this.B_Cancel = new System.Windows.Forms.Button(); - this.CB_GNature = new System.Windows.Forms.ComboBox(); - this.L_GNature = new System.Windows.Forms.Label(); this.TC_Tabs.SuspendLayout(); this.Tab_Gifts.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.NUD_GGender)).BeginInit(); @@ -228,6 +229,23 @@ private void InitializeComponent() this.Tab_Gifts.Text = "Gifts"; this.Tab_Gifts.UseVisualStyleBackColor = true; // + // CB_GNature + // + this.CB_GNature.FormattingEnabled = true; + this.CB_GNature.Location = new System.Drawing.Point(187, 119); + this.CB_GNature.Name = "CB_GNature"; + this.CB_GNature.Size = new System.Drawing.Size(121, 21); + this.CB_GNature.TabIndex = 511; + // + // L_GNature + // + this.L_GNature.Location = new System.Drawing.Point(131, 117); + this.L_GNature.Name = "L_GNature"; + this.L_GNature.Size = new System.Drawing.Size(55, 23); + this.L_GNature.TabIndex = 510; + this.L_GNature.Text = "Nature:"; + this.L_GNature.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // // CHK_IsEgg // this.CHK_IsEgg.AutoSize = true; @@ -285,11 +303,6 @@ private void InitializeComponent() this.NUD_GGender.Name = "NUD_GGender"; this.NUD_GGender.Size = new System.Drawing.Size(34, 20); this.NUD_GGender.TabIndex = 20; - this.NUD_GGender.Value = new decimal(new int[] { - 2, - 0, - 0, - 0}); // // CHK_G_Lock // @@ -374,11 +387,6 @@ private void InitializeComponent() // NUD_GLevel // this.NUD_GLevel.Location = new System.Drawing.Point(187, 30); - this.NUD_GLevel.Maximum = new decimal(new int[] { - 255, - 0, - 0, - 0}); this.NUD_GLevel.Name = "NUD_GLevel"; this.NUD_GLevel.Size = new System.Drawing.Size(48, 20); this.NUD_GLevel.TabIndex = 1; @@ -983,11 +991,6 @@ private void InitializeComponent() // NUD_ELevel // this.NUD_ELevel.Location = new System.Drawing.Point(187, 30); - this.NUD_ELevel.Maximum = new decimal(new int[] { - 255, - 0, - 0, - 0}); this.NUD_ELevel.Name = "NUD_ELevel"; this.NUD_ELevel.Size = new System.Drawing.Size(48, 20); this.NUD_ELevel.TabIndex = 9; @@ -1281,9 +1284,9 @@ private void InitializeComponent() this.L_TTID.AutoSize = true; this.L_TTID.Location = new System.Drawing.Point(252, 123); this.L_TTID.Name = "L_TTID"; - this.L_TTID.Size = new System.Drawing.Size(28, 13); + this.L_TTID.Size = new System.Drawing.Size(53, 13); this.L_TTID.TabIndex = 27; - this.L_TTID.Text = "TID:"; + this.L_TTID.Text = "Gen 7 ID:"; this.L_TTID.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; // // L_TID @@ -1386,11 +1389,6 @@ private void InitializeComponent() // NUD_TLevel // this.NUD_TLevel.Location = new System.Drawing.Point(187, 30); - this.NUD_TLevel.Maximum = new decimal(new int[] { - 255, - 0, - 0, - 0}); this.NUD_TLevel.Name = "NUD_TLevel"; this.NUD_TLevel.Size = new System.Drawing.Size(48, 20); this.NUD_TLevel.TabIndex = 17; @@ -1413,6 +1411,7 @@ private void InitializeComponent() // // Tab_Randomizer // + this.Tab_Randomizer.Controls.Add(this.B_ModifyLevel); this.Tab_Randomizer.Controls.Add(this.NUD_LevelBoost); this.Tab_Randomizer.Controls.Add(this.CHK_Level); this.Tab_Randomizer.Controls.Add(this.B_RandAll); @@ -1426,6 +1425,16 @@ private void InitializeComponent() this.Tab_Randomizer.Text = "Randomizer Options"; this.Tab_Randomizer.UseVisualStyleBackColor = true; // + // B_ModifyLevel + // + this.B_ModifyLevel.Location = new System.Drawing.Point(316, 111); + this.B_ModifyLevel.Name = "B_ModifyLevel"; + this.B_ModifyLevel.Size = new System.Drawing.Size(70, 23); + this.B_ModifyLevel.TabIndex = 512; + this.B_ModifyLevel.Text = "× Current"; + this.B_ModifyLevel.UseVisualStyleBackColor = true; + this.B_ModifyLevel.Click += new System.EventHandler(this.ModifyLevels); + // // NUD_LevelBoost // this.NUD_LevelBoost.DecimalPlaces = 2; @@ -1434,7 +1443,7 @@ private void InitializeComponent() 0, 0, 131072}); - this.NUD_LevelBoost.Location = new System.Drawing.Point(301, 110); + this.NUD_LevelBoost.Location = new System.Drawing.Point(267, 112); this.NUD_LevelBoost.Maximum = new decimal(new int[] { 3, 0, @@ -1454,7 +1463,7 @@ private void InitializeComponent() this.CHK_Level.AutoSize = true; this.CHK_Level.Checked = true; this.CHK_Level.CheckState = System.Windows.Forms.CheckState.Checked; - this.CHK_Level.Location = new System.Drawing.Point(169, 111); + this.CHK_Level.Location = new System.Drawing.Point(135, 113); this.CHK_Level.Name = "CHK_Level"; this.CHK_Level.Size = new System.Drawing.Size(130, 17); this.CHK_Level.TabIndex = 510; @@ -1487,9 +1496,9 @@ private void InitializeComponent() this.GB_Tweak.Controls.Add(this.CHK_G3); this.GB_Tweak.Controls.Add(this.CHK_G2); this.GB_Tweak.Controls.Add(this.CHK_G1); - this.GB_Tweak.Location = new System.Drawing.Point(122, 136); + this.GB_Tweak.Location = new System.Drawing.Point(129, 135); this.GB_Tweak.Name = "GB_Tweak"; - this.GB_Tweak.Size = new System.Drawing.Size(258, 144); + this.GB_Tweak.Size = new System.Drawing.Size(258, 145); this.GB_Tweak.TabIndex = 508; this.GB_Tweak.TabStop = false; this.GB_Tweak.Text = "Extra Randomization Tweaks"; @@ -1683,23 +1692,6 @@ private void InitializeComponent() this.B_Cancel.UseVisualStyleBackColor = true; this.B_Cancel.Click += new System.EventHandler(this.B_Cancel_Click); // - // CB_GNature - // - this.CB_GNature.FormattingEnabled = true; - this.CB_GNature.Location = new System.Drawing.Point(187, 119); - this.CB_GNature.Name = "CB_GNature"; - this.CB_GNature.Size = new System.Drawing.Size(121, 21); - this.CB_GNature.TabIndex = 511; - // - // L_GNature - // - this.L_GNature.Location = new System.Drawing.Point(131, 117); - this.L_GNature.Name = "L_GNature"; - this.L_GNature.Size = new System.Drawing.Size(55, 23); - this.L_GNature.TabIndex = 510; - this.L_GNature.Text = "Nature:"; - this.L_GNature.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // // StaticEncounterEditor7 // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); @@ -1877,5 +1869,6 @@ private void InitializeComponent() private System.Windows.Forms.CheckBox CHK_GIV3; private System.Windows.Forms.ComboBox CB_GNature; private System.Windows.Forms.Label L_GNature; + private System.Windows.Forms.Button B_ModifyLevel; } } \ No newline at end of file diff --git a/pk3DS/Subforms/Gen7/StaticEncounterEditor7.cs b/pk3DS/Subforms/Gen7/StaticEncounterEditor7.cs index 647d543..33c7e2e 100644 --- a/pk3DS/Subforms/Gen7/StaticEncounterEditor7.cs +++ b/pk3DS/Subforms/Gen7/StaticEncounterEditor7.cs @@ -448,10 +448,11 @@ private void B_Starters_Click(object sender, EventArgs e) if (CHK_Item.Checked) t.HeldItem = items[Util.rnd32() % items.Length]; + if (CHK_Level.Checked) + t.Level = Randomizer.getModifiedLevel(t.Level, NUD_LevelBoost.Value); + if (CHK_RemoveShinyLock.Checked) t.ShinyLock = false; // in case any user modifications locked the starters - - // no level boosting } getListBoxEntries(); @@ -479,6 +480,9 @@ private void B_RandAll_Click(object sender, EventArgs e) t.Species = specrand.GetRandomSpecies(t.Species); t.Form = formrand.GetRandomForme(t.Species); + if (CHK_AllowMega.Checked) + formrand.AllowMega = true; + if (CHK_Item.Checked) t.HeldItem = items[Util.rnd32() % items.Length]; @@ -494,6 +498,9 @@ private void B_RandAll_Click(object sender, EventArgs e) t.Form = formrand.GetRandomForme(t.Species); t.RelearnMoves = move.GetCurrentMoves(t.Species, t.Form, t.Level, 4); + if (CHK_AllowMega.Checked) + formrand.AllowMega = true; + if (CHK_Item.Checked) t.HeldItem = items[Util.rnd32() % items.Length]; @@ -509,6 +516,9 @@ private void B_RandAll_Click(object sender, EventArgs e) t.Form = formrand.GetRandomForme(t.Species); t.TradeRequestSpecies = specrand.GetRandomSpecies(t.TradeRequestSpecies); + if (CHK_AllowMega.Checked) + formrand.AllowMega = true; + if (CHK_Item.Checked) t.HeldItem = items[Util.rnd32() % items.Length]; @@ -576,5 +586,30 @@ private void ExportEncounters() var s = Encounters.Select(z => z.GetSummary() + $" // {specieslist[z.Species]} @ ???"); Clipboard.SetText(string.Join(Environment.NewLine, g.Concat(s))); } + + private void ModifyLevels(object sender, EventArgs e) + { + if (WinFormsUtil.Prompt(MessageBoxButtons.YesNo, "Modify all current Levels?", "Cannot undo.") != DialogResult.Yes) return; + + // encounter + for (int i = 0; i < LB_Encounter.Items.Count; i++) + { + LB_Encounter.SelectedIndex = i; + NUD_ELevel.Value = Randomizer.getModifiedLevel((int)NUD_ELevel.Value, NUD_LevelBoost.Value); + } + // gift + for (int i = 0; i < LB_Gift.Items.Count; i++) + { + LB_Gift.SelectedIndex = i; + NUD_GLevel.Value = Randomizer.getModifiedLevel((int)NUD_GLevel.Value, NUD_LevelBoost.Value); + } + // trade + for (int i = 0; i < LB_Trade.Items.Count; i++) + { + LB_Trade.SelectedIndex = i; + NUD_TLevel.Value = Randomizer.getModifiedLevel((int)NUD_TLevel.Value, NUD_LevelBoost.Value); + } + WinFormsUtil.Alert("Modified all Levels according to specification!"); + } } -} +} \ No newline at end of file