From a1d53cdd1cac0c6f5b0d86ee8ad6c7d80bbb0c84 Mon Sep 17 00:00:00 2001 From: cadaei Date: Tue, 8 Jan 2019 20:13:43 +0100 Subject: [PATCH] fixed layout issue on taming-tab with taming-foods (#863). added server-filter for breeding-planner (#852, #823, #866). --- ARKBreedingStats/App.config | 3 + ARKBreedingStats/BreedingPlan.Designer.cs | 46 +- ARKBreedingStats/BreedingPlan.cs | 17 + ARKBreedingStats/Form1.cs | 10 +- ARKBreedingStats/Properties/AssemblyInfo.cs | 2 +- .../Properties/Settings.Designer.cs | 12 + ARKBreedingStats/Properties/Settings.settings | 3 + ARKBreedingStats/TamingControl.Designer.cs | 415 ++++++++++-------- ARKBreedingStats/TamingControl.cs | 7 +- ARKBreedingStats/TamingControl.resx | 134 ++++-- ARKBreedingStats/ver.txt | 2 +- 11 files changed, 409 insertions(+), 242 deletions(-) diff --git a/ARKBreedingStats/App.config b/ARKBreedingStats/App.config index 7b3f4181..9e3830f6 100644 --- a/ARKBreedingStats/App.config +++ b/ARKBreedingStats/App.config @@ -139,6 +139,9 @@ + + False + diff --git a/ARKBreedingStats/BreedingPlan.Designer.cs b/ARKBreedingStats/BreedingPlan.Designer.cs index 00946d32..63fbcc15 100644 --- a/ARKBreedingStats/BreedingPlan.Designer.cs +++ b/ARKBreedingStats/BreedingPlan.Designer.cs @@ -38,6 +38,7 @@ private void InitializeComponent() this.lbBreedingPlanHeader = new System.Windows.Forms.Label(); this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); this.flowLayoutPanel1 = new System.Windows.Forms.FlowLayoutPanel(); + this.pedigreeCreatureBestPossibleInSpecies = new ARKBreedingStats.PedigreeCreature(); this.pedigreeCreature1 = new ARKBreedingStats.PedigreeCreature(); this.lbBPBreedingScore = new System.Windows.Forms.Label(); this.pedigreeCreature2 = new ARKBreedingStats.PedigreeCreature(); @@ -60,6 +61,7 @@ private void InitializeComponent() this.listViewSpeciesBP = new System.Windows.Forms.ListView(); this.columnHeader5 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); this.tabPageTags = new System.Windows.Forms.TabPage(); + this.cbServerFilterLibrary = new System.Windows.Forms.CheckBox(); this.cbBPTagExcludeDefault = new System.Windows.Forms.CheckBox(); this.tagSelectorList1 = new ARKBreedingStats.uiControls.TagSelectorList(); this.label1 = new System.Windows.Forms.Label(); @@ -71,8 +73,7 @@ private void InitializeComponent() this.rbBPTopStatsCn = new System.Windows.Forms.RadioButton(); this.rbBPHighStats = new System.Windows.Forms.RadioButton(); this.rbBPTopStats = new System.Windows.Forms.RadioButton(); - this.statWeighting1 = new StatWeighting(); - this.pedigreeCreatureBestPossibleInSpecies = new ARKBreedingStats.PedigreeCreature(); + this.statWeighting1 = new ARKBreedingStats.uiControls.StatWeighting(); this.panelCombinations.SuspendLayout(); this.tableLayoutPanel1.SuspendLayout(); this.flowLayoutPanel1.SuspendLayout(); @@ -157,6 +158,16 @@ private void InitializeComponent() this.flowLayoutPanel1.Size = new System.Drawing.Size(915, 122); this.flowLayoutPanel1.TabIndex = 5; // + // pedigreeCreatureBestPossibleInSpecies + // + this.pedigreeCreatureBestPossibleInSpecies.Creature = null; + this.flowLayoutPanel1.SetFlowBreak(this.pedigreeCreatureBestPossibleInSpecies, true); + this.pedigreeCreatureBestPossibleInSpecies.IsVirtual = false; + this.pedigreeCreatureBestPossibleInSpecies.Location = new System.Drawing.Point(3, 44); + this.pedigreeCreatureBestPossibleInSpecies.Name = "pedigreeCreatureBestPossibleInSpecies"; + this.pedigreeCreatureBestPossibleInSpecies.Size = new System.Drawing.Size(296, 35); + this.pedigreeCreatureBestPossibleInSpecies.TabIndex = 5; + // // pedigreeCreature1 // this.pedigreeCreature1.Creature = null; @@ -372,6 +383,7 @@ private void InitializeComponent() // // tabPageTags // + this.tabPageTags.Controls.Add(this.cbServerFilterLibrary); this.tabPageTags.Controls.Add(this.cbBPTagExcludeDefault); this.tabPageTags.Controls.Add(this.tagSelectorList1); this.tabPageTags.Controls.Add(this.label1); @@ -383,10 +395,21 @@ private void InitializeComponent() this.tabPageTags.Text = "Tags"; this.tabPageTags.UseVisualStyleBackColor = true; // + // cbServerFilterLibrary + // + this.cbServerFilterLibrary.AutoSize = true; + this.cbServerFilterLibrary.Location = new System.Drawing.Point(3, 6); + this.cbServerFilterLibrary.Name = "cbServerFilterLibrary"; + this.cbServerFilterLibrary.Size = new System.Drawing.Size(139, 17); + this.cbServerFilterLibrary.TabIndex = 5; + this.cbServerFilterLibrary.Text = "Server Filter from Library"; + this.cbServerFilterLibrary.UseVisualStyleBackColor = true; + this.cbServerFilterLibrary.CheckedChanged += new System.EventHandler(this.cbServerFilterLibrary_CheckedChanged); + // // cbBPTagExcludeDefault // this.cbBPTagExcludeDefault.AutoSize = true; - this.cbBPTagExcludeDefault.Location = new System.Drawing.Point(6, 75); + this.cbBPTagExcludeDefault.Location = new System.Drawing.Point(6, 101); this.cbBPTagExcludeDefault.Name = "cbBPTagExcludeDefault"; this.cbBPTagExcludeDefault.Size = new System.Drawing.Size(160, 17); this.cbBPTagExcludeDefault.TabIndex = 4; @@ -397,14 +420,14 @@ private void InitializeComponent() // tagSelectorList1 // this.tagSelectorList1.AutoScroll = true; - this.tagSelectorList1.Location = new System.Drawing.Point(6, 98); + this.tagSelectorList1.Location = new System.Drawing.Point(6, 124); this.tagSelectorList1.Name = "tagSelectorList1"; - this.tagSelectorList1.Size = new System.Drawing.Size(174, 309); + this.tagSelectorList1.Size = new System.Drawing.Size(174, 283); this.tagSelectorList1.TabIndex = 3; // // label1 // - this.label1.Location = new System.Drawing.Point(6, 3); + this.label1.Location = new System.Drawing.Point(6, 29); this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(174, 69); this.label1.TabIndex = 2; @@ -532,16 +555,6 @@ private void InitializeComponent() 1D, 1D, 1D}; - // - // pedigreeCreatureBestPossibleInSpecies - // - this.pedigreeCreatureBestPossibleInSpecies.Creature = null; - this.flowLayoutPanel1.SetFlowBreak(this.pedigreeCreatureBestPossibleInSpecies, true); - this.pedigreeCreatureBestPossibleInSpecies.IsVirtual = false; - this.pedigreeCreatureBestPossibleInSpecies.Location = new System.Drawing.Point(3, 44); - this.pedigreeCreatureBestPossibleInSpecies.Name = "pedigreeCreatureBestPossibleInSpecies"; - this.pedigreeCreatureBestPossibleInSpecies.Size = new System.Drawing.Size(296, 35); - this.pedigreeCreatureBestPossibleInSpecies.TabIndex = 5; // // BreedingPlan // @@ -610,5 +623,6 @@ private void InitializeComponent() private System.Windows.Forms.CheckBox cbBPTagExcludeDefault; private System.Windows.Forms.FlowLayoutPanel flowLayoutPanel1; private PedigreeCreature pedigreeCreatureBestPossibleInSpecies; + private System.Windows.Forms.CheckBox cbServerFilterLibrary; } } diff --git a/ARKBreedingStats/BreedingPlan.cs b/ARKBreedingStats/BreedingPlan.cs index 281c3240..3ca73019 100644 --- a/ARKBreedingStats/BreedingPlan.cs +++ b/ARKBreedingStats/BreedingPlan.cs @@ -68,6 +68,8 @@ public BreedingPlan() breedingPlanNeedsUpdate = false; dontUpdateBreedingPlan = false; + cbServerFilterLibrary.Checked = Properties.Settings.Default.UseServerFilterForBreedingPlan; + tagSelectorList1.OnTagChanged += TagSelectorList1_OnTagChanged; } @@ -209,6 +211,15 @@ private void AsyncCalculateBreedingScoresAndDisplayPairs(BreedingMode breedingMo chosenM = new List(); else chosenM = filterByTags(males); + // filter by servers + if (cbServerFilterLibrary.Checked) + { + chosenF = chosenF.Where(c => (c.server == "" && !creatureCollection.hiddenServers.Contains("n/a")) + || (c.server != "" && !creatureCollection.hiddenServers.Contains(c.server))).ToList(); + chosenM = chosenM.Where(c => (c.server == "" && !creatureCollection.hiddenServers.Contains("n/a")) + || (c.server != "" && !creatureCollection.hiddenServers.Contains(c.server))).ToList(); + } + bool creaturesTagFilteredOut = (crCountF != chosenF.Count) || (crCountM != chosenM.Count); @@ -951,5 +962,11 @@ public void SetLocalizations() Loc.setToolTip(nudBPMutationLimit, tt); Loc.setToolTip(cbBPTagExcludeDefault, tt); } + + private void cbServerFilterLibrary_CheckedChanged(object sender, EventArgs e) + { + Properties.Settings.Default.UseServerFilterForBreedingPlan = cbServerFilterLibrary.Checked; + calculateBreedingScoresAndDisplayPairs(); + } } } diff --git a/ARKBreedingStats/Form1.cs b/ARKBreedingStats/Form1.cs index ba07987a..f5892c82 100644 --- a/ARKBreedingStats/Form1.cs +++ b/ARKBreedingStats/Form1.cs @@ -2651,9 +2651,15 @@ private void cbServerFilterAll_CheckedChanged(object sender, EventArgs e) for (int i = 0; i < checkedListBoxFilterServers.Items.Count; i++) { checkedListBoxFilterServers.SetItemChecked(i, chck); - if (!chck) creatureCollection.hiddenServers.Add(checkedListBoxFilterServers.Items[i].ToString()); + if (!chck) + { + string server = Regex.Match(checkedListBoxFilterServers.Items[i].ToString(), @"^(.+?)(?: \(\d+\))?$").Groups[1].Value; + creatureCollection.hiddenServers.Add(server); + } } + breedingPlan1.breedingPlanNeedsUpdate = true; // needed for serverFilterOption + filterListAllowed = true; filterLib(); } @@ -2695,6 +2701,8 @@ private void checkedListBoxFilterServers_ItemCheck(object sender, ItemCheckEvent creatureCollection.hiddenServers.Remove(server); } + breedingPlan1.breedingPlanNeedsUpdate = true; // needed for serverFilterOption + recalculateTopStatsIfNeeded(); filterLib(); } diff --git a/ARKBreedingStats/Properties/AssemblyInfo.cs b/ARKBreedingStats/Properties/AssemblyInfo.cs index 24a94cfd..57b32e44 100644 --- a/ARKBreedingStats/Properties/AssemblyInfo.cs +++ b/ARKBreedingStats/Properties/AssemblyInfo.cs @@ -31,6 +31,6 @@ // Revision // [assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("0.29.3.3")] +[assembly: AssemblyFileVersion("0.29.4.0")] [assembly: NeutralResourcesLanguage("en")] diff --git a/ARKBreedingStats/Properties/Settings.Designer.cs b/ARKBreedingStats/Properties/Settings.Designer.cs index cd3e5ad3..e3628025 100644 --- a/ARKBreedingStats/Properties/Settings.Designer.cs +++ b/ARKBreedingStats/Properties/Settings.Designer.cs @@ -604,5 +604,17 @@ public string ImportTribeNameFilter { this["ImportTribeNameFilter"] = value; } } + + [global::System.Configuration.UserScopedSettingAttribute()] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Configuration.DefaultSettingValueAttribute("False")] + public bool UseServerFilterForBreedingPlan { + get { + return ((bool)(this["UseServerFilterForBreedingPlan"])); + } + set { + this["UseServerFilterForBreedingPlan"] = value; + } + } } } diff --git a/ARKBreedingStats/Properties/Settings.settings b/ARKBreedingStats/Properties/Settings.settings index 699cfa18..50f75c22 100644 --- a/ARKBreedingStats/Properties/Settings.settings +++ b/ARKBreedingStats/Properties/Settings.settings @@ -149,5 +149,8 @@ + + False + \ No newline at end of file diff --git a/ARKBreedingStats/TamingControl.Designer.cs b/ARKBreedingStats/TamingControl.Designer.cs index b4023259..de51be6a 100644 --- a/ARKBreedingStats/TamingControl.Designer.cs +++ b/ARKBreedingStats/TamingControl.Designer.cs @@ -34,27 +34,19 @@ private void InitializeComponent() this.lbMax = new System.Windows.Forms.Label(); this.lbUsed = new System.Windows.Forms.Label(); this.gpTorporTime = new System.Windows.Forms.GroupBox(); - this.numericUpDownCurrentTorpor = new ARKBreedingStats.uiControls.Nud(); this.btAddWakeUpTimer = new System.Windows.Forms.Button(); this.lbTimeUntilWakingUp = new System.Windows.Forms.Label(); this.lbCurrentTorpor = new System.Windows.Forms.Label(); this.lbTamingTime = new System.Windows.Forms.Label(); this.gbWeaponDamage = new System.Windows.Forms.GroupBox(); - this.nudWDmHarpoon = new ARKBreedingStats.uiControls.Nud(); this.chkbDmHarpoon = new System.Windows.Forms.CheckBox(); this.rbBoneDamageDefault = new System.Windows.Forms.RadioButton(); - this.nudWDmProd = new ARKBreedingStats.uiControls.Nud(); this.chkbDmCrossbow = new System.Windows.Forms.CheckBox(); this.chkbDmBow = new System.Windows.Forms.CheckBox(); this.chkbDmSlingshot = new System.Windows.Forms.CheckBox(); this.chkbDmClub = new System.Windows.Forms.CheckBox(); this.chkbDmLongneck = new System.Windows.Forms.CheckBox(); - this.nudWDmSlingshot = new ARKBreedingStats.uiControls.Nud(); this.chkbDmProd = new System.Windows.Forms.CheckBox(); - this.nudWDmClub = new ARKBreedingStats.uiControls.Nud(); - this.nudWDmBow = new ARKBreedingStats.uiControls.Nud(); - this.nudWDmCrossbow = new ARKBreedingStats.uiControls.Nud(); - this.nudWDmLongneck = new ARKBreedingStats.uiControls.Nud(); this.gbKOInfo = new System.Windows.Forms.GroupBox(); this.lbKOInfo = new System.Windows.Forms.Label(); this.groupBox3 = new System.Windows.Forms.GroupBox(); @@ -63,11 +55,30 @@ private void InitializeComponent() this.lbTimeUntilStarving = new System.Windows.Forms.Label(); this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); this.panel1 = new System.Windows.Forms.Panel(); - this.nudLevel = new ARKBreedingStats.uiControls.Nud(); this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel(); + this.tableLayoutPanel3 = new System.Windows.Forms.TableLayoutPanel(); + this.flpTamingFood = new System.Windows.Forms.FlowLayoutPanel(); + this.panel2 = new System.Windows.Forms.Panel(); + this.nudLevel = new ARKBreedingStats.uiControls.Nud(); + this.nudWDmHarpoon = new ARKBreedingStats.uiControls.Nud(); + this.nudWDmProd = new ARKBreedingStats.uiControls.Nud(); + this.nudWDmSlingshot = new ARKBreedingStats.uiControls.Nud(); + this.nudWDmClub = new ARKBreedingStats.uiControls.Nud(); + this.nudWDmBow = new ARKBreedingStats.uiControls.Nud(); + this.nudWDmCrossbow = new ARKBreedingStats.uiControls.Nud(); + this.nudWDmLongneck = new ARKBreedingStats.uiControls.Nud(); + this.numericUpDownCurrentTorpor = new ARKBreedingStats.uiControls.Nud(); this.gpTorporTime.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.numericUpDownCurrentTorpor)).BeginInit(); this.gbWeaponDamage.SuspendLayout(); + this.gbKOInfo.SuspendLayout(); + this.groupBox3.SuspendLayout(); + this.gpStarvingTime.SuspendLayout(); + this.tableLayoutPanel1.SuspendLayout(); + this.panel1.SuspendLayout(); + this.tableLayoutPanel2.SuspendLayout(); + this.tableLayoutPanel3.SuspendLayout(); + this.panel2.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.nudLevel)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudWDmHarpoon)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudWDmProd)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudWDmSlingshot)).BeginInit(); @@ -75,13 +86,7 @@ private void InitializeComponent() ((System.ComponentModel.ISupportInitialize)(this.nudWDmBow)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudWDmCrossbow)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.nudWDmLongneck)).BeginInit(); - this.gbKOInfo.SuspendLayout(); - this.groupBox3.SuspendLayout(); - this.gpStarvingTime.SuspendLayout(); - this.tableLayoutPanel1.SuspendLayout(); - this.panel1.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.nudLevel)).BeginInit(); - this.tableLayoutPanel2.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownCurrentTorpor)).BeginInit(); this.SuspendLayout(); // // labelResult @@ -114,29 +119,6 @@ private void InitializeComponent() this.gpTorporTime.Name = "gpTorporTime"; this.gpTorporTime.TabStop = false; // - // numericUpDownCurrentTorpor - // - this.numericUpDownCurrentTorpor.DecimalPlaces = 1; - this.numericUpDownCurrentTorpor.ForeColor = System.Drawing.SystemColors.GrayText; - this.numericUpDownCurrentTorpor.Increment = new decimal(new int[] { - 10, - 0, - 0, - 0}); - resources.ApplyResources(this.numericUpDownCurrentTorpor, "numericUpDownCurrentTorpor"); - this.numericUpDownCurrentTorpor.Maximum = new decimal(new int[] { - 100000000, - 0, - 0, - 0}); - this.numericUpDownCurrentTorpor.Name = "numericUpDownCurrentTorpor"; - this.numericUpDownCurrentTorpor.NeutralNumber = new decimal(new int[] { - 0, - 0, - 0, - 0}); - this.numericUpDownCurrentTorpor.ValueChanged += new System.EventHandler(this.numericUpDownCurrentTorpor_ValueChanged); - // // btAddWakeUpTimer // resources.ApplyResources(this.btAddWakeUpTimer, "btAddWakeUpTimer"); @@ -181,6 +163,180 @@ private void InitializeComponent() this.tableLayoutPanel1.SetRowSpan(this.gbWeaponDamage, 2); this.gbWeaponDamage.TabStop = false; // + // chkbDmHarpoon + // + resources.ApplyResources(this.chkbDmHarpoon, "chkbDmHarpoon"); + this.chkbDmHarpoon.Name = "chkbDmHarpoon"; + this.chkbDmHarpoon.UseVisualStyleBackColor = true; + this.chkbDmHarpoon.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); + // + // rbBoneDamageDefault + // + resources.ApplyResources(this.rbBoneDamageDefault, "rbBoneDamageDefault"); + this.rbBoneDamageDefault.Name = "rbBoneDamageDefault"; + this.rbBoneDamageDefault.TabStop = true; + this.rbBoneDamageDefault.UseVisualStyleBackColor = true; + this.rbBoneDamageDefault.CheckedChanged += new System.EventHandler(this.rbBoneDamage_CheckedChanged); + // + // chkbDmCrossbow + // + resources.ApplyResources(this.chkbDmCrossbow, "chkbDmCrossbow"); + this.chkbDmCrossbow.Checked = true; + this.chkbDmCrossbow.CheckState = System.Windows.Forms.CheckState.Checked; + this.chkbDmCrossbow.Name = "chkbDmCrossbow"; + this.chkbDmCrossbow.UseVisualStyleBackColor = true; + this.chkbDmCrossbow.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); + // + // chkbDmBow + // + resources.ApplyResources(this.chkbDmBow, "chkbDmBow"); + this.chkbDmBow.Name = "chkbDmBow"; + this.chkbDmBow.UseVisualStyleBackColor = true; + this.chkbDmBow.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); + // + // chkbDmSlingshot + // + resources.ApplyResources(this.chkbDmSlingshot, "chkbDmSlingshot"); + this.chkbDmSlingshot.Name = "chkbDmSlingshot"; + this.chkbDmSlingshot.UseVisualStyleBackColor = true; + this.chkbDmSlingshot.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); + // + // chkbDmClub + // + resources.ApplyResources(this.chkbDmClub, "chkbDmClub"); + this.chkbDmClub.Name = "chkbDmClub"; + this.chkbDmClub.UseVisualStyleBackColor = true; + this.chkbDmClub.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); + // + // chkbDmLongneck + // + resources.ApplyResources(this.chkbDmLongneck, "chkbDmLongneck"); + this.chkbDmLongneck.Checked = true; + this.chkbDmLongneck.CheckState = System.Windows.Forms.CheckState.Checked; + this.chkbDmLongneck.Name = "chkbDmLongneck"; + this.chkbDmLongneck.UseVisualStyleBackColor = true; + this.chkbDmLongneck.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); + // + // chkbDmProd + // + resources.ApplyResources(this.chkbDmProd, "chkbDmProd"); + this.chkbDmProd.Name = "chkbDmProd"; + this.chkbDmProd.UseVisualStyleBackColor = true; + this.chkbDmProd.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); + // + // gbKOInfo + // + this.gbKOInfo.Controls.Add(this.lbKOInfo); + resources.ApplyResources(this.gbKOInfo, "gbKOInfo"); + this.gbKOInfo.Name = "gbKOInfo"; + this.gbKOInfo.TabStop = false; + // + // lbKOInfo + // + resources.ApplyResources(this.lbKOInfo, "lbKOInfo"); + this.lbKOInfo.Name = "lbKOInfo"; + // + // groupBox3 + // + this.tableLayoutPanel1.SetColumnSpan(this.groupBox3, 2); + this.groupBox3.Controls.Add(this.labelResult); + resources.ApplyResources(this.groupBox3, "groupBox3"); + this.groupBox3.Name = "groupBox3"; + this.tableLayoutPanel1.SetRowSpan(this.groupBox3, 2); + this.groupBox3.TabStop = false; + // + // gpStarvingTime + // + this.gpStarvingTime.Controls.Add(this.btnAddStarvingTimer); + this.gpStarvingTime.Controls.Add(this.lbTimeUntilStarving); + resources.ApplyResources(this.gpStarvingTime, "gpStarvingTime"); + this.gpStarvingTime.Name = "gpStarvingTime"; + this.gpStarvingTime.TabStop = false; + // + // btnAddStarvingTimer + // + resources.ApplyResources(this.btnAddStarvingTimer, "btnAddStarvingTimer"); + this.btnAddStarvingTimer.Name = "btnAddStarvingTimer"; + this.btnAddStarvingTimer.UseVisualStyleBackColor = true; + this.btnAddStarvingTimer.Click += new System.EventHandler(this.btnAddStarvingTimer_Click); + // + // lbTimeUntilStarving + // + resources.ApplyResources(this.lbTimeUntilStarving, "lbTimeUntilStarving"); + this.lbTimeUntilStarving.Name = "lbTimeUntilStarving"; + // + // tableLayoutPanel1 + // + resources.ApplyResources(this.tableLayoutPanel1, "tableLayoutPanel1"); + this.tableLayoutPanel1.Controls.Add(this.gpTorporTime, 0, 0); + this.tableLayoutPanel1.Controls.Add(this.gbKOInfo, 2, 2); + this.tableLayoutPanel1.Controls.Add(this.groupBox3, 0, 1); + this.tableLayoutPanel1.Controls.Add(this.gbWeaponDamage, 2, 0); + this.tableLayoutPanel1.Controls.Add(this.gpStarvingTime, 1, 0); + this.tableLayoutPanel1.Name = "tableLayoutPanel1"; + // + // panel1 + // + resources.ApplyResources(this.panel1, "panel1"); + this.panel1.Controls.Add(this.lbMax); + this.panel1.Controls.Add(this.lbUsed); + this.panel1.Controls.Add(this.lbTamingTime); + this.panel1.Name = "panel1"; + // + // tableLayoutPanel2 + // + resources.ApplyResources(this.tableLayoutPanel2, "tableLayoutPanel2"); + this.tableLayoutPanel2.Controls.Add(this.tableLayoutPanel3, 0, 0); + this.tableLayoutPanel2.Controls.Add(this.tableLayoutPanel1, 1, 0); + this.tableLayoutPanel2.Name = "tableLayoutPanel2"; + // + // tableLayoutPanel3 + // + resources.ApplyResources(this.tableLayoutPanel3, "tableLayoutPanel3"); + this.tableLayoutPanel3.Controls.Add(this.panel1, 0, 1); + this.tableLayoutPanel3.Controls.Add(this.flpTamingFood, 0, 2); + this.tableLayoutPanel3.Controls.Add(this.panel2, 0, 0); + this.tableLayoutPanel3.Name = "tableLayoutPanel3"; + // + // flpTamingFood + // + resources.ApplyResources(this.flpTamingFood, "flpTamingFood"); + this.flpTamingFood.Name = "flpTamingFood"; + // + // panel2 + // + this.panel2.Controls.Add(this.nudLevel); + this.panel2.Controls.Add(this.label1); + resources.ApplyResources(this.panel2, "panel2"); + this.panel2.Name = "panel2"; + // + // nudLevel + // + this.nudLevel.ForeColor = System.Drawing.SystemColors.WindowText; + resources.ApplyResources(this.nudLevel, "nudLevel"); + this.nudLevel.Maximum = new decimal(new int[] { + 10000, + 0, + 0, + 0}); + this.nudLevel.Minimum = new decimal(new int[] { + 1, + 0, + 0, + 0}); + this.nudLevel.Name = "nudLevel"; + this.nudLevel.NeutralNumber = new decimal(new int[] { + 0, + 0, + 0, + 0}); + this.nudLevel.Value = new decimal(new int[] { + 30, + 0, + 0, + 0}); + this.nudLevel.ValueChanged += new System.EventHandler(this.nudLevel_ValueChanged); + // // nudWDmHarpoon // this.nudWDmHarpoon.DecimalPlaces = 1; @@ -209,21 +365,6 @@ private void InitializeComponent() 0}); this.nudWDmHarpoon.ValueChanged += new System.EventHandler(this.nudWDm_ValueChanged); // - // chkbDmHarpoon - // - resources.ApplyResources(this.chkbDmHarpoon, "chkbDmHarpoon"); - this.chkbDmHarpoon.Name = "chkbDmHarpoon"; - this.chkbDmHarpoon.UseVisualStyleBackColor = true; - this.chkbDmHarpoon.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); - // - // rbBoneDamageDefault - // - resources.ApplyResources(this.rbBoneDamageDefault, "rbBoneDamageDefault"); - this.rbBoneDamageDefault.Name = "rbBoneDamageDefault"; - this.rbBoneDamageDefault.TabStop = true; - this.rbBoneDamageDefault.UseVisualStyleBackColor = true; - this.rbBoneDamageDefault.CheckedChanged += new System.EventHandler(this.rbBoneDamage_CheckedChanged); - // // nudWDmProd // this.nudWDmProd.DecimalPlaces = 1; @@ -252,45 +393,6 @@ private void InitializeComponent() 0}); this.nudWDmProd.ValueChanged += new System.EventHandler(this.nudWDm_ValueChanged); // - // chkbDmCrossbow - // - resources.ApplyResources(this.chkbDmCrossbow, "chkbDmCrossbow"); - this.chkbDmCrossbow.Checked = true; - this.chkbDmCrossbow.CheckState = System.Windows.Forms.CheckState.Checked; - this.chkbDmCrossbow.Name = "chkbDmCrossbow"; - this.chkbDmCrossbow.UseVisualStyleBackColor = true; - this.chkbDmCrossbow.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); - // - // chkbDmBow - // - resources.ApplyResources(this.chkbDmBow, "chkbDmBow"); - this.chkbDmBow.Name = "chkbDmBow"; - this.chkbDmBow.UseVisualStyleBackColor = true; - this.chkbDmBow.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); - // - // chkbDmSlingshot - // - resources.ApplyResources(this.chkbDmSlingshot, "chkbDmSlingshot"); - this.chkbDmSlingshot.Name = "chkbDmSlingshot"; - this.chkbDmSlingshot.UseVisualStyleBackColor = true; - this.chkbDmSlingshot.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); - // - // chkbDmClub - // - resources.ApplyResources(this.chkbDmClub, "chkbDmClub"); - this.chkbDmClub.Name = "chkbDmClub"; - this.chkbDmClub.UseVisualStyleBackColor = true; - this.chkbDmClub.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); - // - // chkbDmLongneck - // - resources.ApplyResources(this.chkbDmLongneck, "chkbDmLongneck"); - this.chkbDmLongneck.Checked = true; - this.chkbDmLongneck.CheckState = System.Windows.Forms.CheckState.Checked; - this.chkbDmLongneck.Name = "chkbDmLongneck"; - this.chkbDmLongneck.UseVisualStyleBackColor = true; - this.chkbDmLongneck.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); - // // nudWDmSlingshot // this.nudWDmSlingshot.DecimalPlaces = 1; @@ -319,13 +421,6 @@ private void InitializeComponent() 0}); this.nudWDmSlingshot.ValueChanged += new System.EventHandler(this.nudWDm_ValueChanged); // - // chkbDmProd - // - resources.ApplyResources(this.chkbDmProd, "chkbDmProd"); - this.chkbDmProd.Name = "chkbDmProd"; - this.chkbDmProd.UseVisualStyleBackColor = true; - this.chkbDmProd.CheckedChanged += new System.EventHandler(this.chkbDm_CheckedChanged); - // // nudWDmClub // this.nudWDmClub.DecimalPlaces = 1; @@ -438,100 +533,28 @@ private void InitializeComponent() 0}); this.nudWDmLongneck.ValueChanged += new System.EventHandler(this.nudWDm_ValueChanged); // - // gbKOInfo - // - this.gbKOInfo.Controls.Add(this.lbKOInfo); - resources.ApplyResources(this.gbKOInfo, "gbKOInfo"); - this.gbKOInfo.Name = "gbKOInfo"; - this.gbKOInfo.TabStop = false; - // - // lbKOInfo - // - resources.ApplyResources(this.lbKOInfo, "lbKOInfo"); - this.lbKOInfo.Name = "lbKOInfo"; - // - // groupBox3 - // - this.tableLayoutPanel1.SetColumnSpan(this.groupBox3, 2); - this.groupBox3.Controls.Add(this.labelResult); - resources.ApplyResources(this.groupBox3, "groupBox3"); - this.groupBox3.Name = "groupBox3"; - this.tableLayoutPanel1.SetRowSpan(this.groupBox3, 2); - this.groupBox3.TabStop = false; - // - // gpStarvingTime - // - this.gpStarvingTime.Controls.Add(this.btnAddStarvingTimer); - this.gpStarvingTime.Controls.Add(this.lbTimeUntilStarving); - resources.ApplyResources(this.gpStarvingTime, "gpStarvingTime"); - this.gpStarvingTime.Name = "gpStarvingTime"; - this.gpStarvingTime.TabStop = false; - // - // btnAddStarvingTimer - // - resources.ApplyResources(this.btnAddStarvingTimer, "btnAddStarvingTimer"); - this.btnAddStarvingTimer.Name = "btnAddStarvingTimer"; - this.btnAddStarvingTimer.UseVisualStyleBackColor = true; - this.btnAddStarvingTimer.Click += new System.EventHandler(this.btnAddStarvingTimer_Click); - // - // lbTimeUntilStarving - // - resources.ApplyResources(this.lbTimeUntilStarving, "lbTimeUntilStarving"); - this.lbTimeUntilStarving.Name = "lbTimeUntilStarving"; - // - // tableLayoutPanel1 - // - resources.ApplyResources(this.tableLayoutPanel1, "tableLayoutPanel1"); - this.tableLayoutPanel1.Controls.Add(this.gpTorporTime, 0, 0); - this.tableLayoutPanel1.Controls.Add(this.gbKOInfo, 2, 2); - this.tableLayoutPanel1.Controls.Add(this.groupBox3, 0, 1); - this.tableLayoutPanel1.Controls.Add(this.gbWeaponDamage, 2, 0); - this.tableLayoutPanel1.Controls.Add(this.gpStarvingTime, 1, 0); - this.tableLayoutPanel1.Name = "tableLayoutPanel1"; - // - // panel1 - // - resources.ApplyResources(this.panel1, "panel1"); - this.panel1.Controls.Add(this.lbMax); - this.panel1.Controls.Add(this.lbUsed); - this.panel1.Controls.Add(this.label1); - this.panel1.Controls.Add(this.nudLevel); - this.panel1.Controls.Add(this.lbTamingTime); - this.panel1.Name = "panel1"; - // - // nudLevel + // numericUpDownCurrentTorpor // - this.nudLevel.ForeColor = System.Drawing.SystemColors.WindowText; - resources.ApplyResources(this.nudLevel, "nudLevel"); - this.nudLevel.Maximum = new decimal(new int[] { - 10000, + this.numericUpDownCurrentTorpor.DecimalPlaces = 1; + this.numericUpDownCurrentTorpor.ForeColor = System.Drawing.SystemColors.GrayText; + this.numericUpDownCurrentTorpor.Increment = new decimal(new int[] { + 10, 0, 0, 0}); - this.nudLevel.Minimum = new decimal(new int[] { - 1, + resources.ApplyResources(this.numericUpDownCurrentTorpor, "numericUpDownCurrentTorpor"); + this.numericUpDownCurrentTorpor.Maximum = new decimal(new int[] { + 100000000, 0, 0, 0}); - this.nudLevel.Name = "nudLevel"; - this.nudLevel.NeutralNumber = new decimal(new int[] { - 0, - 0, + this.numericUpDownCurrentTorpor.Name = "numericUpDownCurrentTorpor"; + this.numericUpDownCurrentTorpor.NeutralNumber = new decimal(new int[] { 0, - 0}); - this.nudLevel.Value = new decimal(new int[] { - 30, 0, 0, 0}); - this.nudLevel.ValueChanged += new System.EventHandler(this.nudLevel_ValueChanged); - // - // tableLayoutPanel2 - // - resources.ApplyResources(this.tableLayoutPanel2, "tableLayoutPanel2"); - this.tableLayoutPanel2.Controls.Add(this.panel1, 0, 0); - this.tableLayoutPanel2.Controls.Add(this.tableLayoutPanel1, 1, 0); - this.tableLayoutPanel2.Name = "tableLayoutPanel2"; + this.numericUpDownCurrentTorpor.ValueChanged += new System.EventHandler(this.numericUpDownCurrentTorpor_ValueChanged); // // TamingControl // @@ -541,24 +564,27 @@ private void InitializeComponent() this.Name = "TamingControl"; this.gpTorporTime.ResumeLayout(false); this.gpTorporTime.PerformLayout(); - ((System.ComponentModel.ISupportInitialize)(this.numericUpDownCurrentTorpor)).EndInit(); this.gbWeaponDamage.ResumeLayout(false); this.gbWeaponDamage.PerformLayout(); - ((System.ComponentModel.ISupportInitialize)(this.nudWDmHarpoon)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.nudWDmProd)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.nudWDmSlingshot)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.nudWDmClub)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.nudWDmBow)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.nudWDmCrossbow)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.nudWDmLongneck)).EndInit(); this.gbKOInfo.ResumeLayout(false); this.groupBox3.ResumeLayout(false); this.gpStarvingTime.ResumeLayout(false); this.tableLayoutPanel1.ResumeLayout(false); this.panel1.ResumeLayout(false); this.panel1.PerformLayout(); - ((System.ComponentModel.ISupportInitialize)(this.nudLevel)).EndInit(); this.tableLayoutPanel2.ResumeLayout(false); + this.tableLayoutPanel3.ResumeLayout(false); + this.panel2.ResumeLayout(false); + this.panel2.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.nudLevel)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudWDmHarpoon)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudWDmProd)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudWDmSlingshot)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudWDmClub)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudWDmBow)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudWDmCrossbow)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.nudWDmLongneck)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.numericUpDownCurrentTorpor)).EndInit(); this.ResumeLayout(false); } @@ -600,5 +626,8 @@ private void InitializeComponent() private System.Windows.Forms.Panel panel1; private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2; private System.Windows.Forms.Label lbKOInfo; + private System.Windows.Forms.TableLayoutPanel tableLayoutPanel3; + private System.Windows.Forms.FlowLayoutPanel flpTamingFood; + private System.Windows.Forms.Panel panel2; } } diff --git a/ARKBreedingStats/TamingControl.cs b/ARKBreedingStats/TamingControl.cs index e3ae40fd..67f9b2ab 100644 --- a/ARKBreedingStats/TamingControl.cs +++ b/ARKBreedingStats/TamingControl.cs @@ -107,14 +107,11 @@ public void setSpeciesIndex(int speciesIndex) TamingFoodControl tf; if (i >= foodControls.Count) { - tf = new TamingFoodControl(f) - { - Location = new Point(20, 60 + 45 * i) - }; + tf = new TamingFoodControl(f); tf.valueChanged += updateTamingData; tf.Clicked += onlyOneFood; foodControls.Add(tf); - panel1.Controls.Add(tf); + flpTamingFood.Controls.Add(tf); } else { diff --git a/ARKBreedingStats/TamingControl.resx b/ARKBreedingStats/TamingControl.resx index 0a61b860..98ba6191 100644 --- a/ARKBreedingStats/TamingControl.resx +++ b/ARKBreedingStats/TamingControl.resx @@ -157,7 +157,7 @@ NoControl - 2, 5 + 6, 5 33, 13 @@ -175,10 +175,10 @@ System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - panel1 + panel2 - 2 + 1 True @@ -187,7 +187,7 @@ NoControl - 134, 40 + 105, 2 26, 13 @@ -217,7 +217,7 @@ NoControl - 197, 40 + 168, 2 30, 13 @@ -379,7 +379,7 @@ NoControl - 242, 40 + 220, 2 60, 13 @@ -400,7 +400,7 @@ panel1 - 4 + 2 147, 18 @@ -798,6 +798,9 @@ Fill + + NoControl + 3, 16 @@ -982,7 +985,7 @@ 1 - <?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls><Control Name="gpTorporTime" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /><Control Name="gbKOInfo" Row="2" RowSpan="1" Column="2" ColumnSpan="1" /><Control Name="groupBox3" Row="1" RowSpan="2" Column="0" ColumnSpan="2" /><Control Name="gbWeaponDamage" Row="0" RowSpan="2" Column="2" ColumnSpan="1" /><Control Name="gpStarvingTime" Row="0" RowSpan="1" Column="1" ColumnSpan="1" /></Controls><Columns Styles="Absolute,175,Absolute,175,AutoSize,0" /><Rows Styles="Absolute,100,Absolute,200,AutoSize,0" /></TableLayoutSettings> + <?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls><Control Name="gpTorporTime" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /><Control Name="gbKOInfo" Row="2" RowSpan="1" Column="2" ColumnSpan="1" /><Control Name="groupBox3" Row="1" RowSpan="2" Column="0" ColumnSpan="2" /><Control Name="gbWeaponDamage" Row="0" RowSpan="2" Column="2" ColumnSpan="1" /><Control Name="gpStarvingTime" Row="0" RowSpan="1" Column="1" ColumnSpan="1" /></Controls><Columns Styles="Absolute,175,Absolute,175,AutoSize,0" /><Rows Styles="Absolute,100,Absolute,200,AutoSize,0,Absolute,20" /></TableLayoutSettings> 271, 294 @@ -1008,8 +1011,62 @@ True + + Fill + + + 3, 38 + + + 338, 27 + + + 11 + + + panel1 + + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tableLayoutPanel3 + + + 0 + + + 2 + + + 1 + + + Fill + + + 3, 71 + + + 338, 537 + + + 5 + + + flpTamingFood + + + System.Windows.Forms.FlowLayoutPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tableLayoutPanel3 + + + 1 + - 41, 3 + 45, 3 56, 20 @@ -1024,37 +1081,64 @@ ARKBreedingStats.uiControls.Nud, ARK Smart Breeding, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null - panel1 + panel2 - 3 + 0 - + Fill - + 3, 3 - - 344, 611 + + 338, 29 - - 11 + + 7 - - panel1 + + panel2 - + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - + + tableLayoutPanel3 + + + 2 + + + Fill + + + 3, 3 + + + 3 + + + 344, 611 + + + 6 + + + tableLayoutPanel3 + + + System.Windows.Forms.TableLayoutPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + tableLayoutPanel2 - + 0 - - 2 + + <?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls><Control Name="panel1" Row="1" RowSpan="1" Column="0" ColumnSpan="1" /><Control Name="flpTamingFood" Row="2" RowSpan="1" Column="0" ColumnSpan="1" /><Control Name="panel2" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /></Controls><Columns Styles="Percent,100" /><Rows Styles="AutoSize,0,AutoSize,0,AutoSize,0" /></TableLayoutSettings> Fill @@ -1084,7 +1168,7 @@ 0 - <?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls><Control Name="panel1" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /><Control Name="tableLayoutPanel1" Row="0" RowSpan="1" Column="1" ColumnSpan="1" /></Controls><Columns Styles="Absolute,350,AutoSize,0" /><Rows Styles="Percent,100" /></TableLayoutSettings> + <?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls><Control Name="tableLayoutPanel3" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /><Control Name="tableLayoutPanel1" Row="0" RowSpan="1" Column="1" ColumnSpan="1" /></Controls><Columns Styles="Absolute,350,AutoSize,0" /><Rows Styles="Percent,100" /></TableLayoutSettings> True diff --git a/ARKBreedingStats/ver.txt b/ARKBreedingStats/ver.txt index 0d8e5973..64c442cd 100644 --- a/ARKBreedingStats/ver.txt +++ b/ARKBreedingStats/ver.txt @@ -1 +1 @@ -285.106.2,0.29.3.3 +285.106.2,0.29.4.0