From ace2ab9e276f520f722c353ff4d523a963be3572 Mon Sep 17 00:00:00 2001 From: Yako Date: Wed, 11 Jun 2025 22:28:06 +0200 Subject: [PATCH 1/6] completely rework DVCalc (I am dead inside) --- DS_Map/DVCalculator/DVCalc.Designer.cs | 868 +++++++++++++++++++++++-- DS_Map/DVCalculator/DVCalc.cs | 695 ++++---------------- DS_Map/DVCalculator/DVCalculator.cs | 230 ++++--- DS_Map/DocTool.cs | 8 +- DS_Map/Main Window.cs | 9 +- 5 files changed, 1094 insertions(+), 716 deletions(-) diff --git a/DS_Map/DVCalculator/DVCalc.Designer.cs b/DS_Map/DVCalculator/DVCalc.Designer.cs index 310e014..1fb6d94 100644 --- a/DS_Map/DVCalculator/DVCalc.Designer.cs +++ b/DS_Map/DVCalculator/DVCalc.Designer.cs @@ -1,21 +1,14 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using System.Windows.Forms; - -namespace DSPRE +namespace DSPRE { partial class DVCalc { /// - /// Required designer variable. + /// Required designer variable. /// private System.ComponentModel.IContainer components = null; /// - /// Clean up any resources being used. + /// Clean up any resources being used. /// /// true if managed resources should be disposed; otherwise, false. protected override void Dispose(bool disposing) @@ -33,37 +26,832 @@ namespace DSPRE /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// + private void InitializeComponent() + { + this.panelPokeLabels = new System.Windows.Forms.Panel(); + this.pokeLabel6 = new System.Windows.Forms.Label(); + this.pokeLabel5 = new System.Windows.Forms.Label(); + this.pokeLabel4 = new System.Windows.Forms.Label(); + this.pokeLabel3 = new System.Windows.Forms.Label(); + this.pokeLabel2 = new System.Windows.Forms.Label(); + this.pokeLabel1 = new System.Windows.Forms.Label(); + this.labelPokeNames = new System.Windows.Forms.Label(); + this.comboAbility1 = new System.Windows.Forms.ComboBox(); + this.comboAbility2 = new System.Windows.Forms.ComboBox(); + this.comboAbility3 = new System.Windows.Forms.ComboBox(); + this.comboAbility4 = new System.Windows.Forms.ComboBox(); + this.comboAbility5 = new System.Windows.Forms.ComboBox(); + this.comboAbility6 = new System.Windows.Forms.ComboBox(); + this.labelAbilities = new System.Windows.Forms.Label(); + this.panelAbilities = new System.Windows.Forms.Panel(); + this.panelGenders = new System.Windows.Forms.Panel(); + this.comboGender1 = new System.Windows.Forms.ComboBox(); + this.comboGender2 = new System.Windows.Forms.ComboBox(); + this.labelGenders = new System.Windows.Forms.Label(); + this.comboGender3 = new System.Windows.Forms.ComboBox(); + this.comboGender4 = new System.Windows.Forms.ComboBox(); + this.comboGender5 = new System.Windows.Forms.ComboBox(); + this.comboGender6 = new System.Windows.Forms.ComboBox(); + this.panelDVs = new System.Windows.Forms.Panel(); + this.numericUpDownDV6 = new System.Windows.Forms.NumericUpDown(); + this.numericUpDownDV5 = new System.Windows.Forms.NumericUpDown(); + this.numericUpDownDV4 = new System.Windows.Forms.NumericUpDown(); + this.numericUpDownDV3 = new System.Windows.Forms.NumericUpDown(); + this.numericUpDownDV2 = new System.Windows.Forms.NumericUpDown(); + this.numericUpDownDV1 = new System.Windows.Forms.NumericUpDown(); + this.labelDVs = new System.Windows.Forms.Label(); + this.panelNaturesEdit = new System.Windows.Forms.Panel(); + this.buttonShowAll1 = new System.Windows.Forms.Button(); + this.buttonShowAll2 = new System.Windows.Forms.Button(); + this.buttonShowAll3 = new System.Windows.Forms.Button(); + this.buttonShowAll4 = new System.Windows.Forms.Button(); + this.buttonShowAll5 = new System.Windows.Forms.Button(); + this.buttonShowAll6 = new System.Windows.Forms.Button(); + this.buttonChange6 = new System.Windows.Forms.Button(); + this.buttonChange5 = new System.Windows.Forms.Button(); + this.buttonChange4 = new System.Windows.Forms.Button(); + this.buttonChange3 = new System.Windows.Forms.Button(); + this.buttonChange2 = new System.Windows.Forms.Button(); + this.buttonChange1 = new System.Windows.Forms.Button(); + this.labelNature6 = new System.Windows.Forms.Label(); + this.labelNature5 = new System.Windows.Forms.Label(); + this.labelNature4 = new System.Windows.Forms.Label(); + this.labelNature3 = new System.Windows.Forms.Label(); + this.labelNature2 = new System.Windows.Forms.Label(); + this.labelNature1 = new System.Windows.Forms.Label(); + this.labelNatures = new System.Windows.Forms.Label(); + this.panelTrainerInfo = new System.Windows.Forms.Panel(); + this.labelTrainerClass = new System.Windows.Forms.Label(); + this.labelTrainerName = new System.Windows.Forms.Label(); + this.panelTrainerGender = new System.Windows.Forms.Panel(); + this.labelTrainerGender = new System.Windows.Forms.Label(); + this.radioFemale = new System.Windows.Forms.RadioButton(); + this.radioMale = new System.Windows.Forms.RadioButton(); + this.labelTrainerInfo = new System.Windows.Forms.Label(); + this.panelPokeLabels.SuspendLayout(); + this.panelAbilities.SuspendLayout(); + this.panelGenders.SuspendLayout(); + this.panelDVs.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownDV6)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownDV5)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownDV4)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownDV3)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownDV2)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownDV1)).BeginInit(); + this.panelNaturesEdit.SuspendLayout(); + this.panelTrainerInfo.SuspendLayout(); + this.panelTrainerGender.SuspendLayout(); + this.SuspendLayout(); + // + // panelPokeLabels + // + this.panelPokeLabels.Controls.Add(this.pokeLabel6); + this.panelPokeLabels.Controls.Add(this.pokeLabel5); + this.panelPokeLabels.Controls.Add(this.pokeLabel4); + this.panelPokeLabels.Controls.Add(this.pokeLabel3); + this.panelPokeLabels.Controls.Add(this.pokeLabel2); + this.panelPokeLabels.Controls.Add(this.pokeLabel1); + this.panelPokeLabels.Controls.Add(this.labelPokeNames); + this.panelPokeLabels.Location = new System.Drawing.Point(12, 32); + this.panelPokeLabels.Name = "panelPokeLabels"; + this.panelPokeLabels.Size = new System.Drawing.Size(120, 284); + this.panelPokeLabels.TabIndex = 0; + // + // pokeLabel6 + // + this.pokeLabel6.AutoSize = true; + this.pokeLabel6.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.pokeLabel6.Location = new System.Drawing.Point(3, 245); + this.pokeLabel6.Name = "pokeLabel6"; + this.pokeLabel6.Size = new System.Drawing.Size(92, 20); + this.pokeLabel6.TabIndex = 5; + this.pokeLabel6.Text = "pokeLabel6"; + // + // pokeLabel5 + // + this.pokeLabel5.AutoSize = true; + this.pokeLabel5.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.pokeLabel5.Location = new System.Drawing.Point(3, 205); + this.pokeLabel5.Name = "pokeLabel5"; + this.pokeLabel5.Size = new System.Drawing.Size(92, 20); + this.pokeLabel5.TabIndex = 4; + this.pokeLabel5.Text = "pokeLabel5"; + // + // pokeLabel4 + // + this.pokeLabel4.AutoSize = true; + this.pokeLabel4.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.pokeLabel4.Location = new System.Drawing.Point(3, 165); + this.pokeLabel4.Name = "pokeLabel4"; + this.pokeLabel4.Size = new System.Drawing.Size(92, 20); + this.pokeLabel4.TabIndex = 3; + this.pokeLabel4.Text = "pokeLabel4"; + // + // pokeLabel3 + // + this.pokeLabel3.AutoSize = true; + this.pokeLabel3.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.pokeLabel3.Location = new System.Drawing.Point(3, 125); + this.pokeLabel3.Name = "pokeLabel3"; + this.pokeLabel3.Size = new System.Drawing.Size(92, 20); + this.pokeLabel3.TabIndex = 2; + this.pokeLabel3.Text = "pokeLabel3"; + // + // pokeLabel2 + // + this.pokeLabel2.AutoSize = true; + this.pokeLabel2.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.pokeLabel2.Location = new System.Drawing.Point(3, 85); + this.pokeLabel2.Name = "pokeLabel2"; + this.pokeLabel2.Size = new System.Drawing.Size(92, 20); + this.pokeLabel2.TabIndex = 1; + this.pokeLabel2.Text = "pokeLabel2"; + // + // pokeLabel1 + // + this.pokeLabel1.AutoSize = true; + this.pokeLabel1.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.pokeLabel1.Location = new System.Drawing.Point(3, 45); + this.pokeLabel1.Name = "pokeLabel1"; + this.pokeLabel1.Size = new System.Drawing.Size(92, 20); + this.pokeLabel1.TabIndex = 0; + this.pokeLabel1.Text = "pokeLabel1"; + // + // labelPokeNames + // + this.labelPokeNames.AutoSize = true; + this.labelPokeNames.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelPokeNames.Location = new System.Drawing.Point(3, 5); + this.labelPokeNames.Name = "labelPokeNames"; + this.labelPokeNames.Size = new System.Drawing.Size(111, 20); + this.labelPokeNames.TabIndex = 7; + this.labelPokeNames.Text = "Trainer Party"; + // + // comboAbility1 + // + this.comboAbility1.FormattingEnabled = true; + this.comboAbility1.Location = new System.Drawing.Point(20, 45); + this.comboAbility1.Name = "comboAbility1"; + this.comboAbility1.Size = new System.Drawing.Size(121, 21); + this.comboAbility1.TabIndex = 2; + this.comboAbility1.SelectedIndexChanged += new System.EventHandler(this.valueChanged); + // + // comboAbility2 + // + this.comboAbility2.FormattingEnabled = true; + this.comboAbility2.Location = new System.Drawing.Point(20, 85); + this.comboAbility2.Name = "comboAbility2"; + this.comboAbility2.Size = new System.Drawing.Size(121, 21); + this.comboAbility2.TabIndex = 2; + this.comboAbility2.SelectedIndexChanged += new System.EventHandler(this.valueChanged); + // + // comboAbility3 + // + this.comboAbility3.FormattingEnabled = true; + this.comboAbility3.Location = new System.Drawing.Point(20, 125); + this.comboAbility3.Name = "comboAbility3"; + this.comboAbility3.Size = new System.Drawing.Size(121, 21); + this.comboAbility3.TabIndex = 3; + this.comboAbility3.SelectedIndexChanged += new System.EventHandler(this.valueChanged); + // + // comboAbility4 + // + this.comboAbility4.FormattingEnabled = true; + this.comboAbility4.Location = new System.Drawing.Point(20, 165); + this.comboAbility4.Name = "comboAbility4"; + this.comboAbility4.Size = new System.Drawing.Size(121, 21); + this.comboAbility4.TabIndex = 4; + this.comboAbility4.SelectedIndexChanged += new System.EventHandler(this.valueChanged); + // + // comboAbility5 + // + this.comboAbility5.FormattingEnabled = true; + this.comboAbility5.Location = new System.Drawing.Point(20, 205); + this.comboAbility5.Name = "comboAbility5"; + this.comboAbility5.Size = new System.Drawing.Size(121, 21); + this.comboAbility5.TabIndex = 5; + this.comboAbility5.SelectedIndexChanged += new System.EventHandler(this.valueChanged); + // + // comboAbility6 + // + this.comboAbility6.FormattingEnabled = true; + this.comboAbility6.Location = new System.Drawing.Point(20, 245); + this.comboAbility6.Name = "comboAbility6"; + this.comboAbility6.Size = new System.Drawing.Size(121, 21); + this.comboAbility6.TabIndex = 6; + this.comboAbility6.SelectedIndexChanged += new System.EventHandler(this.valueChanged); + // + // labelAbilities + // + this.labelAbilities.AutoSize = true; + this.labelAbilities.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelAbilities.Location = new System.Drawing.Point(16, 5); + this.labelAbilities.Name = "labelAbilities"; + this.labelAbilities.Size = new System.Drawing.Size(68, 20); + this.labelAbilities.TabIndex = 8; + this.labelAbilities.Text = "Abilties"; + // + // panelAbilities + // + this.panelAbilities.Controls.Add(this.comboAbility5); + this.panelAbilities.Controls.Add(this.comboAbility6); + this.panelAbilities.Controls.Add(this.comboAbility4); + this.panelAbilities.Controls.Add(this.comboAbility3); + this.panelAbilities.Controls.Add(this.comboAbility2); + this.panelAbilities.Controls.Add(this.comboAbility1); + this.panelAbilities.Controls.Add(this.labelAbilities); + this.panelAbilities.Location = new System.Drawing.Point(139, 32); + this.panelAbilities.Name = "panelAbilities"; + this.panelAbilities.Size = new System.Drawing.Size(154, 284); + this.panelAbilities.TabIndex = 9; + // + // panelGenders + // + this.panelGenders.Controls.Add(this.comboGender1); + this.panelGenders.Controls.Add(this.comboGender2); + this.panelGenders.Controls.Add(this.labelGenders); + this.panelGenders.Controls.Add(this.comboGender3); + this.panelGenders.Controls.Add(this.comboGender4); + this.panelGenders.Controls.Add(this.comboGender5); + this.panelGenders.Controls.Add(this.comboGender6); + this.panelGenders.Location = new System.Drawing.Point(299, 32); + this.panelGenders.Name = "panelGenders"; + this.panelGenders.Size = new System.Drawing.Size(149, 284); + this.panelGenders.TabIndex = 11; + // + // comboGender1 + // + this.comboGender1.FormattingEnabled = true; + this.comboGender1.Location = new System.Drawing.Point(19, 45); + this.comboGender1.Name = "comboGender1"; + this.comboGender1.Size = new System.Drawing.Size(121, 21); + this.comboGender1.TabIndex = 5; + this.comboGender1.SelectedIndexChanged += new System.EventHandler(this.valueChanged); + // + // comboGender2 + // + this.comboGender2.FormattingEnabled = true; + this.comboGender2.Location = new System.Drawing.Point(19, 85); + this.comboGender2.Name = "comboGender2"; + this.comboGender2.Size = new System.Drawing.Size(121, 21); + this.comboGender2.TabIndex = 6; + this.comboGender2.SelectedIndexChanged += new System.EventHandler(this.valueChanged); + // + // labelGenders + // + this.labelGenders.AutoSize = true; + this.labelGenders.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelGenders.Location = new System.Drawing.Point(15, 5); + this.labelGenders.Name = "labelGenders"; + this.labelGenders.Size = new System.Drawing.Size(78, 20); + this.labelGenders.TabIndex = 10; + this.labelGenders.Text = "Genders"; + // + // comboGender3 + // + this.comboGender3.FormattingEnabled = true; + this.comboGender3.Location = new System.Drawing.Point(19, 125); + this.comboGender3.Name = "comboGender3"; + this.comboGender3.Size = new System.Drawing.Size(121, 21); + this.comboGender3.TabIndex = 4; + this.comboGender3.SelectedIndexChanged += new System.EventHandler(this.valueChanged); + // + // comboGender4 + // + this.comboGender4.FormattingEnabled = true; + this.comboGender4.Location = new System.Drawing.Point(19, 165); + this.comboGender4.Name = "comboGender4"; + this.comboGender4.Size = new System.Drawing.Size(121, 21); + this.comboGender4.TabIndex = 2; + this.comboGender4.SelectedIndexChanged += new System.EventHandler(this.valueChanged); + // + // comboGender5 + // + this.comboGender5.FormattingEnabled = true; + this.comboGender5.Location = new System.Drawing.Point(19, 205); + this.comboGender5.Name = "comboGender5"; + this.comboGender5.Size = new System.Drawing.Size(121, 21); + this.comboGender5.TabIndex = 3; + this.comboGender5.SelectedIndexChanged += new System.EventHandler(this.valueChanged); + // + // comboGender6 + // + this.comboGender6.FormattingEnabled = true; + this.comboGender6.Location = new System.Drawing.Point(19, 245); + this.comboGender6.Name = "comboGender6"; + this.comboGender6.Size = new System.Drawing.Size(121, 21); + this.comboGender6.TabIndex = 2; + this.comboGender6.SelectedIndexChanged += new System.EventHandler(this.valueChanged); + // + // panelDVs + // + this.panelDVs.Controls.Add(this.numericUpDownDV6); + this.panelDVs.Controls.Add(this.numericUpDownDV5); + this.panelDVs.Controls.Add(this.numericUpDownDV4); + this.panelDVs.Controls.Add(this.numericUpDownDV3); + this.panelDVs.Controls.Add(this.numericUpDownDV2); + this.panelDVs.Controls.Add(this.numericUpDownDV1); + this.panelDVs.Controls.Add(this.labelDVs); + this.panelDVs.Location = new System.Drawing.Point(454, 32); + this.panelDVs.Name = "panelDVs"; + this.panelDVs.Size = new System.Drawing.Size(69, 284); + this.panelDVs.TabIndex = 12; + // + // numericUpDownDV6 + // + this.numericUpDownDV6.Location = new System.Drawing.Point(3, 245); + this.numericUpDownDV6.Maximum = new decimal(new int[] { + 255, + 0, + 0, + 0}); + this.numericUpDownDV6.Name = "numericUpDownDV6"; + this.numericUpDownDV6.Size = new System.Drawing.Size(57, 20); + this.numericUpDownDV6.TabIndex = 5; + this.numericUpDownDV6.ValueChanged += new System.EventHandler(this.valueChanged); + // + // numericUpDownDV5 + // + this.numericUpDownDV5.Location = new System.Drawing.Point(3, 205); + this.numericUpDownDV5.Maximum = new decimal(new int[] { + 255, + 0, + 0, + 0}); + this.numericUpDownDV5.Name = "numericUpDownDV5"; + this.numericUpDownDV5.Size = new System.Drawing.Size(57, 20); + this.numericUpDownDV5.TabIndex = 4; + this.numericUpDownDV5.ValueChanged += new System.EventHandler(this.valueChanged); + // + // numericUpDownDV4 + // + this.numericUpDownDV4.Location = new System.Drawing.Point(3, 165); + this.numericUpDownDV4.Maximum = new decimal(new int[] { + 255, + 0, + 0, + 0}); + this.numericUpDownDV4.Name = "numericUpDownDV4"; + this.numericUpDownDV4.Size = new System.Drawing.Size(57, 20); + this.numericUpDownDV4.TabIndex = 3; + this.numericUpDownDV4.ValueChanged += new System.EventHandler(this.valueChanged); + // + // numericUpDownDV3 + // + this.numericUpDownDV3.Location = new System.Drawing.Point(3, 125); + this.numericUpDownDV3.Maximum = new decimal(new int[] { + 255, + 0, + 0, + 0}); + this.numericUpDownDV3.Name = "numericUpDownDV3"; + this.numericUpDownDV3.Size = new System.Drawing.Size(57, 20); + this.numericUpDownDV3.TabIndex = 2; + this.numericUpDownDV3.ValueChanged += new System.EventHandler(this.valueChanged); + // + // numericUpDownDV2 + // + this.numericUpDownDV2.Location = new System.Drawing.Point(3, 85); + this.numericUpDownDV2.Maximum = new decimal(new int[] { + 255, + 0, + 0, + 0}); + this.numericUpDownDV2.Name = "numericUpDownDV2"; + this.numericUpDownDV2.Size = new System.Drawing.Size(57, 20); + this.numericUpDownDV2.TabIndex = 1; + this.numericUpDownDV2.ValueChanged += new System.EventHandler(this.valueChanged); + // + // numericUpDownDV1 + // + this.numericUpDownDV1.Location = new System.Drawing.Point(3, 45); + this.numericUpDownDV1.Maximum = new decimal(new int[] { + 255, + 0, + 0, + 0}); + this.numericUpDownDV1.Name = "numericUpDownDV1"; + this.numericUpDownDV1.Size = new System.Drawing.Size(57, 20); + this.numericUpDownDV1.TabIndex = 0; + this.numericUpDownDV1.ValueChanged += new System.EventHandler(this.valueChanged); + // + // labelDVs + // + this.labelDVs.AutoSize = true; + this.labelDVs.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelDVs.Location = new System.Drawing.Point(3, 5); + this.labelDVs.Name = "labelDVs"; + this.labelDVs.Size = new System.Drawing.Size(43, 20); + this.labelDVs.TabIndex = 13; + this.labelDVs.Text = "DVs"; + // + // panelNaturesEdit + // + this.panelNaturesEdit.Controls.Add(this.buttonShowAll1); + this.panelNaturesEdit.Controls.Add(this.buttonShowAll2); + this.panelNaturesEdit.Controls.Add(this.buttonShowAll3); + this.panelNaturesEdit.Controls.Add(this.buttonShowAll4); + this.panelNaturesEdit.Controls.Add(this.buttonShowAll5); + this.panelNaturesEdit.Controls.Add(this.buttonShowAll6); + this.panelNaturesEdit.Controls.Add(this.buttonChange6); + this.panelNaturesEdit.Controls.Add(this.buttonChange5); + this.panelNaturesEdit.Controls.Add(this.buttonChange4); + this.panelNaturesEdit.Controls.Add(this.buttonChange3); + this.panelNaturesEdit.Controls.Add(this.buttonChange2); + this.panelNaturesEdit.Controls.Add(this.buttonChange1); + this.panelNaturesEdit.Controls.Add(this.labelNature6); + this.panelNaturesEdit.Controls.Add(this.labelNature5); + this.panelNaturesEdit.Controls.Add(this.labelNature4); + this.panelNaturesEdit.Controls.Add(this.labelNature3); + this.panelNaturesEdit.Controls.Add(this.labelNature2); + this.panelNaturesEdit.Controls.Add(this.labelNature1); + this.panelNaturesEdit.Controls.Add(this.labelNatures); + this.panelNaturesEdit.Location = new System.Drawing.Point(529, 32); + this.panelNaturesEdit.Name = "panelNaturesEdit"; + this.panelNaturesEdit.Size = new System.Drawing.Size(353, 284); + this.panelNaturesEdit.TabIndex = 13; + // + // buttonShowAll1 + // + this.buttonShowAll1.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.buttonShowAll1.Location = new System.Drawing.Point(252, 40); + this.buttonShowAll1.Name = "buttonShowAll1"; + this.buttonShowAll1.Size = new System.Drawing.Size(85, 30); + this.buttonShowAll1.TabIndex = 32; + this.buttonShowAll1.Text = "Show All"; + this.buttonShowAll1.UseVisualStyleBackColor = true; + this.buttonShowAll1.Click += new System.EventHandler(this.buttonShowAll_Click); + // + // buttonShowAll2 + // + this.buttonShowAll2.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.buttonShowAll2.Location = new System.Drawing.Point(252, 80); + this.buttonShowAll2.Name = "buttonShowAll2"; + this.buttonShowAll2.Size = new System.Drawing.Size(85, 30); + this.buttonShowAll2.TabIndex = 31; + this.buttonShowAll2.Text = "Show All"; + this.buttonShowAll2.UseVisualStyleBackColor = true; + this.buttonShowAll2.Click += new System.EventHandler(this.buttonShowAll_Click); + // + // buttonShowAll3 + // + this.buttonShowAll3.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.buttonShowAll3.Location = new System.Drawing.Point(252, 120); + this.buttonShowAll3.Name = "buttonShowAll3"; + this.buttonShowAll3.Size = new System.Drawing.Size(85, 30); + this.buttonShowAll3.TabIndex = 30; + this.buttonShowAll3.Text = "Show All"; + this.buttonShowAll3.UseVisualStyleBackColor = true; + this.buttonShowAll3.Click += new System.EventHandler(this.buttonShowAll_Click); + // + // buttonShowAll4 + // + this.buttonShowAll4.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.buttonShowAll4.Location = new System.Drawing.Point(252, 160); + this.buttonShowAll4.Name = "buttonShowAll4"; + this.buttonShowAll4.Size = new System.Drawing.Size(85, 30); + this.buttonShowAll4.TabIndex = 29; + this.buttonShowAll4.Text = "Show All"; + this.buttonShowAll4.UseVisualStyleBackColor = true; + this.buttonShowAll4.Click += new System.EventHandler(this.buttonShowAll_Click); + // + // buttonShowAll5 + // + this.buttonShowAll5.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.buttonShowAll5.Location = new System.Drawing.Point(252, 200); + this.buttonShowAll5.Name = "buttonShowAll5"; + this.buttonShowAll5.Size = new System.Drawing.Size(85, 30); + this.buttonShowAll5.TabIndex = 28; + this.buttonShowAll5.Text = "Show All"; + this.buttonShowAll5.UseVisualStyleBackColor = true; + this.buttonShowAll5.Click += new System.EventHandler(this.buttonShowAll_Click); + // + // buttonShowAll6 + // + this.buttonShowAll6.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.buttonShowAll6.Location = new System.Drawing.Point(252, 240); + this.buttonShowAll6.Name = "buttonShowAll6"; + this.buttonShowAll6.Size = new System.Drawing.Size(85, 30); + this.buttonShowAll6.TabIndex = 27; + this.buttonShowAll6.Text = "Show All"; + this.buttonShowAll6.UseVisualStyleBackColor = true; + this.buttonShowAll6.Click += new System.EventHandler(this.buttonShowAll_Click); + // + // buttonChange6 + // + this.buttonChange6.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.buttonChange6.Location = new System.Drawing.Point(160, 240); + this.buttonChange6.Name = "buttonChange6"; + this.buttonChange6.Size = new System.Drawing.Size(85, 30); + this.buttonChange6.TabIndex = 26; + this.buttonChange6.Text = "Change"; + this.buttonChange6.UseVisualStyleBackColor = true; + // + // buttonChange5 + // + this.buttonChange5.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.buttonChange5.Location = new System.Drawing.Point(160, 200); + this.buttonChange5.Name = "buttonChange5"; + this.buttonChange5.Size = new System.Drawing.Size(85, 30); + this.buttonChange5.TabIndex = 25; + this.buttonChange5.Text = "Change"; + this.buttonChange5.UseVisualStyleBackColor = true; + // + // buttonChange4 + // + this.buttonChange4.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.buttonChange4.Location = new System.Drawing.Point(160, 160); + this.buttonChange4.Name = "buttonChange4"; + this.buttonChange4.Size = new System.Drawing.Size(85, 30); + this.buttonChange4.TabIndex = 24; + this.buttonChange4.Text = "Change"; + this.buttonChange4.UseVisualStyleBackColor = true; + // + // buttonChange3 + // + this.buttonChange3.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.buttonChange3.Location = new System.Drawing.Point(160, 120); + this.buttonChange3.Name = "buttonChange3"; + this.buttonChange3.Size = new System.Drawing.Size(85, 30); + this.buttonChange3.TabIndex = 23; + this.buttonChange3.Text = "Change"; + this.buttonChange3.UseVisualStyleBackColor = true; + // + // buttonChange2 + // + this.buttonChange2.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.buttonChange2.Location = new System.Drawing.Point(160, 80); + this.buttonChange2.Name = "buttonChange2"; + this.buttonChange2.Size = new System.Drawing.Size(85, 30); + this.buttonChange2.TabIndex = 22; + this.buttonChange2.Text = "Change"; + this.buttonChange2.UseVisualStyleBackColor = true; + // + // buttonChange1 + // + this.buttonChange1.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.buttonChange1.Location = new System.Drawing.Point(160, 40); + this.buttonChange1.Name = "buttonChange1"; + this.buttonChange1.Size = new System.Drawing.Size(85, 30); + this.buttonChange1.TabIndex = 21; + this.buttonChange1.Text = "Change"; + this.buttonChange1.UseVisualStyleBackColor = true; + // + // labelNature6 + // + this.labelNature6.AutoSize = true; + this.labelNature6.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelNature6.Location = new System.Drawing.Point(3, 245); + this.labelNature6.Name = "labelNature6"; + this.labelNature6.Size = new System.Drawing.Size(66, 20); + this.labelNature6.TabIndex = 20; + this.labelNature6.Text = "Nature6"; + // + // labelNature5 + // + this.labelNature5.AutoSize = true; + this.labelNature5.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelNature5.Location = new System.Drawing.Point(3, 205); + this.labelNature5.Name = "labelNature5"; + this.labelNature5.Size = new System.Drawing.Size(66, 20); + this.labelNature5.TabIndex = 19; + this.labelNature5.Text = "Nature5"; + // + // labelNature4 + // + this.labelNature4.AutoSize = true; + this.labelNature4.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelNature4.Location = new System.Drawing.Point(3, 165); + this.labelNature4.Name = "labelNature4"; + this.labelNature4.Size = new System.Drawing.Size(66, 20); + this.labelNature4.TabIndex = 18; + this.labelNature4.Text = "Nature4"; + // + // labelNature3 + // + this.labelNature3.AutoSize = true; + this.labelNature3.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelNature3.Location = new System.Drawing.Point(3, 125); + this.labelNature3.Name = "labelNature3"; + this.labelNature3.Size = new System.Drawing.Size(66, 20); + this.labelNature3.TabIndex = 17; + this.labelNature3.Text = "Nature3"; + // + // labelNature2 + // + this.labelNature2.AutoSize = true; + this.labelNature2.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelNature2.Location = new System.Drawing.Point(3, 85); + this.labelNature2.Name = "labelNature2"; + this.labelNature2.Size = new System.Drawing.Size(66, 20); + this.labelNature2.TabIndex = 16; + this.labelNature2.Text = "Nature2"; + // + // labelNature1 + // + this.labelNature1.AutoSize = true; + this.labelNature1.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelNature1.Location = new System.Drawing.Point(3, 45); + this.labelNature1.Name = "labelNature1"; + this.labelNature1.Size = new System.Drawing.Size(66, 20); + this.labelNature1.TabIndex = 15; + this.labelNature1.Text = "Nature1"; + // + // labelNatures + // + this.labelNatures.AutoSize = true; + this.labelNatures.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelNatures.Location = new System.Drawing.Point(3, 5); + this.labelNatures.Name = "labelNatures"; + this.labelNatures.Size = new System.Drawing.Size(72, 20); + this.labelNatures.TabIndex = 14; + this.labelNatures.Text = "Natures"; + // + // panelTrainerInfo + // + this.panelTrainerInfo.Controls.Add(this.labelTrainerClass); + this.panelTrainerInfo.Controls.Add(this.labelTrainerName); + this.panelTrainerInfo.Controls.Add(this.panelTrainerGender); + this.panelTrainerInfo.Controls.Add(this.labelTrainerInfo); + this.panelTrainerInfo.Location = new System.Drawing.Point(12, 322); + this.panelTrainerInfo.Name = "panelTrainerInfo"; + this.panelTrainerInfo.Size = new System.Drawing.Size(511, 116); + this.panelTrainerInfo.TabIndex = 14; + // + // labelTrainerClass + // + this.labelTrainerClass.AutoSize = true; + this.labelTrainerClass.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelTrainerClass.Location = new System.Drawing.Point(3, 62); + this.labelTrainerClass.Name = "labelTrainerClass"; + this.labelTrainerClass.Size = new System.Drawing.Size(105, 20); + this.labelTrainerClass.TabIndex = 10; + this.labelTrainerClass.Text = "Trainer Class:"; + // + // labelTrainerName + // + this.labelTrainerName.AutoSize = true; + this.labelTrainerName.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelTrainerName.Location = new System.Drawing.Point(3, 32); + this.labelTrainerName.Name = "labelTrainerName"; + this.labelTrainerName.Size = new System.Drawing.Size(108, 20); + this.labelTrainerName.TabIndex = 8; + this.labelTrainerName.Text = "Trainer Name:"; + // + // panelTrainerGender + // + this.panelTrainerGender.Controls.Add(this.labelTrainerGender); + this.panelTrainerGender.Controls.Add(this.radioFemale); + this.panelTrainerGender.Controls.Add(this.radioMale); + this.panelTrainerGender.Location = new System.Drawing.Point(287, 12); + this.panelTrainerGender.Name = "panelTrainerGender"; + this.panelTrainerGender.Size = new System.Drawing.Size(149, 98); + this.panelTrainerGender.TabIndex = 9; + // + // labelTrainerGender + // + this.labelTrainerGender.AutoSize = true; + this.labelTrainerGender.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelTrainerGender.Location = new System.Drawing.Point(2, 6); + this.labelTrainerGender.Name = "labelTrainerGender"; + this.labelTrainerGender.Size = new System.Drawing.Size(116, 20); + this.labelTrainerGender.TabIndex = 9; + this.labelTrainerGender.Text = "Trainer Gender"; + // + // radioFemale + // + this.radioFemale.AutoSize = true; + this.radioFemale.Font = new System.Drawing.Font("Microsoft Sans Serif", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.radioFemale.Location = new System.Drawing.Point(3, 57); + this.radioFemale.Name = "radioFemale"; + this.radioFemale.Size = new System.Drawing.Size(75, 22); + this.radioFemale.TabIndex = 1; + this.radioFemale.TabStop = true; + this.radioFemale.Text = "Female"; + this.radioFemale.UseVisualStyleBackColor = true; + this.radioFemale.CheckedChanged += new System.EventHandler(this.valueChanged); + // + // radioMale + // + this.radioMale.AutoSize = true; + this.radioMale.Font = new System.Drawing.Font("Microsoft Sans Serif", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.radioMale.Location = new System.Drawing.Point(3, 29); + this.radioMale.Name = "radioMale"; + this.radioMale.Size = new System.Drawing.Size(111, 22); + this.radioMale.TabIndex = 0; + this.radioMale.TabStop = true; + this.radioMale.Text = "Male or Multi"; + this.radioMale.UseVisualStyleBackColor = true; + this.radioMale.CheckedChanged += new System.EventHandler(this.valueChanged); + // + // labelTrainerInfo + // + this.labelTrainerInfo.AutoSize = true; + this.labelTrainerInfo.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.labelTrainerInfo.Location = new System.Drawing.Point(3, 0); + this.labelTrainerInfo.Name = "labelTrainerInfo"; + this.labelTrainerInfo.Size = new System.Drawing.Size(102, 20); + this.labelTrainerInfo.TabIndex = 8; + this.labelTrainerInfo.Text = "Trainer Info"; + // + // DVCalc + // + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.ClientSize = new System.Drawing.Size(929, 444); + this.Controls.Add(this.panelTrainerInfo); + this.Controls.Add(this.panelNaturesEdit); + this.Controls.Add(this.panelDVs); + this.Controls.Add(this.panelGenders); + this.Controls.Add(this.panelAbilities); + this.Controls.Add(this.panelPokeLabels); + this.Name = "DVCalc"; + this.Text = "DVCalc"; + this.panelPokeLabels.ResumeLayout(false); + this.panelPokeLabels.PerformLayout(); + this.panelAbilities.ResumeLayout(false); + this.panelAbilities.PerformLayout(); + this.panelGenders.ResumeLayout(false); + this.panelGenders.PerformLayout(); + this.panelDVs.ResumeLayout(false); + this.panelDVs.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownDV6)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownDV5)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownDV4)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownDV3)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownDV2)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownDV1)).EndInit(); + this.panelNaturesEdit.ResumeLayout(false); + this.panelNaturesEdit.PerformLayout(); + this.panelTrainerInfo.ResumeLayout(false); + this.panelTrainerInfo.PerformLayout(); + this.panelTrainerGender.ResumeLayout(false); + this.panelTrainerGender.PerformLayout(); + this.ResumeLayout(false); + + } #endregion - private Label poke_label; - private Label trainerClassIdx_label; - private Label trainerIdx_label; - private Label pokeLVL_label; - private NumericUpDown pokeLevel; - private NumericUpDown trainerClassIdx; - private NumericUpDown trainerIdx; - private ComboBox natureSelect; - private Label nature_label; - private Label DV_label; - private Button calcButton; - private CheckBox maleCheck; - private Label maxDVNature_label; - private Label IV_label; - private ComboBox pokemonSelector; - private Button showAllButton; - private RadioButton radioButtonMale; - private RadioButton radioButtonFemale; - private RadioButton radioButtonAbility1; - private RadioButton radioButtonAbility2; - private NumericUpDown numericUpDownGender; - private GroupBox groupBoxGender; - private GroupBox groupBoxAbility; - private Label labelGenderRatio; - private GroupBox groupBoxHGSS; - private RadioButton radioButtonIngoreGender; - private RadioButton radioButtonIgnoreAbility; - private Button buttonHelp; - private Button buttonHGSS; + private System.Windows.Forms.Panel panelPokeLabels; + private System.Windows.Forms.Label pokeLabel1; + private System.Windows.Forms.Label pokeLabel6; + private System.Windows.Forms.Label pokeLabel5; + private System.Windows.Forms.Label pokeLabel4; + private System.Windows.Forms.Label pokeLabel3; + private System.Windows.Forms.Label pokeLabel2; + private System.Windows.Forms.ComboBox comboAbility1; + private System.Windows.Forms.ComboBox comboAbility2; + private System.Windows.Forms.ComboBox comboAbility3; + private System.Windows.Forms.ComboBox comboAbility4; + private System.Windows.Forms.ComboBox comboAbility5; + private System.Windows.Forms.ComboBox comboAbility6; + private System.Windows.Forms.Label labelPokeNames; + private System.Windows.Forms.Label labelAbilities; + private System.Windows.Forms.Panel panelAbilities; + private System.Windows.Forms.Panel panelGenders; + private System.Windows.Forms.ComboBox comboGender1; + private System.Windows.Forms.ComboBox comboGender2; + private System.Windows.Forms.ComboBox comboGender3; + private System.Windows.Forms.ComboBox comboGender4; + private System.Windows.Forms.ComboBox comboGender5; + private System.Windows.Forms.ComboBox comboGender6; + private System.Windows.Forms.Label labelGenders; + private System.Windows.Forms.Panel panelDVs; + private System.Windows.Forms.NumericUpDown numericUpDownDV1; + private System.Windows.Forms.NumericUpDown numericUpDownDV6; + private System.Windows.Forms.NumericUpDown numericUpDownDV5; + private System.Windows.Forms.NumericUpDown numericUpDownDV4; + private System.Windows.Forms.NumericUpDown numericUpDownDV3; + private System.Windows.Forms.NumericUpDown numericUpDownDV2; + private System.Windows.Forms.Label labelDVs; + private System.Windows.Forms.Panel panelNaturesEdit; + private System.Windows.Forms.Button buttonChange6; + private System.Windows.Forms.Button buttonChange5; + private System.Windows.Forms.Button buttonChange4; + private System.Windows.Forms.Button buttonChange3; + private System.Windows.Forms.Button buttonChange2; + private System.Windows.Forms.Button buttonChange1; + private System.Windows.Forms.Label labelNature6; + private System.Windows.Forms.Label labelNature5; + private System.Windows.Forms.Label labelNature4; + private System.Windows.Forms.Label labelNature3; + private System.Windows.Forms.Label labelNature2; + private System.Windows.Forms.Label labelNature1; + private System.Windows.Forms.Label labelNatures; + private System.Windows.Forms.Button buttonShowAll1; + private System.Windows.Forms.Button buttonShowAll2; + private System.Windows.Forms.Button buttonShowAll3; + private System.Windows.Forms.Button buttonShowAll4; + private System.Windows.Forms.Button buttonShowAll5; + private System.Windows.Forms.Button buttonShowAll6; + private System.Windows.Forms.Panel panelTrainerInfo; + private System.Windows.Forms.Label labelTrainerInfo; + private System.Windows.Forms.Panel panelTrainerGender; + private System.Windows.Forms.RadioButton radioFemale; + private System.Windows.Forms.RadioButton radioMale; + private System.Windows.Forms.Label labelTrainerClass; + private System.Windows.Forms.Label labelTrainerName; + private System.Windows.Forms.Label labelTrainerGender; } -} +} \ No newline at end of file diff --git a/DS_Map/DVCalculator/DVCalc.cs b/DS_Map/DVCalculator/DVCalc.cs index 142adca..905d658 100644 --- a/DS_Map/DVCalculator/DVCalc.cs +++ b/DS_Map/DVCalculator/DVCalc.cs @@ -1,7 +1,12 @@ using DSPRE.ROMFiles; using System; using System.Collections.Generic; +using System.ComponentModel; +using System.Data; using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; using System.Windows.Forms; namespace DSPRE @@ -9,582 +14,170 @@ namespace DSPRE public partial class DVCalc : Form { - public DVCalc() + private TrainerFile trainerFile; + private TrainerProperties trainerProp; + private List