From e7f7e3dc3f454b454558ad01c7acbbfeb0ec5f5d Mon Sep 17 00:00:00 2001 From: Kurt Date: Sun, 30 Dec 2018 17:33:31 -0800 Subject: [PATCH] Update encounter search Add version specific search or all compatible Add encounter type checkboxes (others are ignored) Only return distinct encounters (by reference) Refresh Checksum from generated iencounterable->pk before converting (to eventually be fixed in iencounterable rewrite maybe) Closes #2219 --- .../Subforms/SAV_Encounters.Designer.cs | 453 ++++++++++-------- PKHeX.WinForms/Subforms/SAV_Encounters.cs | 71 ++- 2 files changed, 299 insertions(+), 225 deletions(-) diff --git a/PKHeX.WinForms/Subforms/SAV_Encounters.Designer.cs b/PKHeX.WinForms/Subforms/SAV_Encounters.Designer.cs index cec865f6b..187c08dcc 100644 --- a/PKHeX.WinForms/Subforms/SAV_Encounters.Designer.cs +++ b/PKHeX.WinForms/Subforms/SAV_Encounters.Designer.cs @@ -123,6 +123,8 @@ this.TLP_Filters = new System.Windows.Forms.TableLayoutPanel(); this.FLP_Level = new System.Windows.Forms.FlowLayoutPanel(); this.RTB_Instructions = new System.Windows.Forms.RichTextBox(); + this.L_Version = new System.Windows.Forms.Label(); + this.CB_GameOrigin = new System.Windows.Forms.ComboBox(); ((System.ComponentModel.ISupportInitialize)(this.bpkx30)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.bpkx29)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.bpkx28)).BeginInit(); @@ -192,13 +194,12 @@ ((System.ComponentModel.ISupportInitialize)(this.bpkx63)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.bpkx62)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.bpkx61)).BeginInit(); - this.FLP_Egg.SuspendLayout(); this.TLP_Filters.SuspendLayout(); this.SuspendLayout(); - // + // // SCR_Box - // - this.SCR_Box.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + // + this.SCR_Box.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Right))); this.SCR_Box.LargeChange = 1; this.SCR_Box.Location = new System.Drawing.Point(256, 3); @@ -206,9 +207,9 @@ this.SCR_Box.Size = new System.Drawing.Size(24, 344); this.SCR_Box.TabIndex = 1; this.SCR_Box.Scroll += new System.Windows.Forms.ScrollEventHandler(this.UpdateScroll); - // + // // bpkx30 - // + // this.bpkx30.BackColor = System.Drawing.Color.Transparent; this.bpkx30.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx30.Location = new System.Drawing.Point(207, 126); @@ -217,9 +218,9 @@ this.bpkx30.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx30.TabIndex = 59; this.bpkx30.TabStop = false; - // + // // bpkx29 - // + // this.bpkx29.BackColor = System.Drawing.Color.Transparent; this.bpkx29.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx29.Location = new System.Drawing.Point(166, 126); @@ -228,9 +229,9 @@ this.bpkx29.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx29.TabIndex = 58; this.bpkx29.TabStop = false; - // + // // bpkx28 - // + // this.bpkx28.BackColor = System.Drawing.Color.Transparent; this.bpkx28.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx28.Location = new System.Drawing.Point(125, 126); @@ -239,9 +240,9 @@ this.bpkx28.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx28.TabIndex = 57; this.bpkx28.TabStop = false; - // + // // bpkx27 - // + // this.bpkx27.BackColor = System.Drawing.Color.Transparent; this.bpkx27.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx27.Location = new System.Drawing.Point(84, 126); @@ -250,9 +251,9 @@ this.bpkx27.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx27.TabIndex = 56; this.bpkx27.TabStop = false; - // + // // bpkx26 - // + // this.bpkx26.BackColor = System.Drawing.Color.Transparent; this.bpkx26.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx26.Location = new System.Drawing.Point(43, 126); @@ -261,9 +262,9 @@ this.bpkx26.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx26.TabIndex = 55; this.bpkx26.TabStop = false; - // + // // bpkx25 - // + // this.bpkx25.BackColor = System.Drawing.Color.Transparent; this.bpkx25.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx25.Location = new System.Drawing.Point(2, 126); @@ -272,9 +273,9 @@ this.bpkx25.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx25.TabIndex = 54; this.bpkx25.TabStop = false; - // + // // bpkx24 - // + // this.bpkx24.BackColor = System.Drawing.Color.Transparent; this.bpkx24.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx24.Location = new System.Drawing.Point(207, 95); @@ -283,9 +284,9 @@ this.bpkx24.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx24.TabIndex = 53; this.bpkx24.TabStop = false; - // + // // bpkx23 - // + // this.bpkx23.BackColor = System.Drawing.Color.Transparent; this.bpkx23.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx23.Location = new System.Drawing.Point(166, 95); @@ -294,9 +295,9 @@ this.bpkx23.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx23.TabIndex = 52; this.bpkx23.TabStop = false; - // + // // bpkx22 - // + // this.bpkx22.BackColor = System.Drawing.Color.Transparent; this.bpkx22.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx22.Location = new System.Drawing.Point(125, 95); @@ -305,9 +306,9 @@ this.bpkx22.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx22.TabIndex = 51; this.bpkx22.TabStop = false; - // + // // bpkx21 - // + // this.bpkx21.BackColor = System.Drawing.Color.Transparent; this.bpkx21.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx21.Location = new System.Drawing.Point(84, 95); @@ -316,9 +317,9 @@ this.bpkx21.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx21.TabIndex = 50; this.bpkx21.TabStop = false; - // + // // bpkx20 - // + // this.bpkx20.BackColor = System.Drawing.Color.Transparent; this.bpkx20.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx20.Location = new System.Drawing.Point(43, 95); @@ -327,9 +328,9 @@ this.bpkx20.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx20.TabIndex = 49; this.bpkx20.TabStop = false; - // + // // bpkx19 - // + // this.bpkx19.BackColor = System.Drawing.Color.Transparent; this.bpkx19.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx19.Location = new System.Drawing.Point(2, 95); @@ -338,9 +339,9 @@ this.bpkx19.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx19.TabIndex = 48; this.bpkx19.TabStop = false; - // + // // bpkx18 - // + // this.bpkx18.BackColor = System.Drawing.Color.Transparent; this.bpkx18.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx18.Location = new System.Drawing.Point(207, 64); @@ -349,9 +350,9 @@ this.bpkx18.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx18.TabIndex = 47; this.bpkx18.TabStop = false; - // + // // bpkx17 - // + // this.bpkx17.BackColor = System.Drawing.Color.Transparent; this.bpkx17.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx17.Location = new System.Drawing.Point(166, 64); @@ -360,9 +361,9 @@ this.bpkx17.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx17.TabIndex = 46; this.bpkx17.TabStop = false; - // + // // bpkx16 - // + // this.bpkx16.BackColor = System.Drawing.Color.Transparent; this.bpkx16.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx16.Location = new System.Drawing.Point(125, 64); @@ -371,9 +372,9 @@ this.bpkx16.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx16.TabIndex = 45; this.bpkx16.TabStop = false; - // + // // bpkx15 - // + // this.bpkx15.BackColor = System.Drawing.Color.Transparent; this.bpkx15.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx15.Location = new System.Drawing.Point(84, 64); @@ -382,9 +383,9 @@ this.bpkx15.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx15.TabIndex = 44; this.bpkx15.TabStop = false; - // + // // bpkx14 - // + // this.bpkx14.BackColor = System.Drawing.Color.Transparent; this.bpkx14.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx14.Location = new System.Drawing.Point(43, 64); @@ -393,9 +394,9 @@ this.bpkx14.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx14.TabIndex = 43; this.bpkx14.TabStop = false; - // + // // bpkx13 - // + // this.bpkx13.BackColor = System.Drawing.Color.Transparent; this.bpkx13.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx13.Location = new System.Drawing.Point(2, 64); @@ -404,9 +405,9 @@ this.bpkx13.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx13.TabIndex = 42; this.bpkx13.TabStop = false; - // + // // bpkx12 - // + // this.bpkx12.BackColor = System.Drawing.Color.Transparent; this.bpkx12.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx12.Location = new System.Drawing.Point(207, 33); @@ -415,9 +416,9 @@ this.bpkx12.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx12.TabIndex = 41; this.bpkx12.TabStop = false; - // + // // bpkx11 - // + // this.bpkx11.BackColor = System.Drawing.Color.Transparent; this.bpkx11.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx11.Location = new System.Drawing.Point(166, 33); @@ -426,9 +427,9 @@ this.bpkx11.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx11.TabIndex = 40; this.bpkx11.TabStop = false; - // + // // bpkx10 - // + // this.bpkx10.BackColor = System.Drawing.Color.Transparent; this.bpkx10.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx10.Location = new System.Drawing.Point(125, 33); @@ -437,9 +438,9 @@ this.bpkx10.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx10.TabIndex = 39; this.bpkx10.TabStop = false; - // + // // bpkx9 - // + // this.bpkx9.BackColor = System.Drawing.Color.Transparent; this.bpkx9.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx9.Location = new System.Drawing.Point(84, 33); @@ -448,9 +449,9 @@ this.bpkx9.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx9.TabIndex = 38; this.bpkx9.TabStop = false; - // + // // bpkx8 - // + // this.bpkx8.BackColor = System.Drawing.Color.Transparent; this.bpkx8.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx8.Location = new System.Drawing.Point(43, 33); @@ -459,9 +460,9 @@ this.bpkx8.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx8.TabIndex = 37; this.bpkx8.TabStop = false; - // + // // bpkx7 - // + // this.bpkx7.BackColor = System.Drawing.Color.Transparent; this.bpkx7.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx7.Location = new System.Drawing.Point(2, 33); @@ -470,9 +471,9 @@ this.bpkx7.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx7.TabIndex = 36; this.bpkx7.TabStop = false; - // + // // bpkx6 - // + // this.bpkx6.BackColor = System.Drawing.Color.Transparent; this.bpkx6.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx6.Location = new System.Drawing.Point(207, 2); @@ -481,9 +482,9 @@ this.bpkx6.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx6.TabIndex = 35; this.bpkx6.TabStop = false; - // + // // bpkx5 - // + // this.bpkx5.BackColor = System.Drawing.Color.Transparent; this.bpkx5.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx5.Location = new System.Drawing.Point(166, 2); @@ -492,9 +493,9 @@ this.bpkx5.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx5.TabIndex = 34; this.bpkx5.TabStop = false; - // + // // bpkx4 - // + // this.bpkx4.BackColor = System.Drawing.Color.Transparent; this.bpkx4.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx4.Location = new System.Drawing.Point(125, 2); @@ -503,9 +504,9 @@ this.bpkx4.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx4.TabIndex = 33; this.bpkx4.TabStop = false; - // + // // bpkx3 - // + // this.bpkx3.BackColor = System.Drawing.Color.Transparent; this.bpkx3.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx3.Location = new System.Drawing.Point(84, 2); @@ -514,9 +515,9 @@ this.bpkx3.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx3.TabIndex = 32; this.bpkx3.TabStop = false; - // + // // bpkx2 - // + // this.bpkx2.BackColor = System.Drawing.Color.Transparent; this.bpkx2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx2.Location = new System.Drawing.Point(43, 2); @@ -525,9 +526,9 @@ this.bpkx2.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx2.TabIndex = 31; this.bpkx2.TabStop = false; - // + // // bpkx1 - // + // this.bpkx1.BackColor = System.Drawing.Color.Transparent; this.bpkx1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx1.Location = new System.Drawing.Point(2, 2); @@ -536,9 +537,9 @@ this.bpkx1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx1.TabIndex = 30; this.bpkx1.TabStop = false; - // + // // bpkx60 - // + // this.bpkx60.BackColor = System.Drawing.Color.Transparent; this.bpkx60.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx60.Location = new System.Drawing.Point(207, 281); @@ -547,9 +548,9 @@ this.bpkx60.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx60.TabIndex = 59; this.bpkx60.TabStop = false; - // + // // bpkx59 - // + // this.bpkx59.BackColor = System.Drawing.Color.Transparent; this.bpkx59.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx59.Location = new System.Drawing.Point(166, 281); @@ -558,9 +559,9 @@ this.bpkx59.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx59.TabIndex = 58; this.bpkx59.TabStop = false; - // + // // bpkx58 - // + // this.bpkx58.BackColor = System.Drawing.Color.Transparent; this.bpkx58.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx58.Location = new System.Drawing.Point(125, 281); @@ -569,9 +570,9 @@ this.bpkx58.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx58.TabIndex = 57; this.bpkx58.TabStop = false; - // + // // bpkx57 - // + // this.bpkx57.BackColor = System.Drawing.Color.Transparent; this.bpkx57.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx57.Location = new System.Drawing.Point(84, 281); @@ -580,9 +581,9 @@ this.bpkx57.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx57.TabIndex = 56; this.bpkx57.TabStop = false; - // + // // bpkx56 - // + // this.bpkx56.BackColor = System.Drawing.Color.Transparent; this.bpkx56.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx56.Location = new System.Drawing.Point(43, 281); @@ -591,9 +592,9 @@ this.bpkx56.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx56.TabIndex = 55; this.bpkx56.TabStop = false; - // + // // bpkx55 - // + // this.bpkx55.BackColor = System.Drawing.Color.Transparent; this.bpkx55.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx55.Location = new System.Drawing.Point(2, 281); @@ -602,9 +603,9 @@ this.bpkx55.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx55.TabIndex = 54; this.bpkx55.TabStop = false; - // + // // bpkx54 - // + // this.bpkx54.BackColor = System.Drawing.Color.Transparent; this.bpkx54.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx54.Location = new System.Drawing.Point(207, 250); @@ -613,9 +614,9 @@ this.bpkx54.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx54.TabIndex = 53; this.bpkx54.TabStop = false; - // + // // bpkx53 - // + // this.bpkx53.BackColor = System.Drawing.Color.Transparent; this.bpkx53.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx53.Location = new System.Drawing.Point(166, 250); @@ -624,9 +625,9 @@ this.bpkx53.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx53.TabIndex = 52; this.bpkx53.TabStop = false; - // + // // bpkx52 - // + // this.bpkx52.BackColor = System.Drawing.Color.Transparent; this.bpkx52.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx52.Location = new System.Drawing.Point(125, 250); @@ -635,9 +636,9 @@ this.bpkx52.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx52.TabIndex = 51; this.bpkx52.TabStop = false; - // + // // bpkx51 - // + // this.bpkx51.BackColor = System.Drawing.Color.Transparent; this.bpkx51.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx51.Location = new System.Drawing.Point(84, 250); @@ -646,9 +647,9 @@ this.bpkx51.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx51.TabIndex = 50; this.bpkx51.TabStop = false; - // + // // bpkx50 - // + // this.bpkx50.BackColor = System.Drawing.Color.Transparent; this.bpkx50.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx50.Location = new System.Drawing.Point(43, 250); @@ -657,9 +658,9 @@ this.bpkx50.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx50.TabIndex = 49; this.bpkx50.TabStop = false; - // + // // bpkx49 - // + // this.bpkx49.BackColor = System.Drawing.Color.Transparent; this.bpkx49.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx49.Location = new System.Drawing.Point(2, 250); @@ -668,9 +669,9 @@ this.bpkx49.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx49.TabIndex = 48; this.bpkx49.TabStop = false; - // + // // bpkx48 - // + // this.bpkx48.BackColor = System.Drawing.Color.Transparent; this.bpkx48.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx48.Location = new System.Drawing.Point(207, 219); @@ -679,9 +680,9 @@ this.bpkx48.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx48.TabIndex = 47; this.bpkx48.TabStop = false; - // + // // bpkx47 - // + // this.bpkx47.BackColor = System.Drawing.Color.Transparent; this.bpkx47.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx47.Location = new System.Drawing.Point(166, 219); @@ -690,9 +691,9 @@ this.bpkx47.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx47.TabIndex = 46; this.bpkx47.TabStop = false; - // + // // bpkx46 - // + // this.bpkx46.BackColor = System.Drawing.Color.Transparent; this.bpkx46.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx46.Location = new System.Drawing.Point(125, 219); @@ -701,9 +702,9 @@ this.bpkx46.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx46.TabIndex = 45; this.bpkx46.TabStop = false; - // + // // bpkx45 - // + // this.bpkx45.BackColor = System.Drawing.Color.Transparent; this.bpkx45.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx45.Location = new System.Drawing.Point(84, 219); @@ -712,9 +713,9 @@ this.bpkx45.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx45.TabIndex = 44; this.bpkx45.TabStop = false; - // + // // bpkx44 - // + // this.bpkx44.BackColor = System.Drawing.Color.Transparent; this.bpkx44.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx44.Location = new System.Drawing.Point(43, 219); @@ -723,9 +724,9 @@ this.bpkx44.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx44.TabIndex = 43; this.bpkx44.TabStop = false; - // + // // bpkx43 - // + // this.bpkx43.BackColor = System.Drawing.Color.Transparent; this.bpkx43.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx43.Location = new System.Drawing.Point(2, 219); @@ -734,9 +735,9 @@ this.bpkx43.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx43.TabIndex = 42; this.bpkx43.TabStop = false; - // + // // bpkx42 - // + // this.bpkx42.BackColor = System.Drawing.Color.Transparent; this.bpkx42.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx42.Location = new System.Drawing.Point(207, 188); @@ -745,9 +746,9 @@ this.bpkx42.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx42.TabIndex = 41; this.bpkx42.TabStop = false; - // + // // bpkx41 - // + // this.bpkx41.BackColor = System.Drawing.Color.Transparent; this.bpkx41.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx41.Location = new System.Drawing.Point(166, 188); @@ -756,9 +757,9 @@ this.bpkx41.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx41.TabIndex = 40; this.bpkx41.TabStop = false; - // + // // bpkx40 - // + // this.bpkx40.BackColor = System.Drawing.Color.Transparent; this.bpkx40.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx40.Location = new System.Drawing.Point(125, 188); @@ -767,9 +768,9 @@ this.bpkx40.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx40.TabIndex = 39; this.bpkx40.TabStop = false; - // + // // bpkx39 - // + // this.bpkx39.BackColor = System.Drawing.Color.Transparent; this.bpkx39.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx39.Location = new System.Drawing.Point(84, 188); @@ -778,9 +779,9 @@ this.bpkx39.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx39.TabIndex = 38; this.bpkx39.TabStop = false; - // + // // bpkx38 - // + // this.bpkx38.BackColor = System.Drawing.Color.Transparent; this.bpkx38.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx38.Location = new System.Drawing.Point(43, 188); @@ -789,9 +790,9 @@ this.bpkx38.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx38.TabIndex = 37; this.bpkx38.TabStop = false; - // + // // bpkx37 - // + // this.bpkx37.BackColor = System.Drawing.Color.Transparent; this.bpkx37.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx37.Location = new System.Drawing.Point(2, 188); @@ -800,9 +801,9 @@ this.bpkx37.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx37.TabIndex = 36; this.bpkx37.TabStop = false; - // + // // bpkx36 - // + // this.bpkx36.BackColor = System.Drawing.Color.Transparent; this.bpkx36.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx36.Location = new System.Drawing.Point(207, 157); @@ -811,9 +812,9 @@ this.bpkx36.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx36.TabIndex = 35; this.bpkx36.TabStop = false; - // + // // bpkx35 - // + // this.bpkx35.BackColor = System.Drawing.Color.Transparent; this.bpkx35.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx35.Location = new System.Drawing.Point(166, 157); @@ -822,9 +823,9 @@ this.bpkx35.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx35.TabIndex = 34; this.bpkx35.TabStop = false; - // + // // bpkx34 - // + // this.bpkx34.BackColor = System.Drawing.Color.Transparent; this.bpkx34.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx34.Location = new System.Drawing.Point(125, 157); @@ -833,9 +834,9 @@ this.bpkx34.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx34.TabIndex = 33; this.bpkx34.TabStop = false; - // + // // bpkx33 - // + // this.bpkx33.BackColor = System.Drawing.Color.Transparent; this.bpkx33.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx33.Location = new System.Drawing.Point(84, 157); @@ -844,9 +845,9 @@ this.bpkx33.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx33.TabIndex = 32; this.bpkx33.TabStop = false; - // + // // bpkx32 - // + // this.bpkx32.BackColor = System.Drawing.Color.Transparent; this.bpkx32.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx32.Location = new System.Drawing.Point(43, 157); @@ -855,9 +856,9 @@ this.bpkx32.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx32.TabIndex = 31; this.bpkx32.TabStop = false; - // + // // bpkx31 - // + // this.bpkx31.BackColor = System.Drawing.Color.Transparent; this.bpkx31.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx31.Location = new System.Drawing.Point(2, 157); @@ -866,9 +867,9 @@ this.bpkx31.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx31.TabIndex = 30; this.bpkx31.TabStop = false; - // + // // menuStrip1 - // + // this.menuStrip1.BackColor = System.Drawing.Color.Transparent; this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.Menu_Close, @@ -878,17 +879,17 @@ this.menuStrip1.Size = new System.Drawing.Size(544, 24); this.menuStrip1.TabIndex = 65; this.menuStrip1.Text = "menuStrip1"; - // + // // Menu_Close - // + // this.Menu_Close.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { this.Menu_Exit}); this.Menu_Close.Name = "Menu_Close"; this.Menu_Close.Size = new System.Drawing.Size(37, 20); this.Menu_Close.Text = "File"; - // + // // Menu_Exit - // + // this.Menu_Exit.Image = global::PKHeX.WinForms.Properties.Resources.exit; this.Menu_Exit.Name = "Menu_Exit"; this.Menu_Exit.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.E))); @@ -896,36 +897,36 @@ this.Menu_Exit.Size = new System.Drawing.Size(96, 22); this.Menu_Exit.Text = "&Close"; this.Menu_Exit.Click += new System.EventHandler(this.Menu_Exit_Click); - // + // // Menu_Tools - // + // this.Menu_Tools.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { this.Menu_SearchSettings}); this.Menu_Tools.Name = "Menu_Tools"; this.Menu_Tools.Size = new System.Drawing.Size(47, 20); this.Menu_Tools.Text = "Tools"; this.Menu_Tools.Visible = false; - // + // // Menu_SearchSettings - // + // this.Menu_SearchSettings.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { this.Menu_SearchAdvanced}); this.Menu_SearchSettings.Image = global::PKHeX.WinForms.Properties.Resources.settings; this.Menu_SearchSettings.Name = "Menu_SearchSettings"; this.Menu_SearchSettings.Size = new System.Drawing.Size(154, 22); this.Menu_SearchSettings.Text = "Search Settings"; - // + // // Menu_SearchAdvanced - // + // this.Menu_SearchAdvanced.CheckOnClick = true; this.Menu_SearchAdvanced.Name = "Menu_SearchAdvanced"; this.Menu_SearchAdvanced.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.A))); this.Menu_SearchAdvanced.Size = new System.Drawing.Size(207, 22); this.Menu_SearchAdvanced.Text = "Advanced Search"; this.Menu_SearchAdvanced.Click += new System.EventHandler(this.Menu_SearchAdvanced_Click); - // + // // P_Results - // + // this.P_Results.BackColor = System.Drawing.SystemColors.ButtonHighlight; this.P_Results.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.P_Results.Controls.Add(this.PAN_Box); @@ -934,9 +935,9 @@ this.P_Results.Name = "P_Results"; this.P_Results.Size = new System.Drawing.Size(285, 352); this.P_Results.TabIndex = 66; - // + // // PAN_Box - // + // this.PAN_Box.BackgroundImage = global::PKHeX.WinForms.Properties.Resources.box_wp16xy; this.PAN_Box.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch; this.PAN_Box.Controls.Add(this.bpkx66); @@ -1009,9 +1010,9 @@ this.PAN_Box.Name = "PAN_Box"; this.PAN_Box.Size = new System.Drawing.Size(251, 346); this.PAN_Box.TabIndex = 63; - // + // // bpkx66 - // + // this.bpkx66.BackColor = System.Drawing.Color.Transparent; this.bpkx66.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx66.Location = new System.Drawing.Point(207, 312); @@ -1020,9 +1021,9 @@ this.bpkx66.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx66.TabIndex = 65; this.bpkx66.TabStop = false; - // + // // bpkx65 - // + // this.bpkx65.BackColor = System.Drawing.Color.Transparent; this.bpkx65.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx65.Location = new System.Drawing.Point(166, 312); @@ -1031,9 +1032,9 @@ this.bpkx65.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx65.TabIndex = 64; this.bpkx65.TabStop = false; - // + // // bpkx64 - // + // this.bpkx64.BackColor = System.Drawing.Color.Transparent; this.bpkx64.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx64.Location = new System.Drawing.Point(125, 312); @@ -1042,9 +1043,9 @@ this.bpkx64.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx64.TabIndex = 63; this.bpkx64.TabStop = false; - // + // // bpkx63 - // + // this.bpkx63.BackColor = System.Drawing.Color.Transparent; this.bpkx63.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx63.Location = new System.Drawing.Point(84, 312); @@ -1053,9 +1054,9 @@ this.bpkx63.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx63.TabIndex = 62; this.bpkx63.TabStop = false; - // + // // bpkx62 - // + // this.bpkx62.BackColor = System.Drawing.Color.Transparent; this.bpkx62.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx62.Location = new System.Drawing.Point(43, 312); @@ -1064,9 +1065,9 @@ this.bpkx62.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx62.TabIndex = 61; this.bpkx62.TabStop = false; - // + // // bpkx61 - // + // this.bpkx61.BackColor = System.Drawing.Color.Transparent; this.bpkx61.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.bpkx61.Location = new System.Drawing.Point(2, 312); @@ -1075,81 +1076,81 @@ this.bpkx61.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; this.bpkx61.TabIndex = 60; this.bpkx61.TabStop = false; - // + // // CB_Species - // + // this.CB_Species.Anchor = System.Windows.Forms.AnchorStyles.Left; this.CB_Species.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend; this.CB_Species.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; this.CB_Species.FormattingEnabled = true; - this.CB_Species.Location = new System.Drawing.Point(54, 17); + this.CB_Species.Location = new System.Drawing.Point(69, 17); this.CB_Species.Margin = new System.Windows.Forms.Padding(0); this.CB_Species.Name = "CB_Species"; this.CB_Species.Size = new System.Drawing.Size(122, 21); this.CB_Species.TabIndex = 67; - // + // // CB_Move4 - // + // this.CB_Move4.Anchor = System.Windows.Forms.AnchorStyles.Left; this.CB_Move4.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend; this.CB_Move4.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; this.CB_Move4.FormattingEnabled = true; - this.CB_Move4.Location = new System.Drawing.Point(54, 101); + this.CB_Move4.Location = new System.Drawing.Point(69, 101); this.CB_Move4.Margin = new System.Windows.Forms.Padding(0); this.CB_Move4.Name = "CB_Move4"; this.CB_Move4.Size = new System.Drawing.Size(122, 21); this.CB_Move4.TabIndex = 74; - // + // // CB_Move3 - // + // this.CB_Move3.Anchor = System.Windows.Forms.AnchorStyles.Left; this.CB_Move3.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend; this.CB_Move3.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; this.CB_Move3.FormattingEnabled = true; - this.CB_Move3.Location = new System.Drawing.Point(54, 80); + this.CB_Move3.Location = new System.Drawing.Point(69, 80); this.CB_Move3.Margin = new System.Windows.Forms.Padding(0); this.CB_Move3.Name = "CB_Move3"; this.CB_Move3.Size = new System.Drawing.Size(122, 21); this.CB_Move3.TabIndex = 73; - // + // // CB_Move2 - // + // this.CB_Move2.Anchor = System.Windows.Forms.AnchorStyles.Left; this.CB_Move2.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend; this.CB_Move2.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; this.CB_Move2.FormattingEnabled = true; - this.CB_Move2.Location = new System.Drawing.Point(54, 59); + this.CB_Move2.Location = new System.Drawing.Point(69, 59); this.CB_Move2.Margin = new System.Windows.Forms.Padding(0); this.CB_Move2.Name = "CB_Move2"; this.CB_Move2.Size = new System.Drawing.Size(122, 21); this.CB_Move2.TabIndex = 72; - // + // // CB_Move1 - // + // this.CB_Move1.Anchor = System.Windows.Forms.AnchorStyles.Left; this.CB_Move1.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend; this.CB_Move1.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems; this.CB_Move1.FormattingEnabled = true; - this.CB_Move1.Location = new System.Drawing.Point(54, 38); + this.CB_Move1.Location = new System.Drawing.Point(69, 38); this.CB_Move1.Margin = new System.Windows.Forms.Padding(0); this.CB_Move1.Name = "CB_Move1"; this.CB_Move1.Size = new System.Drawing.Size(122, 21); this.CB_Move1.TabIndex = 71; - // + // // Label_Species - // + // this.Label_Species.Anchor = System.Windows.Forms.AnchorStyles.Right; this.Label_Species.AutoSize = true; - this.Label_Species.Location = new System.Drawing.Point(3, 21); + this.Label_Species.Location = new System.Drawing.Point(18, 21); this.Label_Species.Margin = new System.Windows.Forms.Padding(3); this.Label_Species.Name = "Label_Species"; this.Label_Species.Size = new System.Drawing.Size(48, 13); this.Label_Species.TabIndex = 90; this.Label_Species.Text = "Species:"; this.Label_Species.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // + // // B_Search - // + // this.B_Search.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.B_Search.Location = new System.Drawing.Point(317, 355); this.B_Search.Name = "B_Search"; @@ -1158,57 +1159,57 @@ this.B_Search.Text = "Search!"; this.B_Search.UseVisualStyleBackColor = true; this.B_Search.Click += new System.EventHandler(this.B_Search_Click); - // + // // L_Move1 - // + // this.L_Move1.Anchor = System.Windows.Forms.AnchorStyles.Right; this.L_Move1.AutoSize = true; - this.L_Move1.Location = new System.Drawing.Point(5, 42); + this.L_Move1.Location = new System.Drawing.Point(20, 42); this.L_Move1.Margin = new System.Windows.Forms.Padding(3); this.L_Move1.Name = "L_Move1"; this.L_Move1.Size = new System.Drawing.Size(46, 13); this.L_Move1.TabIndex = 105; this.L_Move1.Text = "Move 1:"; this.L_Move1.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // + // // L_Move2 - // + // this.L_Move2.Anchor = System.Windows.Forms.AnchorStyles.Right; this.L_Move2.AutoSize = true; - this.L_Move2.Location = new System.Drawing.Point(5, 63); + this.L_Move2.Location = new System.Drawing.Point(20, 63); this.L_Move2.Margin = new System.Windows.Forms.Padding(3); this.L_Move2.Name = "L_Move2"; this.L_Move2.Size = new System.Drawing.Size(46, 13); this.L_Move2.TabIndex = 106; this.L_Move2.Text = "Move 2:"; this.L_Move2.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // + // // L_Move3 - // + // this.L_Move3.Anchor = System.Windows.Forms.AnchorStyles.Right; this.L_Move3.AutoSize = true; - this.L_Move3.Location = new System.Drawing.Point(5, 84); + this.L_Move3.Location = new System.Drawing.Point(20, 84); this.L_Move3.Margin = new System.Windows.Forms.Padding(3); this.L_Move3.Name = "L_Move3"; this.L_Move3.Size = new System.Drawing.Size(46, 13); this.L_Move3.TabIndex = 107; this.L_Move3.Text = "Move 3:"; this.L_Move3.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // + // // L_Move4 - // + // this.L_Move4.Anchor = System.Windows.Forms.AnchorStyles.Right; this.L_Move4.AutoSize = true; - this.L_Move4.Location = new System.Drawing.Point(5, 105); + this.L_Move4.Location = new System.Drawing.Point(20, 105); this.L_Move4.Margin = new System.Windows.Forms.Padding(3); this.L_Move4.Name = "L_Move4"; this.L_Move4.Size = new System.Drawing.Size(46, 13); this.L_Move4.TabIndex = 108; this.L_Move4.Text = "Move 4:"; this.L_Move4.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // + // // B_Reset - // + // this.B_Reset.Location = new System.Drawing.Point(223, 8); this.B_Reset.Name = "B_Reset"; this.B_Reset.Size = new System.Drawing.Size(75, 23); @@ -1216,18 +1217,18 @@ this.B_Reset.Text = "Reset Filters"; this.B_Reset.UseVisualStyleBackColor = true; this.B_Reset.Click += new System.EventHandler(this.ResetFilters); - // + // // L_Count - // + // this.L_Count.Location = new System.Drawing.Point(99, 18); this.L_Count.Name = "L_Count"; this.L_Count.Size = new System.Drawing.Size(83, 13); this.L_Count.TabIndex = 114; this.L_Count.Text = "Count: {0}"; this.L_Count.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // + // // L_Viewed - // + // this.L_Viewed.AutoSize = true; this.L_Viewed.Location = new System.Drawing.Point(9, 386); this.L_Viewed.Name = "L_Viewed"; @@ -1235,25 +1236,24 @@ this.L_Viewed.TabIndex = 117; this.L_Viewed.Text = "Last Viewed: {0}"; this.L_Viewed.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; - // + // // FLP_Egg - // + // this.FLP_Egg.Anchor = System.Windows.Forms.AnchorStyles.Left; this.FLP_Egg.AutoSize = true; - this.FLP_Egg.Controls.Add(this.CHK_IsEgg); - this.FLP_Egg.Location = new System.Drawing.Point(54, 0); + this.FLP_Egg.Location = new System.Drawing.Point(0, 8); this.FLP_Egg.Margin = new System.Windows.Forms.Padding(0); this.FLP_Egg.Name = "FLP_Egg"; - this.FLP_Egg.Size = new System.Drawing.Size(45, 17); + this.FLP_Egg.Size = new System.Drawing.Size(0, 0); this.FLP_Egg.TabIndex = 120; - // + // // CHK_IsEgg - // + // this.CHK_IsEgg.Anchor = System.Windows.Forms.AnchorStyles.Left; this.CHK_IsEgg.AutoSize = true; this.CHK_IsEgg.Checked = true; this.CHK_IsEgg.CheckState = System.Windows.Forms.CheckState.Indeterminate; - this.CHK_IsEgg.Location = new System.Drawing.Point(0, 0); + this.CHK_IsEgg.Location = new System.Drawing.Point(69, 0); this.CHK_IsEgg.Margin = new System.Windows.Forms.Padding(0); this.CHK_IsEgg.Name = "CHK_IsEgg"; this.CHK_IsEgg.Size = new System.Drawing.Size(45, 17); @@ -1262,10 +1262,10 @@ this.CHK_IsEgg.TextAlign = System.Drawing.ContentAlignment.MiddleRight; this.CHK_IsEgg.ThreeState = true; this.CHK_IsEgg.UseVisualStyleBackColor = true; - // + // // TLP_Filters - // - this.TLP_Filters.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + // + this.TLP_Filters.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Right))); this.TLP_Filters.AutoScroll = true; this.TLP_Filters.AutoScrollMargin = new System.Drawing.Size(3, 3); @@ -1273,7 +1273,6 @@ this.TLP_Filters.ColumnCount = 2; this.TLP_Filters.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle()); this.TLP_Filters.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle()); - this.TLP_Filters.Controls.Add(this.FLP_Egg, 1, 0); this.TLP_Filters.Controls.Add(this.Label_Species, 0, 1); this.TLP_Filters.Controls.Add(this.CB_Species, 1, 1); this.TLP_Filters.Controls.Add(this.FLP_Level, 1, 5); @@ -1285,9 +1284,13 @@ this.TLP_Filters.Controls.Add(this.CB_Move3, 1, 11); this.TLP_Filters.Controls.Add(this.L_Move4, 0, 12); this.TLP_Filters.Controls.Add(this.CB_Move4, 1, 12); + this.TLP_Filters.Controls.Add(this.CHK_IsEgg, 1, 0); + this.TLP_Filters.Controls.Add(this.CB_GameOrigin, 1, 16); + this.TLP_Filters.Controls.Add(this.FLP_Egg, 0, 0); + this.TLP_Filters.Controls.Add(this.L_Version, 0, 16); this.TLP_Filters.Location = new System.Drawing.Point(304, 16); this.TLP_Filters.Name = "TLP_Filters"; - this.TLP_Filters.RowCount = 17; + this.TLP_Filters.RowCount = 18; this.TLP_Filters.RowStyles.Add(new System.Windows.Forms.RowStyle()); this.TLP_Filters.RowStyles.Add(new System.Windows.Forms.RowStyle()); this.TLP_Filters.RowStyles.Add(new System.Windows.Forms.RowStyle()); @@ -1305,31 +1308,55 @@ this.TLP_Filters.RowStyles.Add(new System.Windows.Forms.RowStyle()); this.TLP_Filters.RowStyles.Add(new System.Windows.Forms.RowStyle()); this.TLP_Filters.RowStyles.Add(new System.Windows.Forms.RowStyle()); + this.TLP_Filters.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 20F)); this.TLP_Filters.Size = new System.Drawing.Size(228, 359); this.TLP_Filters.TabIndex = 118; - // + // // FLP_Level - // + // this.FLP_Level.Anchor = System.Windows.Forms.AnchorStyles.Left; this.FLP_Level.AutoSize = true; - this.FLP_Level.Location = new System.Drawing.Point(54, 38); + this.FLP_Level.Location = new System.Drawing.Point(69, 38); this.FLP_Level.Margin = new System.Windows.Forms.Padding(0); this.FLP_Level.Name = "FLP_Level"; this.FLP_Level.Size = new System.Drawing.Size(0, 0); this.FLP_Level.TabIndex = 119; - // + // // RTB_Instructions - // - this.RTB_Instructions.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + // + this.RTB_Instructions.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Right))); this.RTB_Instructions.Location = new System.Drawing.Point(63, 32); this.RTB_Instructions.Name = "RTB_Instructions"; this.RTB_Instructions.Size = new System.Drawing.Size(235, 352); this.RTB_Instructions.TabIndex = 119; this.RTB_Instructions.Text = ""; - // + // + // L_Version + // + this.L_Version.Anchor = System.Windows.Forms.AnchorStyles.Right; + this.L_Version.AutoSize = true; + this.L_Version.Location = new System.Drawing.Point(3, 126); + this.L_Version.Margin = new System.Windows.Forms.Padding(3); + this.L_Version.Name = "L_Version"; + this.L_Version.Size = new System.Drawing.Size(63, 13); + this.L_Version.TabIndex = 122; + this.L_Version.Text = "OT Version:"; + this.L_Version.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // CB_GameOrigin + // + this.CB_GameOrigin.Anchor = System.Windows.Forms.AnchorStyles.Left; + this.CB_GameOrigin.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; + this.CB_GameOrigin.FormattingEnabled = true; + this.CB_GameOrigin.Location = new System.Drawing.Point(69, 122); + this.CB_GameOrigin.Margin = new System.Windows.Forms.Padding(0); + this.CB_GameOrigin.Name = "CB_GameOrigin"; + this.CB_GameOrigin.Size = new System.Drawing.Size(122, 21); + this.CB_GameOrigin.TabIndex = 121; + // // SAV_Encounters - // + // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(544, 401); @@ -1420,8 +1447,6 @@ ((System.ComponentModel.ISupportInitialize)(this.bpkx63)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.bpkx62)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.bpkx61)).EndInit(); - this.FLP_Egg.ResumeLayout(false); - this.FLP_Egg.PerformLayout(); this.TLP_Filters.ResumeLayout(false); this.TLP_Filters.PerformLayout(); this.ResumeLayout(false); @@ -1525,5 +1550,7 @@ private System.Windows.Forms.FlowLayoutPanel FLP_Level; private System.Windows.Forms.RichTextBox RTB_Instructions; private System.Windows.Forms.ToolStripMenuItem Menu_SearchAdvanced; + private System.Windows.Forms.ComboBox CB_GameOrigin; + private System.Windows.Forms.Label L_Version; } } \ No newline at end of file diff --git a/PKHeX.WinForms/Subforms/SAV_Encounters.cs b/PKHeX.WinForms/Subforms/SAV_Encounters.cs index d369fe393..80ce1b884 100644 --- a/PKHeX.WinForms/Subforms/SAV_Encounters.cs +++ b/PKHeX.WinForms/Subforms/SAV_Encounters.cs @@ -5,6 +5,7 @@ using System; using System.Collections.Generic; using System.Drawing; using System.Linq; +using System.Runtime.CompilerServices; using System.Threading.Tasks; using System.Windows.Forms; using static PKHeX.Core.MessageStrings; @@ -22,7 +23,6 @@ namespace PKHeX.WinForms ToolStripMenuItem mnuView = new ToolStripMenuItem {Name = "mnuView", Text = "View"}; - WinFormsUtil.TranslateInterface(this, Main.CurrentLanguage); ContextMenuStrip mnu = new ContextMenuStrip(); mnu.Items.AddRange(new ToolStripItem[] { mnuView }); @@ -70,6 +70,10 @@ namespace PKHeX.WinForms foreach (PictureBox p in PKXBOXES) p.ContextMenuStrip = mnu; + WinFormsUtil.TranslateInterface(this, Main.CurrentLanguage); + + TLP_Filters.Controls.Add(TypeFilters = GetTypeFilters(), 2, TLP_Filters.RowCount - 1); + // Load Data L_Count.Text = "Ready..."; @@ -81,6 +85,34 @@ namespace PKHeX.WinForms CenterToParent(); } + private static FlowLayoutPanel GetTypeFilters() + { + var flp = new FlowLayoutPanel { Dock = DockStyle.Fill }; + var types = (EncounterOrder[])Enum.GetValues(typeof(EncounterOrder)); + var checks = types.Select(z => new CheckBox + { + Name = z.ToString(), + Text = z.ToString(), + AutoSize = true, + Checked = true, + Padding = Padding.Empty, + Margin = Padding.Empty, + }).ToArray(); + foreach (var chk in checks) + { + flp.Controls.Add(chk); + flp.SetFlowBreak(chk, true); + } + flp.AutoSize = true; + return flp; + } + + private EncounterOrder[] GetTypes() + { + return TypeFilters.Controls.OfType().Where(z => z.Checked).Select(z => z.Name) + .Select(z => (EncounterOrder)Enum.Parse(typeof(EncounterOrder), z)).ToArray(); + } + private readonly PictureBox[] PKXBOXES; private List Results; private int slotSelected = -1; // = null; @@ -88,7 +120,7 @@ namespace PKHeX.WinForms private const int RES_MAX = 66; private const int RES_MIN = 6; private readonly string Counter; - private const int MAXFORMAT = PKX.Generation; + private readonly FlowLayoutPanel TypeFilters; // Important Events private void ClickView(object sender, EventArgs e) @@ -107,7 +139,10 @@ namespace PKHeX.WinForms return; } - PKME_Tabs.PopulateFields(Results[index].ConvertToPKM(SAV), false); + var enc = Results[index]; + var pk = enc.ConvertToPKM(SAV); + pk.RefreshChecksum(); + PKME_Tabs.PopulateFields(pk, false); slotSelected = index; slotColor = Properties.Resources.slotView; FillPKXBoxes(SCR_Box.Value); @@ -117,6 +152,7 @@ namespace PKHeX.WinForms { // Set the Text CB_Species.InitializeBinding(); + CB_GameOrigin.InitializeBinding(); var Any = new ComboItem {Text = MsgAny, Value = -1}; @@ -134,6 +170,9 @@ namespace PKHeX.WinForms } } + var DS_Version = new List(GameInfo.VersionDataSource); + DS_Version.Insert(0, Any); CB_GameOrigin.DataSource = DS_Version; + // Trigger a Reset ResetFilters(null, null); } @@ -141,10 +180,12 @@ namespace PKHeX.WinForms private void ResetFilters(object sender, EventArgs e) { CB_Species.SelectedIndex = 0; - CB_Move1.SelectedIndex = CB_Move2.SelectedIndex = CB_Move3.SelectedIndex = CB_Move4.SelectedIndex = 0; + CB_GameOrigin.SelectedIndex = 0; RTB_Instructions.Clear(); + foreach (var chk in TypeFilters.Controls.OfType()) + chk.Checked = true; if (sender != null) System.Media.SystemSounds.Asterisk.Play(); @@ -159,22 +200,25 @@ namespace PKHeX.WinForms var pk = SAV.BlankPKM; var species = settings.Species <= 0 ? Enumerable.Range(1, SAV.MaxSpeciesID) : new[] { settings.Species }; - var results = species.SelectMany(z => GetEncounters(z, moves, pk)); + var versions = settings.GetVersions(SAV); + var results = species.SelectMany(z => GetEncounters(z, moves, pk, versions)); if (settings.SearchEgg != null) results = results.Where(z => z.EggEncounter == settings.SearchEgg); // return filtered results - return results; + var comparer = new ReferenceComparer(); + return results.Distinct(comparer); // only distinct objects } - private IEnumerable GetEncounters(int species, int[] moves, PKM pk) + private class ReferenceComparer : IEqualityComparer + { + public bool Equals(T x, T y) => RuntimeHelpers.GetHashCode(x).Equals(RuntimeHelpers.GetHashCode(y)); + public int GetHashCode(T obj) => RuntimeHelpers.GetHashCode(obj); + } + + private static IEnumerable GetEncounters(int species, int[] moves, PKM pk, GameVersion[] vers) { pk.Species = species; - - var parent = GameUtil.GetMetLocationVersionGroup(SAV.Version); - if (parent == GameVersion.Invalid) - parent = GameUtil.GetMetLocationVersionGroup(GameUtil.GetVersion(SAV.Generation)); - var vers = GameUtil.GameVersions.Where(z => parent.Contains(z)).ToArray(); return EncounterMovesetGenerator.GenerateEncounters(pk, moves, vers); } @@ -188,6 +232,7 @@ namespace PKHeX.WinForms Species = WinFormsUtil.GetIndex(CB_Species), BatchInstructions = RTB_Instructions.Lines, + Version = WinFormsUtil.GetIndex(CB_GameOrigin), }; settings.AddMove(WinFormsUtil.GetIndex(CB_Move1)); @@ -204,6 +249,7 @@ namespace PKHeX.WinForms private async void B_Search_Click(object sender, EventArgs e) { B_Search.Enabled = false; + EncounterMovesetGenerator.PriorityList = GetTypes(); var search = SearchDatabase(); var results = await Task.Run(() => search.ToList()).ConfigureAwait(true); @@ -214,6 +260,7 @@ namespace PKHeX.WinForms SetResults(results); // updates Count Label as well. System.Media.SystemSounds.Asterisk.Play(); B_Search.Enabled = true; + EncounterMovesetGenerator.ResetFilters(); } private void UpdateScroll(object sender, ScrollEventArgs e)