diff --git a/ARKBreedingStats.sln.DotSettings b/ARKBreedingStats.sln.DotSettings
index f49271e2..9c5189be 100644
--- a/ARKBreedingStats.sln.DotSettings
+++ b/ARKBreedingStats.sln.DotSettings
@@ -14,4 +14,5 @@
NEXT_LINE
True
True
+ True
True
\ No newline at end of file
diff --git a/ARKBreedingStats/BreedingPlan.cs b/ARKBreedingStats/BreedingPlan.cs
index ace97528..10558b80 100644
--- a/ARKBreedingStats/BreedingPlan.cs
+++ b/ARKBreedingStats/BreedingPlan.cs
@@ -945,7 +945,7 @@ private void listViewSpeciesBP_SelectedIndexChanged(object sender, EventArgs e)
|| listViewSpeciesBP.SelectedItems[0].Text != currentSpecies.DescriptiveNameAndMod)
)
{
- SetGlobalSpecies?.Invoke((Species)((ListViewItem)listViewSpeciesBP.SelectedItems[0]).Tag);
+ SetGlobalSpecies?.Invoke((Species)listViewSpeciesBP.SelectedItems[0].Tag);
}
}
diff --git a/ARKBreedingStats/CreatureInfoInput.Designer.cs b/ARKBreedingStats/CreatureInfoInput.Designer.cs
index 886db0b7..45d89be8 100644
--- a/ARKBreedingStats/CreatureInfoInput.Designer.cs
+++ b/ARKBreedingStats/CreatureInfoInput.Designer.cs
@@ -31,6 +31,11 @@ protected override void Dispose(bool disposing)
private void InitializeComponent()
{
this.gbCreatureInfo = new System.Windows.Forms.GroupBox();
+ this.btNamingPattern6 = new System.Windows.Forms.Button();
+ this.btNamingPattern5 = new System.Windows.Forms.Button();
+ this.btNamingPattern4 = new System.Windows.Forms.Button();
+ this.btNamingPattern3 = new System.Windows.Forms.Button();
+ this.btNamingPattern2 = new System.Windows.Forms.Button();
this.btNamingPatternEditor = new System.Windows.Forms.Button();
this.btnGenerateUniqueName = new System.Windows.Forms.Button();
this.tbArkIdIngame = new System.Windows.Forms.TextBox();
@@ -74,11 +79,8 @@ private void InitializeComponent()
this.lbOwner = new System.Windows.Forms.Label();
this.lbName = new System.Windows.Forms.Label();
this.btAdd2Library = new System.Windows.Forms.Button();
- this.btNamingPattern2 = new System.Windows.Forms.Button();
- this.btNamingPattern3 = new System.Windows.Forms.Button();
- this.btNamingPattern4 = new System.Windows.Forms.Button();
- this.btNamingPattern5 = new System.Windows.Forms.Button();
- this.btNamingPattern6 = new System.Windows.Forms.Button();
+ this.BtSaveOTSPreset = new System.Windows.Forms.Button();
+ this.BtApplyOTSPreset = new System.Windows.Forms.Button();
this.gbCreatureInfo.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.nudMutationsFather)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.nudMutationsMother)).BeginInit();
@@ -87,6 +89,8 @@ private void InitializeComponent()
//
// gbCreatureInfo
//
+ this.gbCreatureInfo.Controls.Add(this.BtApplyOTSPreset);
+ this.gbCreatureInfo.Controls.Add(this.BtSaveOTSPreset);
this.gbCreatureInfo.Controls.Add(this.btNamingPattern6);
this.gbCreatureInfo.Controls.Add(this.btNamingPattern5);
this.gbCreatureInfo.Controls.Add(this.btNamingPattern4);
@@ -138,12 +142,62 @@ private void InitializeComponent()
this.gbCreatureInfo.Dock = System.Windows.Forms.DockStyle.Fill;
this.gbCreatureInfo.Location = new System.Drawing.Point(0, 0);
this.gbCreatureInfo.Name = "gbCreatureInfo";
- this.gbCreatureInfo.Size = new System.Drawing.Size(229, 518);
+ this.gbCreatureInfo.Size = new System.Drawing.Size(229, 542);
this.gbCreatureInfo.TabIndex = 0;
this.gbCreatureInfo.TabStop = false;
this.gbCreatureInfo.Text = "Creature-info";
this.gbCreatureInfo.Enter += new System.EventHandler(this.groupBox1_Enter);
//
+ // btNamingPattern6
+ //
+ this.btNamingPattern6.Location = new System.Drawing.Point(190, 44);
+ this.btNamingPattern6.Name = "btNamingPattern6";
+ this.btNamingPattern6.Size = new System.Drawing.Size(33, 20);
+ this.btNamingPattern6.TabIndex = 48;
+ this.btNamingPattern6.TabStop = false;
+ this.btNamingPattern6.Text = "G6";
+ this.btNamingPattern6.UseVisualStyleBackColor = true;
+ //
+ // btNamingPattern5
+ //
+ this.btNamingPattern5.Location = new System.Drawing.Point(155, 44);
+ this.btNamingPattern5.Name = "btNamingPattern5";
+ this.btNamingPattern5.Size = new System.Drawing.Size(30, 20);
+ this.btNamingPattern5.TabIndex = 47;
+ this.btNamingPattern5.TabStop = false;
+ this.btNamingPattern5.Text = "G5";
+ this.btNamingPattern5.UseVisualStyleBackColor = true;
+ //
+ // btNamingPattern4
+ //
+ this.btNamingPattern4.Location = new System.Drawing.Point(120, 44);
+ this.btNamingPattern4.Name = "btNamingPattern4";
+ this.btNamingPattern4.Size = new System.Drawing.Size(30, 20);
+ this.btNamingPattern4.TabIndex = 46;
+ this.btNamingPattern4.TabStop = false;
+ this.btNamingPattern4.Text = "G4";
+ this.btNamingPattern4.UseVisualStyleBackColor = true;
+ //
+ // btNamingPattern3
+ //
+ this.btNamingPattern3.Location = new System.Drawing.Point(85, 44);
+ this.btNamingPattern3.Name = "btNamingPattern3";
+ this.btNamingPattern3.Size = new System.Drawing.Size(30, 20);
+ this.btNamingPattern3.TabIndex = 45;
+ this.btNamingPattern3.TabStop = false;
+ this.btNamingPattern3.Text = "G3";
+ this.btNamingPattern3.UseVisualStyleBackColor = true;
+ //
+ // btNamingPattern2
+ //
+ this.btNamingPattern2.Location = new System.Drawing.Point(50, 44);
+ this.btNamingPattern2.Name = "btNamingPattern2";
+ this.btNamingPattern2.Size = new System.Drawing.Size(30, 20);
+ this.btNamingPattern2.TabIndex = 44;
+ this.btNamingPattern2.TabStop = false;
+ this.btNamingPattern2.Text = "G2";
+ this.btNamingPattern2.UseVisualStyleBackColor = true;
+ //
// btNamingPatternEditor
//
this.btNamingPatternEditor.Location = new System.Drawing.Point(201, 19);
@@ -166,7 +220,7 @@ private void InitializeComponent()
//
// tbArkIdIngame
//
- this.tbArkIdIngame.Location = new System.Drawing.Point(83, 255);
+ this.tbArkIdIngame.Location = new System.Drawing.Point(83, 281);
this.tbArkIdIngame.Name = "tbArkIdIngame";
this.tbArkIdIngame.ReadOnly = true;
this.tbArkIdIngame.Size = new System.Drawing.Size(138, 20);
@@ -174,7 +228,7 @@ private void InitializeComponent()
//
// tbARKID
//
- this.tbARKID.Location = new System.Drawing.Point(50, 229);
+ this.tbARKID.Location = new System.Drawing.Point(50, 255);
this.tbARKID.Name = "tbARKID";
this.tbARKID.Size = new System.Drawing.Size(172, 20);
this.tbARKID.TabIndex = 8;
@@ -184,7 +238,7 @@ private void InitializeComponent()
this.cbServer.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Append;
this.cbServer.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.CustomSource;
this.cbServer.FormattingEnabled = true;
- this.cbServer.Location = new System.Drawing.Point(50, 122);
+ this.cbServer.Location = new System.Drawing.Point(50, 148);
this.cbServer.Name = "cbServer";
this.cbServer.Size = new System.Drawing.Size(172, 21);
this.cbServer.TabIndex = 4;
@@ -193,14 +247,14 @@ private void InitializeComponent()
//
this.textBoxTribe.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.textBoxTribe.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.CustomSource;
- this.textBoxTribe.Location = new System.Drawing.Point(50, 96);
+ this.textBoxTribe.Location = new System.Drawing.Point(50, 122);
this.textBoxTribe.Name = "textBoxTribe";
this.textBoxTribe.Size = new System.Drawing.Size(172, 20);
this.textBoxTribe.TabIndex = 3;
//
// textBoxNote
//
- this.textBoxNote.Location = new System.Drawing.Point(50, 203);
+ this.textBoxNote.Location = new System.Drawing.Point(50, 229);
this.textBoxNote.Name = "textBoxNote";
this.textBoxNote.Size = new System.Drawing.Size(172, 20);
this.textBoxNote.TabIndex = 7;
@@ -210,7 +264,7 @@ private void InitializeComponent()
this.parentComboBoxFather.DrawMode = System.Windows.Forms.DrawMode.OwnerDrawFixed;
this.parentComboBoxFather.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.parentComboBoxFather.FormattingEnabled = true;
- this.parentComboBoxFather.Location = new System.Drawing.Point(50, 176);
+ this.parentComboBoxFather.Location = new System.Drawing.Point(50, 202);
this.parentComboBoxFather.Name = "parentComboBoxFather";
this.parentComboBoxFather.PreselectedCreatureGuid = new System.Guid("00000000-0000-0000-0000-000000000000");
this.parentComboBoxFather.Size = new System.Drawing.Size(172, 21);
@@ -222,7 +276,7 @@ private void InitializeComponent()
this.parentComboBoxMother.DrawMode = System.Windows.Forms.DrawMode.OwnerDrawFixed;
this.parentComboBoxMother.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.parentComboBoxMother.FormattingEnabled = true;
- this.parentComboBoxMother.Location = new System.Drawing.Point(50, 149);
+ this.parentComboBoxMother.Location = new System.Drawing.Point(50, 175);
this.parentComboBoxMother.Name = "parentComboBoxMother";
this.parentComboBoxMother.PreselectedCreatureGuid = new System.Guid("00000000-0000-0000-0000-000000000000");
this.parentComboBoxMother.Size = new System.Drawing.Size(172, 21);
@@ -233,7 +287,7 @@ private void InitializeComponent()
//
this.textBoxOwner.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.textBoxOwner.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.CustomSource;
- this.textBoxOwner.Location = new System.Drawing.Point(50, 70);
+ this.textBoxOwner.Location = new System.Drawing.Point(50, 96);
this.textBoxOwner.Name = "textBoxOwner";
this.textBoxOwner.Size = new System.Drawing.Size(172, 20);
this.textBoxOwner.TabIndex = 2;
@@ -250,7 +304,7 @@ private void InitializeComponent()
// nudMutationsFather
//
this.nudMutationsFather.ForeColor = System.Drawing.SystemColors.GrayText;
- this.nudMutationsFather.Location = new System.Drawing.Point(162, 360);
+ this.nudMutationsFather.Location = new System.Drawing.Point(162, 386);
this.nudMutationsFather.Maximum = new decimal(new int[] {
2147483647,
0,
@@ -274,7 +328,7 @@ private void InitializeComponent()
// nudMutationsMother
//
this.nudMutationsMother.ForeColor = System.Drawing.SystemColors.GrayText;
- this.nudMutationsMother.Location = new System.Drawing.Point(80, 360);
+ this.nudMutationsMother.Location = new System.Drawing.Point(80, 386);
this.nudMutationsMother.Maximum = new decimal(new int[] {
2147483647,
0,
@@ -298,7 +352,7 @@ private void InitializeComponent()
// label12
//
this.label12.AutoSize = true;
- this.label12.Location = new System.Drawing.Point(147, 362);
+ this.label12.Location = new System.Drawing.Point(147, 388);
this.label12.Name = "label12";
this.label12.Size = new System.Drawing.Size(17, 13);
this.label12.TabIndex = 34;
@@ -307,7 +361,7 @@ private void InitializeComponent()
// label11
//
this.label11.AutoSize = true;
- this.label11.Location = new System.Drawing.Point(65, 362);
+ this.label11.Location = new System.Drawing.Point(65, 388);
this.label11.Name = "label11";
this.label11.Size = new System.Drawing.Size(16, 13);
this.label11.TabIndex = 33;
@@ -315,7 +369,7 @@ private void InitializeComponent()
//
// dhmsInputGrown
//
- this.dhmsInputGrown.Location = new System.Drawing.Point(86, 305);
+ this.dhmsInputGrown.Location = new System.Drawing.Point(86, 331);
this.dhmsInputGrown.Name = "dhmsInputGrown";
this.dhmsInputGrown.Size = new System.Drawing.Size(136, 26);
this.dhmsInputGrown.TabIndex = 10;
@@ -324,7 +378,7 @@ private void InitializeComponent()
//
// dhmsInputCooldown
//
- this.dhmsInputCooldown.Location = new System.Drawing.Point(86, 278);
+ this.dhmsInputCooldown.Location = new System.Drawing.Point(86, 304);
this.dhmsInputCooldown.Name = "dhmsInputCooldown";
this.dhmsInputCooldown.Size = new System.Drawing.Size(136, 26);
this.dhmsInputCooldown.TabIndex = 9;
@@ -334,7 +388,7 @@ private void InitializeComponent()
//
this.nudMaturation.DecimalPlaces = 2;
this.nudMaturation.ForeColor = System.Drawing.SystemColors.WindowText;
- this.nudMaturation.Location = new System.Drawing.Point(89, 334);
+ this.nudMaturation.Location = new System.Drawing.Point(89, 360);
this.nudMaturation.Name = "nudMaturation";
this.nudMaturation.NeutralNumber = new decimal(new int[] {
0,
@@ -354,7 +408,7 @@ private void InitializeComponent()
//
this.cbNeutered.Appearance = System.Windows.Forms.Appearance.Button;
this.cbNeutered.AutoSize = true;
- this.cbNeutered.Location = new System.Drawing.Point(91, 386);
+ this.cbNeutered.Location = new System.Drawing.Point(91, 412);
this.cbNeutered.Name = "cbNeutered";
this.cbNeutered.Size = new System.Drawing.Size(61, 23);
this.cbNeutered.TabIndex = 15;
@@ -365,7 +419,7 @@ private void InitializeComponent()
//
this.dateTimePickerAdded.Checked = false;
this.dateTimePickerAdded.Format = System.Windows.Forms.DateTimePickerFormat.Time;
- this.dateTimePickerAdded.Location = new System.Drawing.Point(146, 414);
+ this.dateTimePickerAdded.Location = new System.Drawing.Point(146, 440);
this.dateTimePickerAdded.MinDate = new System.DateTime(2014, 12, 31, 0, 0, 0, 0);
this.dateTimePickerAdded.Name = "dateTimePickerAdded";
this.dateTimePickerAdded.Size = new System.Drawing.Size(76, 20);
@@ -373,7 +427,7 @@ private void InitializeComponent()
//
// buttonStatus
//
- this.buttonStatus.Location = new System.Drawing.Point(49, 415);
+ this.buttonStatus.Location = new System.Drawing.Point(49, 441);
this.buttonStatus.Name = "buttonStatus";
this.buttonStatus.Size = new System.Drawing.Size(35, 23);
this.buttonStatus.TabIndex = 16;
@@ -382,7 +436,7 @@ private void InitializeComponent()
//
// buttonSex
//
- this.buttonSex.Location = new System.Drawing.Point(50, 386);
+ this.buttonSex.Location = new System.Drawing.Point(50, 412);
this.buttonSex.Name = "buttonSex";
this.buttonSex.Size = new System.Drawing.Size(35, 23);
this.buttonSex.TabIndex = 14;
@@ -393,7 +447,7 @@ private void InitializeComponent()
// lbNewMutations
//
this.lbNewMutations.AutoSize = true;
- this.lbNewMutations.Location = new System.Drawing.Point(186, 391);
+ this.lbNewMutations.Location = new System.Drawing.Point(186, 417);
this.lbNewMutations.Name = "lbNewMutations";
this.lbNewMutations.Size = new System.Drawing.Size(30, 13);
this.lbNewMutations.TabIndex = 42;
@@ -403,7 +457,7 @@ private void InitializeComponent()
// lbArkIdIngame
//
this.lbArkIdIngame.AutoSize = true;
- this.lbArkIdIngame.Location = new System.Drawing.Point(5, 258);
+ this.lbArkIdIngame.Location = new System.Drawing.Point(5, 284);
this.lbArkIdIngame.Name = "lbArkIdIngame";
this.lbArkIdIngame.Size = new System.Drawing.Size(72, 13);
this.lbArkIdIngame.TabIndex = 41;
@@ -412,7 +466,7 @@ private void InitializeComponent()
// label1
//
this.label1.AutoSize = true;
- this.label1.Location = new System.Drawing.Point(6, 232);
+ this.label1.Location = new System.Drawing.Point(6, 258);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(35, 13);
this.label1.TabIndex = 39;
@@ -420,7 +474,7 @@ private void InitializeComponent()
//
// btClearColors
//
- this.btClearColors.Location = new System.Drawing.Point(2, 444);
+ this.btClearColors.Location = new System.Drawing.Point(2, 470);
this.btClearColors.Name = "btClearColors";
this.btClearColors.Size = new System.Drawing.Size(45, 23);
this.btClearColors.TabIndex = 37;
@@ -430,7 +484,7 @@ private void InitializeComponent()
//
// regionColorChooser1
//
- this.regionColorChooser1.Location = new System.Drawing.Point(48, 441);
+ this.regionColorChooser1.Location = new System.Drawing.Point(48, 467);
this.regionColorChooser1.Margin = new System.Windows.Forms.Padding(0);
this.regionColorChooser1.Name = "regionColorChooser1";
this.regionColorChooser1.Size = new System.Drawing.Size(174, 29);
@@ -439,7 +493,7 @@ private void InitializeComponent()
// lbServer
//
this.lbServer.AutoSize = true;
- this.lbServer.Location = new System.Drawing.Point(6, 125);
+ this.lbServer.Location = new System.Drawing.Point(6, 151);
this.lbServer.Name = "lbServer";
this.lbServer.Size = new System.Drawing.Size(38, 13);
this.lbServer.TabIndex = 30;
@@ -449,7 +503,7 @@ private void InitializeComponent()
//
this.lbTribe.AutoSize = true;
this.lbTribe.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Underline, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.lbTribe.Location = new System.Drawing.Point(6, 99);
+ this.lbTribe.Location = new System.Drawing.Point(6, 125);
this.lbTribe.Name = "lbTribe";
this.lbTribe.Size = new System.Drawing.Size(31, 13);
this.lbTribe.TabIndex = 29;
@@ -459,7 +513,7 @@ private void InitializeComponent()
// lbStatus
//
this.lbStatus.AutoSize = true;
- this.lbStatus.Location = new System.Drawing.Point(6, 420);
+ this.lbStatus.Location = new System.Drawing.Point(6, 446);
this.lbStatus.Name = "lbStatus";
this.lbStatus.Size = new System.Drawing.Size(37, 13);
this.lbStatus.TabIndex = 27;
@@ -468,7 +522,7 @@ private void InitializeComponent()
// lbSex
//
this.lbSex.AutoSize = true;
- this.lbSex.Location = new System.Drawing.Point(6, 391);
+ this.lbSex.Location = new System.Drawing.Point(6, 417);
this.lbSex.Name = "lbSex";
this.lbSex.Size = new System.Drawing.Size(25, 13);
this.lbSex.TabIndex = 26;
@@ -477,7 +531,7 @@ private void InitializeComponent()
// lbMutations
//
this.lbMutations.AutoSize = true;
- this.lbMutations.Location = new System.Drawing.Point(6, 362);
+ this.lbMutations.Location = new System.Drawing.Point(6, 388);
this.lbMutations.Name = "lbMutations";
this.lbMutations.Size = new System.Drawing.Size(53, 13);
this.lbMutations.TabIndex = 25;
@@ -486,7 +540,7 @@ private void InitializeComponent()
// label7
//
this.label7.AutoSize = true;
- this.label7.Location = new System.Drawing.Point(105, 420);
+ this.label7.Location = new System.Drawing.Point(105, 446);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(38, 13);
this.label7.TabIndex = 17;
@@ -495,7 +549,7 @@ private void InitializeComponent()
// lbMaturationPerc
//
this.lbMaturationPerc.AutoSize = true;
- this.lbMaturationPerc.Location = new System.Drawing.Point(6, 336);
+ this.lbMaturationPerc.Location = new System.Drawing.Point(6, 362);
this.lbMaturationPerc.Name = "lbMaturationPerc";
this.lbMaturationPerc.Size = new System.Drawing.Size(74, 13);
this.lbMaturationPerc.TabIndex = 22;
@@ -504,7 +558,7 @@ private void InitializeComponent()
// lbCooldown
//
this.lbCooldown.AutoSize = true;
- this.lbCooldown.Location = new System.Drawing.Point(6, 285);
+ this.lbCooldown.Location = new System.Drawing.Point(6, 311);
this.lbCooldown.Name = "lbCooldown";
this.lbCooldown.Size = new System.Drawing.Size(54, 13);
this.lbCooldown.TabIndex = 20;
@@ -513,7 +567,7 @@ private void InitializeComponent()
// lbGrownIn
//
this.lbGrownIn.AutoSize = true;
- this.lbGrownIn.Location = new System.Drawing.Point(6, 311);
+ this.lbGrownIn.Location = new System.Drawing.Point(6, 337);
this.lbGrownIn.Name = "lbGrownIn";
this.lbGrownIn.Size = new System.Drawing.Size(49, 13);
this.lbGrownIn.TabIndex = 21;
@@ -521,7 +575,7 @@ private void InitializeComponent()
//
// btSaveChanges
//
- this.btSaveChanges.Location = new System.Drawing.Point(89, 473);
+ this.btSaveChanges.Location = new System.Drawing.Point(89, 499);
this.btSaveChanges.Name = "btSaveChanges";
this.btSaveChanges.Size = new System.Drawing.Size(60, 37);
this.btSaveChanges.TabIndex = 20;
@@ -533,7 +587,7 @@ private void InitializeComponent()
// lbNote
//
this.lbNote.AutoSize = true;
- this.lbNote.Location = new System.Drawing.Point(6, 206);
+ this.lbNote.Location = new System.Drawing.Point(6, 232);
this.lbNote.Name = "lbNote";
this.lbNote.Size = new System.Drawing.Size(30, 13);
this.lbNote.TabIndex = 19;
@@ -542,7 +596,7 @@ private void InitializeComponent()
// lbFather
//
this.lbFather.AutoSize = true;
- this.lbFather.Location = new System.Drawing.Point(6, 179);
+ this.lbFather.Location = new System.Drawing.Point(6, 205);
this.lbFather.Name = "lbFather";
this.lbFather.Size = new System.Drawing.Size(37, 13);
this.lbFather.TabIndex = 18;
@@ -551,7 +605,7 @@ private void InitializeComponent()
// lbMother
//
this.lbMother.AutoSize = true;
- this.lbMother.Location = new System.Drawing.Point(6, 152);
+ this.lbMother.Location = new System.Drawing.Point(6, 178);
this.lbMother.Name = "lbMother";
this.lbMother.Size = new System.Drawing.Size(40, 13);
this.lbMother.TabIndex = 17;
@@ -561,7 +615,7 @@ private void InitializeComponent()
//
this.lbOwner.AutoSize = true;
this.lbOwner.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Underline, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.lbOwner.Location = new System.Drawing.Point(6, 73);
+ this.lbOwner.Location = new System.Drawing.Point(6, 99);
this.lbOwner.Name = "lbOwner";
this.lbOwner.Size = new System.Drawing.Size(38, 13);
this.lbOwner.TabIndex = 16;
@@ -581,7 +635,7 @@ private void InitializeComponent()
//
// btAdd2Library
//
- this.btAdd2Library.Location = new System.Drawing.Point(89, 473);
+ this.btAdd2Library.Location = new System.Drawing.Point(89, 499);
this.btAdd2Library.Name = "btAdd2Library";
this.btAdd2Library.Size = new System.Drawing.Size(134, 37);
this.btAdd2Library.TabIndex = 21;
@@ -589,55 +643,25 @@ private void InitializeComponent()
this.btAdd2Library.UseVisualStyleBackColor = true;
this.btAdd2Library.Click += new System.EventHandler(this.buttonAdd2Library_Click);
//
- // btNamingPattern2
+ // BtSaveOTSPreset
//
- this.btNamingPattern2.Location = new System.Drawing.Point(50, 44);
- this.btNamingPattern2.Name = "btNamingPattern2";
- this.btNamingPattern2.Size = new System.Drawing.Size(30, 20);
- this.btNamingPattern2.TabIndex = 44;
- this.btNamingPattern2.TabStop = false;
- this.btNamingPattern2.Text = "G2";
- this.btNamingPattern2.UseVisualStyleBackColor = true;
+ this.BtSaveOTSPreset.Location = new System.Drawing.Point(139, 70);
+ this.BtSaveOTSPreset.Name = "BtSaveOTSPreset";
+ this.BtSaveOTSPreset.Size = new System.Drawing.Size(84, 20);
+ this.BtSaveOTSPreset.TabIndex = 49;
+ this.BtSaveOTSPreset.Text = "Save Preset";
+ this.BtSaveOTSPreset.UseVisualStyleBackColor = true;
+ this.BtSaveOTSPreset.Click += new System.EventHandler(this.BtSaveOTSPreset_Click);
//
- // btNamingPattern3
+ // BtApplyOTSPreset
//
- this.btNamingPattern3.Location = new System.Drawing.Point(85, 44);
- this.btNamingPattern3.Name = "btNamingPattern3";
- this.btNamingPattern3.Size = new System.Drawing.Size(30, 20);
- this.btNamingPattern3.TabIndex = 45;
- this.btNamingPattern3.TabStop = false;
- this.btNamingPattern3.Text = "G3";
- this.btNamingPattern3.UseVisualStyleBackColor = true;
- //
- // btNamingPattern4
- //
- this.btNamingPattern4.Location = new System.Drawing.Point(120, 44);
- this.btNamingPattern4.Name = "btNamingPattern4";
- this.btNamingPattern4.Size = new System.Drawing.Size(30, 20);
- this.btNamingPattern4.TabIndex = 46;
- this.btNamingPattern4.TabStop = false;
- this.btNamingPattern4.Text = "G4";
- this.btNamingPattern4.UseVisualStyleBackColor = true;
- //
- // btNamingPattern5
- //
- this.btNamingPattern5.Location = new System.Drawing.Point(155, 44);
- this.btNamingPattern5.Name = "btNamingPattern5";
- this.btNamingPattern5.Size = new System.Drawing.Size(30, 20);
- this.btNamingPattern5.TabIndex = 47;
- this.btNamingPattern5.TabStop = false;
- this.btNamingPattern5.Text = "G5";
- this.btNamingPattern5.UseVisualStyleBackColor = true;
- //
- // btNamingPattern6
- //
- this.btNamingPattern6.Location = new System.Drawing.Point(190, 44);
- this.btNamingPattern6.Name = "btNamingPattern6";
- this.btNamingPattern6.Size = new System.Drawing.Size(33, 20);
- this.btNamingPattern6.TabIndex = 48;
- this.btNamingPattern6.TabStop = false;
- this.btNamingPattern6.Text = "G6";
- this.btNamingPattern6.UseVisualStyleBackColor = true;
+ this.BtApplyOTSPreset.Location = new System.Drawing.Point(50, 70);
+ this.BtApplyOTSPreset.Name = "BtApplyOTSPreset";
+ this.BtApplyOTSPreset.Size = new System.Drawing.Size(83, 20);
+ this.BtApplyOTSPreset.TabIndex = 50;
+ this.BtApplyOTSPreset.Text = "Preset OTS";
+ this.BtApplyOTSPreset.UseVisualStyleBackColor = true;
+ this.BtApplyOTSPreset.Click += new System.EventHandler(this.BtApplyOTSPreset_Click);
//
// CreatureInfoInput
//
@@ -645,7 +669,7 @@ private void InitializeComponent()
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.gbCreatureInfo);
this.Name = "CreatureInfoInput";
- this.Size = new System.Drawing.Size(229, 518);
+ this.Size = new System.Drawing.Size(229, 542);
this.gbCreatureInfo.ResumeLayout(false);
this.gbCreatureInfo.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.nudMutationsFather)).EndInit();
@@ -706,5 +730,7 @@ private void InitializeComponent()
private System.Windows.Forms.Button btNamingPattern4;
private System.Windows.Forms.Button btNamingPattern3;
private System.Windows.Forms.Button btNamingPattern2;
+ private System.Windows.Forms.Button BtApplyOTSPreset;
+ private System.Windows.Forms.Button BtSaveOTSPreset;
}
}
diff --git a/ARKBreedingStats/CreatureInfoInput.cs b/ARKBreedingStats/CreatureInfoInput.cs
index a7b17f7b..23c214a4 100644
--- a/ARKBreedingStats/CreatureInfoInput.cs
+++ b/ARKBreedingStats/CreatureInfoInput.cs
@@ -407,7 +407,7 @@ public int[] RegionColors
{
if (selectedSpecies != null)
{
- regionColorIDs = (int[])value.Clone();
+ regionColorIDs = (int[])value?.Clone() ?? new int[6];
regionColorChooser1.SetSpecies(selectedSpecies, regionColorIDs);
}
}
@@ -517,6 +517,7 @@ private void SetCreatureData(Creature cr)
cr.tribe = CreatureTribe;
cr.server = CreatureServer;
cr.flags = CreatureFlags;
+ cr.colors = RegionColors;
}
private void textBoxOwner_Leave(object sender, EventArgs e)
@@ -649,6 +650,20 @@ private void NudMutations_ValueChanged(object sender, EventArgs e)
CalculateNewMutations();
}
+ private void BtSaveOTSPreset_Click(object sender, EventArgs e)
+ {
+ Properties.Settings.Default.DefaultOwnerName = CreatureOwner;
+ Properties.Settings.Default.DefaultTribeName = CreatureTribe;
+ Properties.Settings.Default.DefaultServerName = CreatureServer;
+ }
+
+ private void BtApplyOTSPreset_Click(object sender, EventArgs e)
+ {
+ CreatureOwner = Properties.Settings.Default.DefaultOwnerName;
+ CreatureTribe = Properties.Settings.Default.DefaultTribeName;
+ CreatureServer = Properties.Settings.Default.DefaultServerName;
+ }
+
internal void Clear()
{
textBoxName.Clear();
diff --git a/ARKBreedingStats/Form1.Designer.cs b/ARKBreedingStats/Form1.Designer.cs
index a3682e6f..e2d62712 100644
--- a/ARKBreedingStats/Form1.Designer.cs
+++ b/ARKBreedingStats/Form1.Designer.cs
@@ -1374,7 +1374,7 @@ private void InitializeComponent()
this.tabControlMain.Location = new System.Drawing.Point(0, 103);
this.tabControlMain.Name = "tabControlMain";
this.tabControlMain.SelectedIndex = 1;
- this.tabControlMain.Size = new System.Drawing.Size(1232, 716);
+ this.tabControlMain.Size = new System.Drawing.Size(1232, 756);
this.tabControlMain.TabIndex = 3;
this.tabControlMain.SelectedIndexChanged += new System.EventHandler(this.tabControl1_SelectedIndexChanged);
//
@@ -1391,7 +1391,7 @@ private void InitializeComponent()
this.tabPageStatTesting.Location = new System.Drawing.Point(4, 22);
this.tabPageStatTesting.Name = "tabPageStatTesting";
this.tabPageStatTesting.Padding = new System.Windows.Forms.Padding(3);
- this.tabPageStatTesting.Size = new System.Drawing.Size(1224, 690);
+ this.tabPageStatTesting.Size = new System.Drawing.Size(1224, 730);
this.tabPageStatTesting.TabIndex = 1;
this.tabPageStatTesting.Text = "Stat Testing";
this.tabPageStatTesting.UseVisualStyleBackColor = true;
@@ -1623,7 +1623,7 @@ private void InitializeComponent()
0,
0,
0};
- this.creatureInfoInputTester.Size = new System.Drawing.Size(229, 518);
+ this.creatureInfoInputTester.Size = new System.Drawing.Size(229, 542);
this.creatureInfoInputTester.TabIndex = 4;
this.creatureInfoInputTester.TribeLock = false;
this.creatureInfoInputTester.Add2Library_Clicked += new System.Action(this.creatureInfoInputTester_Add2Library_Clicked);
@@ -1652,7 +1652,7 @@ private void InitializeComponent()
this.tabPageExtractor.Location = new System.Drawing.Point(4, 22);
this.tabPageExtractor.Name = "tabPageExtractor";
this.tabPageExtractor.Padding = new System.Windows.Forms.Padding(3);
- this.tabPageExtractor.Size = new System.Drawing.Size(1224, 690);
+ this.tabPageExtractor.Size = new System.Drawing.Size(1224, 730);
this.tabPageExtractor.TabIndex = 0;
this.tabPageExtractor.Text = "Extractor";
this.tabPageExtractor.UseVisualStyleBackColor = true;
@@ -1854,7 +1854,7 @@ private void InitializeComponent()
0,
0,
0};
- this.creatureInfoInputExtractor.Size = new System.Drawing.Size(229, 518);
+ this.creatureInfoInputExtractor.Size = new System.Drawing.Size(229, 542);
this.creatureInfoInputExtractor.TabIndex = 7;
this.creatureInfoInputExtractor.TribeLock = false;
this.creatureInfoInputExtractor.Add2Library_Clicked += new System.Action(this.creatureInfoInputExtractor_Add2Library_Clicked);
@@ -2548,7 +2548,7 @@ private void InitializeComponent()
this.toolStripSeparator14,
this.toolStripMenuItemRemove});
this.contextMenuStripLibrary.Name = "contextMenuStripLibrary";
- this.contextMenuStripLibrary.Size = new System.Drawing.Size(259, 364);
+ this.contextMenuStripLibrary.Size = new System.Drawing.Size(259, 342);
this.contextMenuStripLibrary.Opening += new System.ComponentModel.CancelEventHandler(this.contextMenuStripLibrary_Opening);
//
// toolStripMenuItemEdit
@@ -3002,7 +3002,7 @@ private void InitializeComponent()
this.statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.toolStripProgressBar1,
this.toolStripStatusLabel});
- this.statusStrip1.Location = new System.Drawing.Point(0, 819);
+ this.statusStrip1.Location = new System.Drawing.Point(0, 859);
this.statusStrip1.Name = "statusStrip1";
this.statusStrip1.Size = new System.Drawing.Size(1232, 22);
this.statusStrip1.TabIndex = 44;
@@ -3352,7 +3352,7 @@ private void InitializeComponent()
this.speciesSelector1.LastSpecies = new string[0];
this.speciesSelector1.Location = new System.Drawing.Point(0, 103);
this.speciesSelector1.Name = "speciesSelector1";
- this.speciesSelector1.Size = new System.Drawing.Size(1232, 716);
+ this.speciesSelector1.Size = new System.Drawing.Size(1232, 756);
this.speciesSelector1.SplitterDistance = 500;
this.speciesSelector1.TabIndex = 0;
//
@@ -3376,7 +3376,7 @@ private void InitializeComponent()
this.AllowDrop = true;
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(1232, 841);
+ this.ClientSize = new System.Drawing.Size(1232, 881);
this.Controls.Add(this.tabControlMain);
this.Controls.Add(this.speciesSelector1);
this.Controls.Add(this.panelToolBar);
diff --git a/ARKBreedingStats/Form1.collection.cs b/ARKBreedingStats/Form1.collection.cs
index ab41cce7..55c2d06e 100644
--- a/ARKBreedingStats/Form1.collection.cs
+++ b/ARKBreedingStats/Form1.collection.cs
@@ -230,12 +230,7 @@ private bool LoadCollectionFile(string filePath, bool keepCurrentCreatures = fal
return false;
}
- List oldCreatures = null;
- if (keepCurrentCreatures)
- oldCreatures = creatureCollection.creatures;
-
- // for the case the collectionfile has no multipliers, keep the current ones
- ServerMultipliers oldMultipliers = creatureCollection.serverMultipliers;
+ CreatureCollection previouslyLoadedCreatureCollection = creatureCollection;
// Wait until the file is readable
const int numberOfRetries = 5;
@@ -378,7 +373,7 @@ private bool LoadCollectionFile(string filePath, bool keepCurrentCreatures = fal
if (creatureCollection.serverMultipliers == null)
{
- creatureCollection.serverMultipliers = oldMultipliers ?? Values.V.serverMultipliersPresets.GetPreset(ServerMultipliersPresets.OFFICIAL);
+ creatureCollection.serverMultipliers = previouslyLoadedCreatureCollection.serverMultipliers ?? Values.V.serverMultipliersPresets.GetPreset(ServerMultipliersPresets.OFFICIAL);
}
if (speciesSelector1.LastSpecies != null && speciesSelector1.LastSpecies.Length > 0)
@@ -393,7 +388,10 @@ private bool LoadCollectionFile(string filePath, bool keepCurrentCreatures = fal
bool creatureWasAdded = false;
if (keepCurrentCreatures)
- creatureWasAdded = creatureCollection.MergeCreatureList(oldCreatures);
+ {
+ creatureWasAdded = previouslyLoadedCreatureCollection.MergeCreatureList(creatureCollection.creatures);
+ creatureCollection = previouslyLoadedCreatureCollection;
+ }
else
{
currentFileName = filePath;
diff --git a/ARKBreedingStats/Form1.cs b/ARKBreedingStats/Form1.cs
index 6a66cdc1..5d295bbc 100644
--- a/ARKBreedingStats/Form1.cs
+++ b/ARKBreedingStats/Form1.cs
@@ -403,6 +403,7 @@ private void Form1_Load(object sender, EventArgs e)
// default owner and tribe
creatureInfoInputExtractor.CreatureOwner = Properties.Settings.Default.DefaultOwnerName;
creatureInfoInputExtractor.CreatureTribe = Properties.Settings.Default.DefaultTribeName;
+ creatureInfoInputExtractor.CreatureServer = Properties.Settings.Default.DefaultServerName;
creatureInfoInputExtractor.OwnerLock = Properties.Settings.Default.OwnerNameLocked;
creatureInfoInputExtractor.TribeLock = Properties.Settings.Default.TribeNameLocked;
@@ -630,7 +631,7 @@ private void SpeciesSelector1_onSpeciesChanged(bool speciesChanged)
else if (tabControlMain.SelectedTab == tabPageLibrary)
{
if (Properties.Settings.Default.ApplyGlobalSpeciesToLibrary)
- listBoxSpeciesLib.SelectedIndex = listBoxSpeciesLib.Items.IndexOf(species);
+ listBoxSpeciesLib.SelectedItem = species;
}
else if (tabControlMain.SelectedTab == tabPageTaming)
{
@@ -757,7 +758,7 @@ private void ApplySettingsToValues()
ATImportExportedFolderLocation aTImportExportedFolderLocation = ATImportExportedFolderLocation.CreateFromString(f);
string menuItemHeader = string.IsNullOrEmpty(aTImportExportedFolderLocation.ConvenientName) ? "" : aTImportExportedFolderLocation.ConvenientName;
ToolStripMenuItem tsmi = new ToolStripMenuItem(menuItemHeader
- + (string.IsNullOrEmpty(aTImportExportedFolderLocation.OwnerSuffix) ? "" : " - " + aTImportExportedFolderLocation.OwnerSuffix))
+ + (string.IsNullOrEmpty(aTImportExportedFolderLocation.OwnerSuffix) ? string.Empty : " - " + aTImportExportedFolderLocation.OwnerSuffix))
{
Tag = aTImportExportedFolderLocation
};
@@ -786,7 +787,7 @@ private void ApplySettingsToValues()
{
Tag = atImportFileLocation
};
- tsmi.Click += RunSavegameImport;
+ tsmi.Click += SavegameImportClick;
importingFromSavegameToolStripMenuItem.DropDownItems.Add(tsmi);
}
}
@@ -1195,8 +1196,11 @@ private void LoadListViewSettings(ListView lv, string widthName, string indicesN
// load column display indices
if (Properties.Settings.Default[indicesName] is int[] colIndices)
{
- for (int c = 0; c < colIndices.Length && c < lv.Columns.Count; c++)
- lv.Columns[c].DisplayIndex = colIndices[c];
+ // indices have to be set increasingly, or they will "push" other values up
+ var colIndicesOrdered = colIndices.Select((i, c) => (columnIndex: c, displayIndex: i))
+ .OrderBy(c => c.displayIndex).ToArray();
+ for (int c = 0; c < colIndicesOrdered.Length && c < lv.Columns.Count; c++)
+ lv.Columns[colIndicesOrdered[c].columnIndex].DisplayIndex = colIndicesOrdered[c].displayIndex;
}
// load listviewLibSorting
@@ -1248,9 +1252,7 @@ private void Form1_FormClosed(object sender, FormClosedEventArgs e)
// save onlyNonMutatedInBreedingPlanner
Properties.Settings.Default.MutationLimitBreedingPlanner = breedingPlan1.MutationLimit;
- // save default owner and tribe name and if they're locked
- Properties.Settings.Default.DefaultOwnerName = creatureInfoInputExtractor.CreatureOwner;
- Properties.Settings.Default.DefaultTribeName = creatureInfoInputExtractor.CreatureTribe;
+ // save locked state of owner and tribe name
Properties.Settings.Default.OwnerNameLocked = creatureInfoInputExtractor.OwnerLock;
Properties.Settings.Default.TribeNameLocked = creatureInfoInputExtractor.TribeLock;
@@ -1391,6 +1393,7 @@ private void checkBoxUseFiltersInTopStatCalculation_CheckedChanged(object sender
private void listBoxSpeciesLib_SelectedIndexChanged(object sender, EventArgs e)
{
+ SetSpecies(listBoxSpeciesLib.SelectedItem as Species);
FilterLib();
}
@@ -3254,6 +3257,12 @@ private void Form1_DragDrop(object sender, DragEventArgs e)
LoadCollectionFile(filePath);
}
}
+ else if (ext == ".ark")
+ {
+ if (MessageBox.Show($"Import all of the creatures in the following ARK save file to the currently opened library?\n{filePath}",
+ "Import savefile?", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
+ RunSavegameImport(new ATImportFileLocation(null, null, filePath));
+ }
else
DoOCR(files[0]);
}
@@ -3345,10 +3354,11 @@ private void openJsonDataFolderToolStripMenuItem_Click(object sender, EventArgs
private void ReloadNamePatternCustomReplacings(PatternEditor pe = null)
{
string filePath = FileService.GetJsonPath(FileService.CustomReplacingsNamePattern);
- if (!FileService.LoadJSONFile(filePath, out customReplacingsNamingPattern, out string error))
+ string errorMessage = null;
+ if (!File.Exists(filePath) || !FileService.LoadJSONFile(filePath, out customReplacingsNamingPattern, out errorMessage))
{
- if (!string.IsNullOrEmpty(error))
- MessageBox.Show(error, "ASB Custom replacings file loading error", MessageBoxButtons.OK, MessageBoxIcon.Error);
+ if (!string.IsNullOrEmpty(errorMessage))
+ MessageBox.Show(errorMessage, "ASB Custom replacings file loading error", MessageBoxButtons.OK, MessageBoxIcon.Error);
}
else if (pe != null) pe.SetCustomReplacings(customReplacingsNamingPattern);
}
diff --git a/ARKBreedingStats/Form1.importSave.cs b/ARKBreedingStats/Form1.importSave.cs
index 7956f54c..8166fe71 100644
--- a/ARKBreedingStats/Form1.importSave.cs
+++ b/ARKBreedingStats/Form1.importSave.cs
@@ -7,7 +7,6 @@
using System.IO;
using System.IO.Compression;
using System.Linq;
-using System.Text;
using System.Text.RegularExpressions;
using System.Threading;
using System.Threading.Tasks;
@@ -17,12 +16,19 @@ namespace ARKBreedingStats
{
public partial class Form1
{
- private async void RunSavegameImport(object sender, EventArgs e)
+ private void SavegameImportClick(object sender, EventArgs e)
+ {
+ RunSavegameImport((ATImportFileLocation)((ToolStripMenuItem)sender).Tag);
+ }
+
+ ///
+ /// Imports the creatures from the given savegame. ftp is possible.
+ ///
+ ///
+ private async void RunSavegameImport(ATImportFileLocation atImportFileLocation)
{
try
{
- ATImportFileLocation atImportFileLocation = (ATImportFileLocation)((ToolStripMenuItem)sender).Tag;
-
string workingCopyfilename = Properties.Settings.Default.savegameExtractionPath;
// working dir not configured? use temp dir
diff --git a/ARKBreedingStats/Form1.library.cs b/ARKBreedingStats/Form1.library.cs
index 340ef451..727a2339 100644
--- a/ARKBreedingStats/Form1.library.cs
+++ b/ARKBreedingStats/Form1.library.cs
@@ -102,7 +102,7 @@ private void AddCreatureToCollection(bool fromExtractor = true, long motherArkId
&& creatureCollection.DeletedCreatureGuids.Contains(creature.guid))
creatureCollection.DeletedCreatureGuids.RemoveAll(guid => guid == creature.guid);
- creatureCollection.MergeCreatureList(new List { creature }, update: true);
+ creatureCollection.MergeCreatureList(new List { creature });
// if creature already exists by guid, use the already existing creature object for the parent assignments
creature = creatureCollection.creatures.SingleOrDefault(c => c.guid == creature.guid) ?? creature;
@@ -894,7 +894,7 @@ private void CooldownColors(Creature c, out Color forecolor, out Color backcolor
private void listView_ColumnClick(object sender, ColumnClickEventArgs e)
{
- ListViewColumnSorter.doSort((ListView)sender, e.Column);
+ ListViewColumnSorter.DoSort((ListView)sender, e.Column);
}
// onlibrarychange
@@ -1046,10 +1046,9 @@ private void FilterLib()
// if only one species should be shown adjust statnames if the selected species is a glow-species
bool chargeStatsHeaders = false;
if (listBoxSpeciesLib.SelectedIndex > 0
- && listBoxSpeciesLib.SelectedItem.GetType() == typeof(Species))
+ && listBoxSpeciesLib.SelectedItem is Species selectedSpecies)
{
- Species selectedSpecies = listBoxSpeciesLib.SelectedItem as Species;
- filteredList = filteredList.Where(c => c.Species == selectedSpecies);
+ filteredList = filteredList.Where(c => c.Species.Equals(selectedSpecies));
if (selectedSpecies.IsGlowSpecies)
chargeStatsHeaders = true;
}
diff --git a/ARKBreedingStats/ImportSavegame.cs b/ARKBreedingStats/ImportSavegame.cs
index cc1fe937..6b908ba5 100644
--- a/ARKBreedingStats/ImportSavegame.cs
+++ b/ARKBreedingStats/ImportSavegame.cs
@@ -122,27 +122,14 @@ private static void ImportCollection(CreatureCollection creatureCollection, List
var removedCreatures = creatureCollection.creatures.Where(c => c.status == CreatureStatus.Available && c.server == serverName).Except(newCreatures);
foreach (var c in removedCreatures)
c.status = CreatureStatus.Unavailable;
-
- // mark creatures that re-appear as available (due to server transfer / obelisk / etc)
- var readdedCreatures = creatureCollection.creatures.Where(c => c.status == CreatureStatus.Unavailable || c.status == CreatureStatus.Obelisk).Intersect(newCreatures);
- foreach (var c in readdedCreatures)
- c.status = CreatureStatus.Available;
}
- // update creature status that can be determined from the import
- var creaturesNowInPods = creatureCollection.creatures.Intersect(newCreatures.Where(c => c.status == CreatureStatus.Cryopod));
- foreach (var c in creaturesNowInPods)
- c.status = CreatureStatus.Cryopod;
- var creaturesNowOutOfPods = creatureCollection.creatures.Where(c => c.status == CreatureStatus.Cryopod).Intersect(newCreatures.Where(c => c.status != CreatureStatus.Cryopod));
- foreach (var c in creaturesNowInPods)
- c.status = CreatureStatus.Available;
-
newCreatures.ForEach(creature =>
{
creature.server = serverName;
});
- creatureCollection.MergeCreatureList(newCreatures, true, false, true);
+ creatureCollection.MergeCreatureList(newCreatures, addPreviouslylDeletedCreatures: true);
}
private Creature ConvertGameObject(GameObject creatureObject, int? levelStep)
@@ -242,11 +229,6 @@ private Creature ConvertGameObject(GameObject creatureObject, int? levelStep)
creature.status = CreatureStatus.Dead; // dead is always dead
}
- if (!isDead && creature.status == CreatureStatus.Dead)
- {
- creature.status = CreatureStatus.Unavailable; // if found alive when marked dead, mark as unavailable
- }
-
if (creatureObject.IsCryo)
creature.status = CreatureStatus.Cryopod;
diff --git a/ARKBreedingStats/ListViewColumnSorter.cs b/ARKBreedingStats/ListViewColumnSorter.cs
index 76c9f3c7..66bc68a6 100644
--- a/ARKBreedingStats/ListViewColumnSorter.cs
+++ b/ARKBreedingStats/ListViewColumnSorter.cs
@@ -14,21 +14,22 @@ public class ListViewColumnSorter : IComparer
///
/// Specifies the last column to be sorted (is used for sorting when current compare is equal)
///
- public int LastSortColumn { set; get; }
+ private int _lastSortColumn;
///
/// Gets or sets the order of sorting to apply (for example, 'Ascending' or 'Descending').
///
public SortOrder Order { set; get; }
+
///
/// Gets or sets the order of the last column sorting (for example, 'Ascending' or 'Descending').
///
- public SortOrder LastOrder { set; get; }
+ private SortOrder _lastOrder;
///
/// Case insensitive comparer object
///
- private CaseInsensitiveComparer ObjectCompare;
+ private readonly CaseInsensitiveComparer _objectCompare;
///
/// Class constructor. Initializes various elements
@@ -37,13 +38,13 @@ public ListViewColumnSorter()
{
// Initialize the column to '0'
SortColumn = 0;
- LastSortColumn = 0;
+ _lastSortColumn = 0;
// Initialize the sort order to 'none'
Order = SortOrder.None;
// Initialize the CaseInsensitiveComparer object
- ObjectCompare = new CaseInsensitiveComparer();
+ _objectCompare = new CaseInsensitiveComparer();
}
///
@@ -57,21 +58,25 @@ public int Compare(object x, object y)
int compareResult;
// Cast the objects to be compared to ListViewItem objects
- ListViewItem listviewX = (ListViewItem)x;
- ListViewItem listviewY = (ListViewItem)y;
+ if (!(x is ListViewItem listViewX
+ && y is ListViewItem listViewY))
+ {
+ return 0;
+ }
+
double c1, c2;
- if (listviewX.SubItems.Count <= SortColumn) SortColumn = 0;
+ if (listViewX.SubItems.Count <= SortColumn) SortColumn = 0;
// Compare the two items
- if ((listviewX.SubItems[SortColumn].Text + listviewY.SubItems[SortColumn].Text).Length == 0)
+ if ((listViewX.SubItems[SortColumn].Text + listViewY.SubItems[SortColumn].Text).Length == 0)
compareResult = 0;
else
{
- compareResult = double.TryParse(listviewX.SubItems[SortColumn].Text, out c1) &&
- double.TryParse(listviewY.SubItems[SortColumn].Text, out c2) ?
+ compareResult = double.TryParse(listViewX.SubItems[SortColumn].Text, out c1) &&
+ double.TryParse(listViewY.SubItems[SortColumn].Text, out c2) ?
Math.Sign(c1 - c2) :
- ObjectCompare.Compare(listviewX.SubItems[SortColumn].Text, listviewY.SubItems[SortColumn].Text);
+ _objectCompare.Compare(listViewX.SubItems[SortColumn].Text, listViewY.SubItems[SortColumn].Text);
// if descending sort is selected, return negative result of compare operation
if (Order == SortOrder.Descending)
@@ -81,15 +86,15 @@ public int Compare(object x, object y)
// if comparing is 0 (items equal), use LastColumnToSort
if (compareResult == 0)
{
- if (listviewX.SubItems.Count <= LastSortColumn) LastSortColumn = 0;
+ if (listViewX.SubItems.Count <= _lastSortColumn) _lastSortColumn = 0;
// Compare the two items
// the first two columns are text, the others are int as string
- compareResult = double.TryParse(listviewX.SubItems[LastSortColumn].Text, out c1) &&
- double.TryParse(listviewY.SubItems[LastSortColumn].Text, out c2) ?
+ compareResult = double.TryParse(listViewX.SubItems[_lastSortColumn].Text, out c1) &&
+ double.TryParse(listViewY.SubItems[_lastSortColumn].Text, out c2) ?
Math.Sign(c1 - c2) :
- ObjectCompare.Compare(listviewX.SubItems[LastSortColumn].Text, listviewY.SubItems[LastSortColumn].Text);
+ _objectCompare.Compare(listViewX.SubItems[_lastSortColumn].Text, listViewY.SubItems[_lastSortColumn].Text);
// if descending sort is selected, return negative result of compare operation
- if (LastOrder == SortOrder.Descending)
+ if (_lastOrder == SortOrder.Descending)
compareResult = -compareResult;
}
@@ -97,22 +102,22 @@ public int Compare(object x, object y)
// Return '0' to indicate they are equal
}
- public static void doSort(ListView lw, int column)
+ public static void DoSort(ListView lw, int column)
{
- ListViewColumnSorter lwcs = (ListViewColumnSorter)lw.ListViewItemSorter;
+ if (!(lw.ListViewItemSorter is ListViewColumnSorter lvcs)) return;
// Determine if clicked column is already the column that is being sorted.
- if (column == lwcs.SortColumn)
+ if (column == lvcs.SortColumn)
{
// Reverse the current sort direction for this column.
- lwcs.Order = lwcs.Order == SortOrder.Ascending ? SortOrder.Descending : SortOrder.Ascending;
+ lvcs.Order = lvcs.Order == SortOrder.Ascending ? SortOrder.Descending : SortOrder.Ascending;
}
else
{
// Set the column number that is to be sorted; default to descending (except the name and owner column).
- lwcs.LastSortColumn = lwcs.SortColumn;
- lwcs.LastOrder = lwcs.Order;
- lwcs.SortColumn = column;
- lwcs.Order = column > 1 ? SortOrder.Descending : SortOrder.Ascending;
+ lvcs._lastSortColumn = lvcs.SortColumn;
+ lvcs._lastOrder = lvcs.Order;
+ lvcs.SortColumn = column;
+ lvcs.Order = column > 1 ? SortOrder.Descending : SortOrder.Ascending;
}
// Perform the sort with these new sort options.
diff --git a/ARKBreedingStats/Pedigree.cs b/ARKBreedingStats/Pedigree.cs
index 4aa17bf4..e549d565 100644
--- a/ARKBreedingStats/Pedigree.cs
+++ b/ARKBreedingStats/Pedigree.cs
@@ -381,7 +381,7 @@ public void UpdateListView()
private void listViewCreatures_ColumnClick(object sender, ColumnClickEventArgs e)
{
- ListViewColumnSorter.doSort((ListView)sender, e.Column);
+ ListViewColumnSorter.DoSort((ListView)sender, e.Column);
}
public void SetLocalizations()
diff --git a/ARKBreedingStats/Properties/AssemblyInfo.cs b/ARKBreedingStats/Properties/AssemblyInfo.cs
index 8f0cfed7..c2018324 100644
--- a/ARKBreedingStats/Properties/AssemblyInfo.cs
+++ b/ARKBreedingStats/Properties/AssemblyInfo.cs
@@ -30,6 +30,6 @@
// Revision
//
[assembly: AssemblyVersion("1.0.0.0")]
-[assembly: AssemblyFileVersion("0.39.5.0")]
+[assembly: AssemblyFileVersion("0.39.6.0")]
[assembly: NeutralResourcesLanguage("en")]
diff --git a/ARKBreedingStats/Properties/Settings.Designer.cs b/ARKBreedingStats/Properties/Settings.Designer.cs
index 5a606790..497aa145 100644
--- a/ARKBreedingStats/Properties/Settings.Designer.cs
+++ b/ARKBreedingStats/Properties/Settings.Designer.cs
@@ -544,6 +544,18 @@ public bool TribeNameLocked {
}
}
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Configuration.DefaultSettingValueAttribute("")]
+ public string DefaultServerName {
+ get {
+ return ((string)(this["DefaultServerName"]));
+ }
+ set {
+ this["DefaultServerName"] = value;
+ }
+ }
+
[global::System.Configuration.UserScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("False")]
diff --git a/ARKBreedingStats/Properties/Settings.settings b/ARKBreedingStats/Properties/Settings.settings
index cba64acc..05829ae9 100644
--- a/ARKBreedingStats/Properties/Settings.settings
+++ b/ARKBreedingStats/Properties/Settings.settings
@@ -134,6 +134,9 @@
False
+
+
+
False
diff --git a/ARKBreedingStats/SpeciesSelector.cs b/ARKBreedingStats/SpeciesSelector.cs
index bf1231e9..fbd3ebbb 100644
--- a/ARKBreedingStats/SpeciesSelector.cs
+++ b/ARKBreedingStats/SpeciesSelector.cs
@@ -213,7 +213,8 @@ public void SetSpeciesByName(string speciesName)
public void SetSpecies(Species species)
{
- if (species == null) return;
+ if (species == null
+ || SelectedSpecies == species) return;
lastSpeciesBPs.Remove(species.blueprintPath);
if (lastSpeciesBPs.Count > keepNrLastSpecies) // only keep keepNrLastSpecies of the last species in this list
diff --git a/ARKBreedingStats/TimerControl.cs b/ARKBreedingStats/TimerControl.cs
index 62c08671..5303d5f1 100644
--- a/ARKBreedingStats/TimerControl.cs
+++ b/ARKBreedingStats/TimerControl.cs
@@ -381,7 +381,7 @@ public ListViewColumnSorter ColumnSorter
private void listViewTimer_ColumnClick(object sender, ColumnClickEventArgs e)
{
- ListViewColumnSorter.doSort((ListView)sender, e.Column);
+ ListViewColumnSorter.DoSort((ListView)sender, e.Column);
}
public enum TimerGroups
diff --git a/ARKBreedingStats/TribesControl.cs b/ARKBreedingStats/TribesControl.cs
index 443172e0..7a6e6e10 100644
--- a/ARKBreedingStats/TribesControl.cs
+++ b/ARKBreedingStats/TribesControl.cs
@@ -26,7 +26,7 @@ public TribesControl()
private void listView_ColumnClick(object sender, ColumnClickEventArgs e)
{
- ListViewColumnSorter.doSort((ListView)sender, e.Column);
+ ListViewColumnSorter.DoSort((ListView)sender, e.Column);
}
public List Players
diff --git a/ARKBreedingStats/json/values/_manifest.json b/ARKBreedingStats/json/values/_manifest.json
index 3e4ae1d0..aec14291 100644
--- a/ARKBreedingStats/json/values/_manifest.json
+++ b/ARKBreedingStats/json/values/_manifest.json
@@ -18,7 +18,8 @@
"mod": { "id": "111111111", "tag": "PrimitivePlus", "title": "PrimitivePlus" }
},
"1125442531-Gaia.json": {
- "version": "310.36.1587342854",
+ "version": "310.77.1589030706",
+ "format": "1.13",
"mod": { "id": "1125442531", "tag": "Gaia", "title": "Gaia" }
},
"1136390783-PhoenixBreeding.json": {
@@ -70,11 +71,13 @@
"mod": { "id": "1522327484", "tag": "Additions_Pack", "title": "ARK Additions!" }
},
"1523045986-Paranoia.json": {
- "version": "309.53.1586276630",
+ "version": "310.62.1588570766",
+ "format": "1.13",
"mod": { "id": "1523045986", "tag": "Paranoia", "title": "Additional Creatures 2: Paranoia!" }
},
"1565015734-BetterDinosTest.json": {
- "version": "310.41.1587774145",
+ "version": "310.62.1588873988",
+ "format": "1.13",
"mod": { "id": "1565015734", "tag": "BetterDinosTest", "title": "Better Dinos" }
},
"1576299694-ElementalDinos.json": {
@@ -98,11 +101,13 @@
"mod": { "id": "1633860796", "tag": "DE_Breedable_RockDrakes", "title": "Dark Edges Breedable Rock Drakes" }
},
"1652120435-AtlasPort.json": {
- "version": "306.83.1569282532",
+ "version": "310.62.1588940053",
+ "format": "1.13",
"mod": { "id": "1652120435", "tag": "AtlasPort", "title": "Shad's Atlas Imports" }
},
"1654255131-AtlasImports.json": {
- "version": "310.41.1587683797",
+ "version": "310.50.1588055957",
+ "format": "1.13",
"mod": { "id": "1654255131", "tag": "AtlasImports", "title": "Animals of Atlas" }
},
"1662691167-Senior.json": {
@@ -110,11 +115,13 @@
"mod": { "id": "1662691167", "tag": "Senior", "title": "Additional Creatures: Senior Class" }
},
"1675895024-NoUntameables.json": {
- "version": "310.36.1587027746",
+ "version": "310.62.1588527963",
+ "format": "1.13",
"mod": { "id": "1675895024", "tag": "NoUntameables", "title": "No Untameables" }
},
"1676159020-Aquaria.json": {
- "version": "307.4.1584246685",
+ "version": "310.62.1588370282",
+ "format": "1.13",
"mod": { "id": "1676159020", "tag": "Aquaria", "title": "Additional Creatures: Aquaria" }
},
"1681125667-Primal_Fear_EX.json": {
@@ -126,7 +133,8 @@
"mod": { "id": "1696957410", "tag": "MarniimodsTest", "title": "Marnii's Equines" }
},
"1729386191-BonusDinoMod.json": {
- "version": "310.36.1587240193",
+ "version": "310.62.1588448169",
+ "format": "1.13",
"mod": { "id": "1729386191", "tag": "BonusDinoMod", "title": "Additional Creatures: Bonus Content" }
},
"1729512589-Brachiosaurus.json": {
@@ -165,9 +173,15 @@
"version": "309.53.1581239136",
"mod": { "id": "1934081600", "tag": "SoloFarmAnky", "title": "Solo Farm Mod" }
},
+ "1984936918-MarniiModsWildlife.json": {
+ "version": "310.77.1589127051",
+ "format": "1.13",
+ "mod": { "id": "1984936918", "tag": "MarniiModsWildlife", "title": "MarniiMods:Wildlife" }
+ },
"2000326197-ExtraResources.json": {
- "version": "309.53.1582726065",
- "mod": { "id": "2000326197", "tag": "ExtraResources", "title": "Extra Resources" }
+ "version": "310.50.1588186841",
+ "format": "1.13",
+ "mod": { "id": "2000326197", "tag": "ExtraResources", "title": "Event Assets" }
},
"729352919-IndomRex.json": {
"version": "306.83.1488771984",
@@ -182,7 +196,8 @@
"mod": { "id": "839162288", "tag": "Primal_Fear", "title": "Primal Fear" }
},
"893735676-AE.json": {
- "version": "310.36.1587436399",
+ "version": "310.62.1588820272",
+ "format": "1.13",
"mod": { "id": "893735676", "tag": "AE", "title": "ARK: Eternal" }
},
"895711211-ClassicFlyers.json": {
@@ -202,7 +217,7 @@
"mod": { "id": "919470289", "tag": "SSFlyer", "title": "SSFlyer" }
},
"values.json": {
- "version": "310.47.4923984",
+ "version": "310.62.4973089",
"format": "1.13"
}
}
diff --git a/ARKBreedingStats/json/values/values.json b/ARKBreedingStats/json/values/values.json
index 7c811573..9d8379cc 100644
--- a/ARKBreedingStats/json/values/values.json
+++ b/ARKBreedingStats/json/values/values.json
@@ -1,5 +1,5 @@
{
- "version": "310.47.4923984",
+ "version": "310.62.4973089",
"format": "1.13",
"species": [
{
@@ -9830,6 +9830,166 @@
"doesNotUseOxygen": false,
"displayedStats": 927
},
+ {
+ "name": "Corrupted Avatar",
+ "blueprintPath": "/Game/Genesis/Dinos/Bots/Bot_Character_BP.Bot_Character_BP",
+ "fullStatsRaw": [
+ [ 100, 0.5, 0.27, 0.5, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.06, 0, 0.5, 0 ],
+ [ 150, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ null,
+ null,
+ [ 100, 0.02, 0.04, 0, 0 ],
+ [ 1, 0.05, 0.1, 0.5, 0.4 ],
+ [ 1, 0, 0.01, 0, 0 ],
+ null,
+ null
+ ],
+ "immobilizedBy": [ "Bola", "Bear Trap", "Plant Species Y" ],
+ "taming": {
+ "nonViolent": false,
+ "violent": false,
+ "tamingIneffectiveness": 20,
+ "affinityNeeded0": 100,
+ "affinityIncreasePL": 5,
+ "foodConsumptionBase": 0.01,
+ "foodConsumptionMult": 0.05
+ },
+ "TamedBaseHealthMultiplier": 1,
+ "NoImprintingForSpeed": false,
+ "doesNotUseOxygen": false,
+ "displayedStats": 927
+ },
+ {
+ "name": "Corrupted Avatar",
+ "blueprintPath": "/Game/Genesis/Dinos/Bots/Bot_WithBow_BP.Bot_WithBow_BP",
+ "fullStatsRaw": [
+ [ 100, 0.5, 0.27, 0.5, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.06, 0, 0.5, 0 ],
+ [ 150, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ null,
+ null,
+ [ 100, 0.02, 0.04, 0, 0 ],
+ [ 1, 0.05, 0.1, 0.5, 0.4 ],
+ [ 1, 0, 0.01, 0, 0 ],
+ null,
+ null
+ ],
+ "immobilizedBy": [ "Bola", "Bear Trap", "Plant Species Y" ],
+ "taming": {
+ "nonViolent": false,
+ "violent": false,
+ "tamingIneffectiveness": 20,
+ "affinityNeeded0": 100,
+ "affinityIncreasePL": 5,
+ "foodConsumptionBase": 0.01,
+ "foodConsumptionMult": 0.05
+ },
+ "TamedBaseHealthMultiplier": 1,
+ "NoImprintingForSpeed": false,
+ "doesNotUseOxygen": false,
+ "displayedStats": 927
+ },
+ {
+ "name": "Corrupted Avatar",
+ "blueprintPath": "/Game/Genesis/Dinos/Bots/Bot_WithSpear_BP.Bot_WithSpear_BP",
+ "fullStatsRaw": [
+ [ 100, 0.5, 0.27, 0.5, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.06, 0, 0.5, 0 ],
+ [ 150, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ null,
+ null,
+ [ 100, 0.02, 0.04, 0, 0 ],
+ [ 1, 0.05, 0.1, 0.5, 0.4 ],
+ [ 1, 0, 0.01, 0, 0 ],
+ null,
+ null
+ ],
+ "immobilizedBy": [ "Bola", "Bear Trap", "Plant Species Y" ],
+ "taming": {
+ "nonViolent": false,
+ "violent": false,
+ "tamingIneffectiveness": 20,
+ "affinityNeeded0": 100,
+ "affinityIncreasePL": 5,
+ "foodConsumptionBase": 0.01,
+ "foodConsumptionMult": 0.05
+ },
+ "TamedBaseHealthMultiplier": 1,
+ "NoImprintingForSpeed": false,
+ "doesNotUseOxygen": false,
+ "displayedStats": 927
+ },
+ {
+ "name": "Corrupted Avatar",
+ "blueprintPath": "/Game/Genesis/Dinos/Bots/Bot_WithTekGrenades_BP.Bot_WithTekGrenades_BP",
+ "fullStatsRaw": [
+ [ 100, 0.5, 0.27, 0.5, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.06, 0, 0.5, 0 ],
+ [ 150, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ null,
+ null,
+ [ 100, 0.02, 0.04, 0, 0 ],
+ [ 1, 0.05, 0.1, 0.5, 0.4 ],
+ [ 1, 0, 0.01, 0, 0 ],
+ null,
+ null
+ ],
+ "immobilizedBy": [ "Bola", "Bear Trap", "Plant Species Y" ],
+ "taming": {
+ "nonViolent": false,
+ "violent": false,
+ "tamingIneffectiveness": 20,
+ "affinityNeeded0": 100,
+ "affinityIncreasePL": 5,
+ "foodConsumptionBase": 0.01,
+ "foodConsumptionMult": 0.05
+ },
+ "TamedBaseHealthMultiplier": 1,
+ "NoImprintingForSpeed": false,
+ "doesNotUseOxygen": false,
+ "displayedStats": 927
+ },
+ {
+ "name": "Corrupted Avatar",
+ "blueprintPath": "/Game/Genesis/Dinos/Bots/Bot_WithTekRifle_BP.Bot_WithTekRifle_BP",
+ "fullStatsRaw": [
+ [ 100, 0.5, 0.27, 0.5, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.06, 0, 0.5, 0 ],
+ [ 150, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ null,
+ null,
+ [ 100, 0.02, 0.04, 0, 0 ],
+ [ 1, 0.05, 0.1, 0.5, 0.4 ],
+ [ 1, 0, 0.01, 0, 0 ],
+ null,
+ null
+ ],
+ "immobilizedBy": [ "Bola", "Bear Trap", "Plant Species Y" ],
+ "taming": {
+ "nonViolent": false,
+ "violent": false,
+ "tamingIneffectiveness": 20,
+ "affinityNeeded0": 100,
+ "affinityIncreasePL": 5,
+ "foodConsumptionBase": 0.01,
+ "foodConsumptionMult": 0.05
+ },
+ "TamedBaseHealthMultiplier": 1,
+ "NoImprintingForSpeed": false,
+ "doesNotUseOxygen": false,
+ "displayedStats": 927
+ },
{
"name": "Magmasaur",
"blueprintPath": "/Game/Genesis/Dinos/Cherufe/Cherufe_Character_BP.Cherufe_Character_BP",
@@ -36917,6 +37077,105 @@
"doesNotUseOxygen": true,
"displayedStats": 919
},
+ {
+ "name": "Corrupted Master Controller",
+ "blueprintPath": "/Game/Genesis/Dinos/VRMainBoss/VRMainBoss_Character_Easy.VRMainBoss_Character_Easy",
+ "variants": [ "Boss", "Gamma", "VR" ],
+ "fullStatsRaw": [
+ [ 25000, 0.2, 0.27, 0.5, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.06, 0, 0.5, 0 ],
+ [ 150, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ null,
+ null,
+ [ 100, 0.02, 0.04, 0, 0 ],
+ [ 1, 0.05, 0.1, 0.5, 0.4 ],
+ [ 1, 0, 0.01, 0, 0 ],
+ null,
+ null
+ ],
+ "immobilizedBy": [],
+ "taming": {
+ "nonViolent": false,
+ "violent": false,
+ "tamingIneffectiveness": 20,
+ "affinityNeeded0": 100,
+ "affinityIncreasePL": 5,
+ "foodConsumptionBase": 0.01,
+ "foodConsumptionMult": 0.05
+ },
+ "TamedBaseHealthMultiplier": 1,
+ "NoImprintingForSpeed": false,
+ "doesNotUseOxygen": false,
+ "displayedStats": 927
+ },
+ {
+ "name": "Corrupted Master Controller",
+ "blueprintPath": "/Game/Genesis/Dinos/VRMainBoss/VRMainBoss_Character_Hard.VRMainBoss_Character_Hard",
+ "variants": [ "Alpha", "Boss", "VR" ],
+ "fullStatsRaw": [
+ [ 150000, 0.2, 0.27, 0.5, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.06, 0, 0.5, 0 ],
+ [ 150, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ null,
+ null,
+ [ 100, 0.02, 0.04, 0, 0 ],
+ [ 1, 0.05, 0.1, 0.5, 0.4 ],
+ [ 1, 0, 0.01, 0, 0 ],
+ null,
+ null
+ ],
+ "immobilizedBy": [],
+ "taming": {
+ "nonViolent": false,
+ "violent": false,
+ "tamingIneffectiveness": 20,
+ "affinityNeeded0": 100,
+ "affinityIncreasePL": 5,
+ "foodConsumptionBase": 0.01,
+ "foodConsumptionMult": 0.05
+ },
+ "TamedBaseHealthMultiplier": 1,
+ "NoImprintingForSpeed": false,
+ "doesNotUseOxygen": false,
+ "displayedStats": 927
+ },
+ {
+ "name": "Corrupted Master Controller",
+ "blueprintPath": "/Game/Genesis/Dinos/VRMainBoss/VRMainBoss_Character_Medium.VRMainBoss_Character_Medium",
+ "variants": [ "Beta", "Boss", "VR" ],
+ "fullStatsRaw": [
+ [ 60000, 0.2, 0.27, 0.5, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.06, 0, 0.5, 0 ],
+ [ 150, 0.1, 0.1, 0, 0 ],
+ [ 100, 0.1, 0.1, 0, 0 ],
+ null,
+ null,
+ [ 100, 0.02, 0.04, 0, 0 ],
+ [ 1, 0.05, 0.1, 0.5, 0.4 ],
+ [ 1, 0, 0.01, 0, 0 ],
+ null,
+ null
+ ],
+ "immobilizedBy": [],
+ "taming": {
+ "nonViolent": false,
+ "violent": false,
+ "tamingIneffectiveness": 20,
+ "affinityNeeded0": 100,
+ "affinityIncreasePL": 5,
+ "foodConsumptionBase": 0.01,
+ "foodConsumptionMult": 0.05
+ },
+ "TamedBaseHealthMultiplier": 1,
+ "NoImprintingForSpeed": false,
+ "doesNotUseOxygen": false,
+ "displayedStats": 927
+ },
{
"name": "Dragon",
"blueprintPath": "/Game/Mods/Ragnarok/Custom_Assets/Bosses/Dragon_Character_BP_Boss_Easy_Ragnarok.Dragon_Character_BP_Boss_Easy_Ragnarok",
@@ -38192,168 +38451,6 @@
"doesNotUseOxygen": true,
"displayedStats": 919
},
- {
- "name": "Ice Wyvern",
- "blueprintPath": "/Game/Mods/Valguero/Assets/Dinos/IceWyvern/Ragnarok_Wyvern_Override_Ice.Ragnarok_Wyvern_Override_Ice",
- "variants": [ "Valguero" ],
- "fullStatsRaw": [
- [ 1725, 0.15, 0.2025, -1050, 0 ],
- [ 275, 0.05, 0.05, 0, 0 ],
- [ 725, 0.06, 0, 0.5, 0 ],
- [ 150, 0.1, 0.1, 0, 0 ],
- [ 2000, 0.1, 0.1, 0, 0 ],
- null,
- null,
- [ 400, 0.02, 0.04, 0, 0 ],
- [ 1, 0.05, 0.1, -0.25, 0.4 ],
- [ 1, 0, 0, 0, 0 ],
- null,
- null
- ],
- "statImprintMult": [ 0.2, 0, 0.2, 0, 0.2, 0.2, 0, 0.2, 0.2, 0, 0, 0 ],
- "immobilizedBy": [ "Chain Bola", "Large Bear Trap" ],
- "breeding": {
- "gestationTime": 0,
- "incubationTime": 17998.5601,
- "eggTempMin": 80,
- "eggTempMax": 90,
- "maturationTime": 333333.333,
- "matingCooldownMin": 64800,
- "matingCooldownMax": 172800
- },
- "colors": [
- {
- "name": "Body Main",
- "colors": [
- "BigFoot4",
- "Dino Albino",
- "Dino Light Blue",
- "Dino Light Green",
- "Dino Light Purple",
- "DragonBlue0",
- "DragonGreen3",
- "Light Grey",
- "NearBlack",
- "WyvernBlue0",
- "WyvernBlue1",
- "WyvernPurple1"
- ]
- },
- {
- "name": "Fins",
- "colors": [
- "Black",
- "Dino Light Blue",
- "DragonBlue0",
- "Light Grey",
- "WyvernBlue0",
- "WyvernBlue1"
- ]
- },
- {
- "name": "Wings",
- "colors": [
- "Dino Dark Purple",
- "Dino Darker Grey",
- "Dino Light Blue",
- "Dino Light Purple",
- "DragonBlue0",
- "Light Grey",
- "WyvernBlue0",
- "WyvernPurple0",
- "WyvernPurple1"
- ]
- },
- null,
- {
- "name": "Scales Belly",
- "colors": [
- "BigFoot0",
- "BigFoot4",
- "Dino Albino",
- "Dino Light Blue",
- "Dino Light Brown",
- "Dino Light Green",
- "Dino Light Purple",
- "DragonBlue0",
- "DragonGreen3",
- "Light Grey",
- "NearBlack",
- "WolfFur",
- "WyvernBlue0",
- "WyvernBlue1"
- ]
- },
- {
- "name": "Scales Top and Fins",
- "colors": [
- "Dino Albino",
- "Dino Light Blue",
- "Dino Light Green",
- "Dino Light Purple",
- "DragonGreen3",
- "Light Grey",
- "NearBlack",
- "WyvernBlue0",
- "WyvernPurple1"
- ]
- }
- ],
- "taming": {
- "nonViolent": false,
- "violent": false,
- "tamingIneffectiveness": 1.5,
- "affinityNeeded0": 8500,
- "affinityIncreasePL": 150,
- "foodConsumptionBase": 0.000185,
- "foodConsumptionMult": 199.984
- },
- "TamedBaseHealthMultiplier": 1,
- "NoImprintingForSpeed": true,
- "doesNotUseOxygen": false,
- "displayedStats": 927
- },
- {
- "name": "Dire Polar Bear",
- "blueprintPath": "/Game/Mods/Valguero/Assets/Dinos/PolarBear/Polar_Bear.Polar_Bear",
- "variants": [ "Valguero" ],
- "fullStatsRaw": [
- [ 400, 0.2, 0.27, 0.5, 0 ],
- [ 500, 0.1, 0.1, 0, 0 ],
- [ 1000, 0.06, 0, 0.5, 0 ],
- [ 270, 0.1, 0.1, 0, 0 ],
- [ 3000, 0.1, 0.1, 0, 0 ],
- null,
- null,
- [ 650, 0.02, 0.04, 0, 0 ],
- [ 1, 0.05, 0.1, 0.5, 0.4 ],
- [ 1, 0, 0.01, 1.226, 0 ],
- null,
- null
- ],
- "immobilizedBy": [ "Chain Bola", "Large Bear Trap" ],
- "breeding": {
- "gestationTime": 14285.7143,
- "incubationTime": 0,
- "maturationTime": 166666.667,
- "matingCooldownMin": 64800,
- "matingCooldownMax": 172800
- },
- "taming": {
- "nonViolent": false,
- "violent": true,
- "tamingIneffectiveness": 1.25,
- "affinityNeeded0": 4000,
- "affinityIncreasePL": 125,
- "torporDepletionPS0": 0.9,
- "foodConsumptionBase": 0.003156,
- "foodConsumptionMult": 150
- },
- "TamedBaseHealthMultiplier": 1,
- "NoImprintingForSpeed": false,
- "doesNotUseOxygen": false,
- "displayedStats": 927
- },
{
"name": "Chalk Golem",
"blueprintPath": "/Game/Mods/Valguero/Assets/Dinos/RockGolem/ChalkGolem/ChalkGolem_Character_BP.ChalkGolem_Character_BP",
diff --git a/ARKBreedingStats/library/CreatureCollection.cs b/ARKBreedingStats/library/CreatureCollection.cs
index cd5e8bd4..0eed34a7 100644
--- a/ARKBreedingStats/library/CreatureCollection.cs
+++ b/ARKBreedingStats/library/CreatureCollection.cs
@@ -153,143 +153,131 @@ public List ModList
/// Adds creatures to the current library.
///
/// List of creatures to add
- /// If true and a creature is already added, its parameters will be updated
- /// If true the creature status will be updated
/// If true creatures will be added even if they were just deleted.
///
- public bool MergeCreatureList(List creaturesToMerge, bool update = false, bool updateStatus = true, bool addPreviouslylDeletedCreatures = false)
+ public bool MergeCreatureList(List creaturesToMerge, bool addPreviouslylDeletedCreatures = false)
{
- bool creaturesWereAdded = false;
- foreach (Creature creature in creaturesToMerge)
+ bool creaturesWereAddedOrUpdated = false;
+ foreach (Creature creatureNew in creaturesToMerge)
{
- if (!addPreviouslylDeletedCreatures && DeletedCreatureGuids != null && DeletedCreatureGuids.Contains(creature.guid)) continue;
+ if (!addPreviouslylDeletedCreatures && DeletedCreatureGuids != null && DeletedCreatureGuids.Contains(creatureNew.guid)) continue;
- if (!creatures.Contains(creature))
+ if (!creatures.Contains(creatureNew))
{
- creatures.Add(creature);
- creaturesWereAdded = true;
+ creatures.Add(creatureNew);
+ creaturesWereAddedOrUpdated = true;
+ continue;
}
- else if (update)
+
+ // creature is already in the library. Update it's properties.
+ var creatureExisting = creatures.Single(c => c.guid == creatureNew.guid);
+ if (creatureExisting.Species == null)
+ creatureExisting.Species = creatureNew.Species;
+ else if (!creatureExisting.Species.Equals(creatureNew.Species)) continue;
+
+ if (creatureNew.Mother != null)
+ creatureExisting.Mother = creatureNew.Mother;
+ else if (creatureNew.motherGuid != Guid.Empty)
+ creatureExisting.motherGuid = creatureNew.motherGuid;
+ if (creatureNew.Father != null)
+ creatureExisting.Father = creatureNew.Father;
+ else if (creatureNew.fatherGuid != Guid.Empty)
+ creatureExisting.fatherGuid = creatureNew.fatherGuid;
+
+ if (!string.IsNullOrEmpty(creatureNew.motherName))
+ creatureExisting.motherName = creatureNew.motherName;
+ if (!string.IsNullOrEmpty(creatureNew.fatherName))
+ creatureExisting.fatherName = creatureNew.fatherName;
+
+ // if the new ArkId is imported, use that
+ if (creatureExisting.ArkId != creatureNew.ArkId && Utils.IsArkIdImported(creatureNew.ArkId, creatureNew.guid))
+ {
+ creatureExisting.ArkId = creatureNew.ArkId;
+ creatureExisting.ArkIdImported = true;
+ }
+
+ creatureExisting.colors = creatureNew.colors;
+ creatureExisting.status = creatureNew.status;
+ creatureExisting.sex = creatureNew.sex;
+ creatureExisting.cooldownUntil = creatureNew.cooldownUntil;
+ creatureExisting.domesticatedAt = creatureNew.domesticatedAt;
+ creatureExisting.generation = creatureNew.generation;
+ creatureExisting.growingUntil = creatureNew.growingUntil;
+ creatureExisting.imprintingBonus = creatureNew.imprintingBonus;
+ creatureExisting.isBred = creatureNew.isBred;
+ if (!string.IsNullOrEmpty(creatureNew.note))
+ creatureExisting.note = creatureNew.note;
+
+ UpdateString(ref creatureExisting.name, ref creatureNew.name);
+ UpdateString(ref creatureExisting.owner, ref creatureNew.owner);
+ UpdateString(ref creatureExisting.tribe, ref creatureNew.tribe);
+ UpdateString(ref creatureExisting.server, ref creatureNew.server);
+ UpdateString(ref creatureExisting.imprinterName, ref creatureNew.imprinterName);
+
+ void UpdateString(ref string oldCreatureValue, ref string newCreatureValue)
+ {
+ if (oldCreatureValue != newCreatureValue)
+ {
+ oldCreatureValue = newCreatureValue;
+ creaturesWereAddedOrUpdated = true;
+ }
+ }
+
+ bool recalculate = false;
+ if (creatureExisting.flags.HasFlag(CreatureFlags.Placeholder) ||
+ (creatureExisting.status == CreatureStatus.Unavailable && creatureNew.status == CreatureStatus.Available))
{
- // Merge in some specific parts: imprinting level, dom stats, name
- var old = creatures.Single(c => c.guid == creature.guid);
- if (old.Species == null)
- old.Species = creature.Species;
- else if (old.Species != creature.Species) continue;
-
- if (creature.Mother != null)
- old.Mother = creature.Mother;
- else if (creature.motherGuid != Guid.Empty)
- old.motherGuid = creature.motherGuid;
- if (creature.Father != null)
- old.Father = creature.Father;
- else if (creature.fatherGuid != Guid.Empty)
- old.fatherGuid = creature.fatherGuid;
-
- bool recalculate = false;
- if (old.flags.HasFlag(CreatureFlags.Placeholder) ||
- (old.status == CreatureStatus.Unavailable && creature.status == CreatureStatus.Available))
+ creatureExisting.levelFound = creatureNew.levelFound;
+ creatureExisting.levelsDom = creatureNew.levelsDom;
+ creatureExisting.levelsWild = creatureNew.levelsWild;
+ creatureExisting.mutationsMaternal = creatureNew.mutationsMaternal;
+ creatureExisting.mutationsPaternal = creatureNew.mutationsPaternal;
+ creatureExisting.tamingEff = creatureNew.tamingEff;
+ creaturesWereAddedOrUpdated = true;
+ recalculate = true;
+ }
+ else
+ {
+ if (!creatureExisting.levelsWild.SequenceEqual(creatureNew.levelsWild))
{
- old.colors = creature.colors;
- old.cooldownUntil = creature.cooldownUntil;
- old.domesticatedAt = creature.domesticatedAt;
- old.sex = creature.sex;
- old.generation = creature.generation;
- old.growingUntil = creature.growingUntil;
- old.imprinterName = creature.imprinterName;
- old.imprintingBonus = creature.imprintingBonus;
- old.isBred = creature.isBred;
- old.levelFound = creature.levelFound;
- old.levelsDom = creature.levelsDom;
- old.levelsWild = creature.levelsWild;
- old.motherName = creature.motherName;
- old.fatherName = creature.fatherName;
- old.mutationsMaternal = creature.mutationsMaternal;
- old.mutationsPaternal = creature.mutationsPaternal;
- old.name = creature.name;
- old.note = creature.note;
- old.owner = creature.owner;
- old.server = creature.server;
- old.flags = creature.flags;
- if (updateStatus)
- old.status = creature.status;
- old.tamingEff = creature.tamingEff;
- old.topBreedingCreature = creature.topBreedingCreature;
- old.topBreedingStats = creature.topBreedingStats;
- old.topStatsCount = creature.topStatsCount;
- old.topStatsCountBP = creature.topStatsCountBP;
- old.topness = creature.topness;
- old.tribe = creature.tribe;
- old.valuesBreeding = creature.valuesBreeding;
- old.valuesDom = creature.valuesDom;
- old.ArkId = creature.ArkId;
- old.ArkIdImported = creature.ArkIdImported;
- creaturesWereAdded = true;
+ creatureExisting.levelsWild = creatureNew.levelsWild;
recalculate = true;
+ creaturesWereAddedOrUpdated = true;
}
- else
+
+ if (!creatureExisting.levelsDom.SequenceEqual(creatureNew.levelsDom))
{
- if (old.name != creature.name)
- {
- old.name = creature.name;
- creaturesWereAdded = true;
- }
-
- if (old.server != creature.server)
- {
- old.server = creature.server;
- creaturesWereAdded = true;
- }
-
- if (!old.levelsWild.SequenceEqual(creature.levelsWild))
- {
- old.levelsWild = creature.levelsWild;
- recalculate = true;
- creaturesWereAdded = true;
- }
-
- if (!old.levelsDom.SequenceEqual(creature.levelsDom))
- {
- old.levelsDom = creature.levelsDom;
- recalculate = true;
- creaturesWereAdded = true;
- }
-
- if (old.imprintingBonus != creature.imprintingBonus)
- {
- old.imprintingBonus = creature.imprintingBonus;
- recalculate = true;
- creaturesWereAdded = true;
- }
-
- if (old.tamingEff != creature.tamingEff)
- {
- old.tamingEff = creature.tamingEff;
- recalculate = true;
- creaturesWereAdded = true;
- }
- // usually not necessary, mutations will not change, but if in ARK before exporting the ancestors screen was not opened, 0 will be assumed by ARK.
- if (creature.mutationsMaternal != 0 || creature.mutationsPaternal != 0)
- {
- old.mutationsMaternal = creature.mutationsMaternal;
- old.mutationsPaternal = creature.mutationsPaternal;
- }
- if (old.motherGuid == Guid.Empty || old.fatherGuid == Guid.Empty)
- {
- old.motherGuid = creature.motherGuid;
- old.motherName = creature.motherName;
- old.fatherGuid = creature.fatherGuid;
- old.fatherName = creature.fatherName;
- }
- old.colors = creature.colors;
- old.status = creature.status;
+ creatureExisting.levelsDom = creatureNew.levelsDom;
+ recalculate = true;
+ creaturesWereAddedOrUpdated = true;
+ }
+
+ if (creatureExisting.imprintingBonus != creatureNew.imprintingBonus)
+ {
+ creatureExisting.imprintingBonus = creatureNew.imprintingBonus;
+ recalculate = true;
+ creaturesWereAddedOrUpdated = true;
}
- if (recalculate)
- old.RecalculateCreatureValues(getWildLevelStep());
+ if (creatureExisting.tamingEff != creatureNew.tamingEff)
+ {
+ creatureExisting.tamingEff = creatureNew.tamingEff;
+ recalculate = true;
+ creaturesWereAddedOrUpdated = true;
+ }
+ // usually not necessary, mutations will not change, but if in ARK before exporting the ancestors screen was not opened, 0 will be assumed by ARK.
+ if (creatureNew.mutationsMaternal != 0 || creatureNew.mutationsPaternal != 0)
+ {
+ creatureExisting.mutationsMaternal = creatureNew.mutationsMaternal;
+ creatureExisting.mutationsPaternal = creatureNew.mutationsPaternal;
+ }
}
+ creatureExisting.flags = creatureNew.flags;
+
+ if (recalculate)
+ creatureExisting.RecalculateCreatureValues(getWildLevelStep());
}
- return creaturesWereAdded;
+ return creaturesWereAddedOrUpdated;
}
///
diff --git a/ARKBreedingStats/library/CreatureExtensions.cs b/ARKBreedingStats/library/CreatureExtensions.cs
index 7395285b..1d279f15 100644
--- a/ARKBreedingStats/library/CreatureExtensions.cs
+++ b/ARKBreedingStats/library/CreatureExtensions.cs
@@ -41,7 +41,7 @@ public static Bitmap InfoGraphic(this Creature creature, CreatureCollection cc)
g.DrawString(creature.Species.DescriptiveNameAndMod, fontHeader, fontBrush, 3, currentYPosition);
currentYPosition += 19;
- g.DrawString($"Level {creature.LevelHatched} | {Utils.SexSymbol(creature.sex) + (creature.flags.HasFlag(CreatureFlags.Neutered) ? $" ({Loc.s(creature.sex == Sex.Female ? "Spayed" : "Neutered")})" : string.Empty)} | {creature.Mutations} mutations", font, fontBrush, 8, currentYPosition);
+ g.DrawString($"Level {creature.LevelHatched} | {Utils.SexSymbol(creature.sex) + (creature.flags.HasFlag(CreatureFlags.Neutered) ? $" ({Loc.s(creature.sex == Sex.Female ? "Spayed" : "Neutered")})" : string.Empty)} | {creature.Mutations} mutations | generation {creature.generation}", font, fontBrush, 8, currentYPosition);
currentYPosition += 17;
using (var p = new Pen(Color.LightGray, 1))
diff --git a/ARKBreedingStats/local/strings.fr.resx b/ARKBreedingStats/local/strings.fr.resx
index c7581334..1439f5b8 100644
--- a/ARKBreedingStats/local/strings.fr.resx
+++ b/ARKBreedingStats/local/strings.fr.resx
@@ -189,7 +189,7 @@ Changez le mode de reproduction en "Statistiques élevées" pour de meilleures s
Ces parents viennent de s'accoupler
- Cliquez pour créer une entrée d'incubation dans l'onglet Elevage
+ Cliquez pour créer une entrée d'incubation dans l'onglet Élevage
Cliquez pour effacer toutes les zones de couleur.
@@ -204,7 +204,7 @@ Changez le mode de reproduction en "Statistiques élevées" pour de meilleures s
Importer le fichier-créature qui a été exporté en dernier (en jeu avec la fonction "Exporter les données")
- ajouter un minuteur pour l'affamement
+ Ajouter un minuteur pour l'affamement
Générer un nom automatiquement
@@ -693,7 +693,7 @@ Régler sur -1 pour n'importe quel nombre de mutation.
&Quitter
- Elevage
+ Élevage
Statistiques élevées
@@ -784,7 +784,7 @@ Certaines progénitures peuvent être moins bonnes qu'en mode Statistiques Elev
Test des statistiques
- Status
+ Statut
Queue
@@ -814,7 +814,7 @@ Certaines progénitures peuvent être moins bonnes qu'en mode Statistiques Elev
Temps entre les accouplements
- tout nourrir de
+ Tout nourrir de
Réveil
@@ -999,7 +999,22 @@ Certaines progénitures peuvent être moins bonnes qu'en mode Statistiques Elev
L'espèce sélectionnée n'est pas apprivoisable. Peut-être avez-vous sélectionné une variante non apprivoisable d'une espèce apprivoisable ?
+
+ Un partenaire peut avoir plus de mutations
+
+
+ Seulement la meilleure suggestion pour les femelles
+
Progéniture
+
+ Probabilité d'une mutation
+
+
+ Temps d'accouplement
+
+
+ Ajouté à
+
\ No newline at end of file
diff --git a/ARKBreedingStats/raising/RaisingControl.Designer.cs b/ARKBreedingStats/raising/RaisingControl.Designer.cs
index 82c9b153..2e768177 100644
--- a/ARKBreedingStats/raising/RaisingControl.Designer.cs
+++ b/ARKBreedingStats/raising/RaisingControl.Designer.cs
@@ -233,6 +233,7 @@ private void InitializeComponent()
this.listViewBabies.TabIndex = 6;
this.listViewBabies.UseCompatibleStateImageBehavior = false;
this.listViewBabies.View = System.Windows.Forms.View.Details;
+ this.listViewBabies.ColumnClick += new System.Windows.Forms.ColumnClickEventHandler(this.listViewBabies_ColumnClick);
this.listViewBabies.SelectedIndexChanged += new System.EventHandler(this.listViewBabies_SelectedIndexChanged);
//
// columnHeaderBabyName
diff --git a/ARKBreedingStats/raising/RaisingControl.cs b/ARKBreedingStats/raising/RaisingControl.cs
index 736c47e4..a0b039de 100644
--- a/ARKBreedingStats/raising/RaisingControl.cs
+++ b/ARKBreedingStats/raising/RaisingControl.cs
@@ -33,6 +33,7 @@ public RaisingControl()
listViewBabies.Groups.Add("growing", "Juveniles / Adolescent");
updateListView = false;
listViewBabies.DoubleBuffered(true); // prevent flickering
+ listViewBabies.ListViewItemSorter = new ListViewColumnSorter();
}
public void UpdateRaisingData()
@@ -595,6 +596,11 @@ private void btAdjustAllTimers_Click(object sender, EventArgs e)
Utils.BlinkAsync(btAdjustAllTimers, Color.LightGreen, 500, false);
}
+ private void listViewBabies_ColumnClick(object sender, ColumnClickEventArgs e)
+ {
+ ListViewColumnSorter.DoSort((ListView)sender, e.Column);
+ }
+
private void bSaveTimerEdit_Click(object sender, EventArgs e)
{
if (iteEdit != null)
diff --git a/ARKBreedingStats/uiControls/NamePatterns.cs b/ARKBreedingStats/uiControls/NamePatterns.cs
index b619478a..1caf53c8 100644
--- a/ARKBreedingStats/uiControls/NamePatterns.cs
+++ b/ARKBreedingStats/uiControls/NamePatterns.cs
@@ -198,6 +198,24 @@ private static string ResolveFunction(Match m, Creature creature, int[] speciesT
case ">=": return d1 >= d2 ? m.Groups[3].Value : m.Groups[4].Value;
}
}
+ else
+ {
+ // compare the values as strings
+ match = Regex.Match(p1, @"\A\s*(.*?)\s*(==|!=|<=|<|>=|>)\s*(.*?)\s*\Z");
+ if (match.Success)
+ {
+ int stringComparingResult = match.Groups[1].Value.CompareTo(match.Groups[3].Value);
+ switch (match.Groups[2].Value)
+ {
+ case "==": return stringComparingResult == 0 ? m.Groups[3].Value : m.Groups[4].Value;
+ case "!=": return stringComparingResult != 0 ? m.Groups[3].Value : m.Groups[4].Value;
+ case "<": return stringComparingResult < 0 ? m.Groups[3].Value : m.Groups[4].Value;
+ case "<=": return stringComparingResult <= 0 ? m.Groups[3].Value : m.Groups[4].Value;
+ case ">": return stringComparingResult > 0 ? m.Groups[3].Value : m.Groups[4].Value;
+ case ">=": return stringComparingResult >= 0 ? m.Groups[3].Value : m.Groups[4].Value;
+ }
+ }
+ }
return ParametersInvalid($"The expression for ifexpr invalid: \"{p1}\"");
case "substring":
// check param number: 1: substring, 2: p1, 3: pos, 4: length
@@ -302,6 +320,15 @@ private static string ResolveFunction(Match m, Creature creature, int[] speciesT
case "time":
// parameter: 1: time, 2: format
return DateTime.Now.ToString(p1);
+ case "color":
+ // parameter 1: region id (0,...,5), 2: if not empty, the color name instead of the numerical id is returned
+ if (!int.TryParse(p1, out int regionId)
+ || regionId < 0 || regionId > 5) return ParametersInvalid("color region id has to be a number in the range 0 - 5");
+
+ if ((creature.colors?[regionId] ?? 0) == 0) return string.Empty; // no color info
+ if (string.IsNullOrWhiteSpace(m.Groups[3].Value))
+ return creature.colors[regionId].ToString();
+ return CreatureColors.creatureColorName(creature.colors[regionId]);
}
}
catch (Exception ex)
diff --git a/ARKBreedingStats/uiControls/PatternEditor.cs b/ARKBreedingStats/uiControls/PatternEditor.cs
index 8604eecd..6b7cf6d6 100644
--- a/ARKBreedingStats/uiControls/PatternEditor.cs
+++ b/ARKBreedingStats/uiControls/PatternEditor.cs
@@ -278,7 +278,7 @@ public string NamePattern
{
{"isTopStat", "{{#if: isTop | true | false }}, to check if a stat is a top stat in that species (i.e. highest in library).\n{{#if: isTopHP | bestHP {hp} }}" },
{"isNewTopStat", "{{#if: isNewTop | true | false }}, to check if a stat is a top stat in that species (i.e. higher than the ones in the library).\n{{#if: isNewTopHP | newBestHP {hp} }}" },
- {"ifexpr", "{{#ifexpr: expression | true | false }}, to check if a numerical expression with two operands and one operator is true or false. Possible operators are ==, !=, <, <=, <, >=.\n{{#ifexpr: {topPercent} > 80 | top80 }}" },
+ {"ifexpr", "{{#ifexpr: expression | true | false }}, to check if an expression with two operands and one operator is true or false. Possible operators are ==, !=, <, <=, <, >=.\n{{#ifexpr: {topPercent} > 80 | true | false }}" },
{"substring","{{#substring: text | start | length }}. Length can be ommited. If start is negative it takes the characters from the end.\n{{#substring: {species} | 0 | 4 }}"},
{"replace","{{#replace: text | find | replaceBy }}\n{{#replace: {species} | Abberant | Ab }}"},
{"customreplace","{{#customreplace: text }}. Replaces the text with a value saved in the file customReplacings.json.\nIf a second parameter is given, that is returned if the key is not available.\n{{#customreplace: {species} }}"},
@@ -289,6 +289,7 @@ public string NamePattern
{"casing","{{#casing: text | casingtype (U, L, T) }}. U for UPPER, L for lower, T for Title.\n{{#casing: {species} | U }}"},
{"time","{{#time: formatString }}\n{{#time: yyyy-MM-dd_HH:mm }}"},
{"format","{{#format: number | formatString }}\n{{#format: {hp_vb} | 000000 }}"},
+ {"color","{{#color: regionId | colorName }}. Returns the colorId of the region. If the second parameter is not empty, the color name will be returned.\n{{#color: 0 | true }}"},
};
private void btnClear_Click(object sender, EventArgs e)
diff --git a/translations.txt b/translations.txt
index e6e98880..9d95bf78 100644
--- a/translations.txt
+++ b/translations.txt
@@ -1,5 +1,6 @@
aboutToolStripMenuItem about…
added Added
+addedAt Added at
AlreadyCreatureWithTopStats "There is already a creature in your library that has all the available top-stats ({0} {1}).
The currently selected conservative-breeding-mode might show some suggestions that may seem non-optimal.
Change the breeding-mode to "High Stats" for better suggestions."
@@ -43,6 +44,8 @@ C3 C3
C4 C4
C5 C5
Cancel Cancel
+cbBPMutationLimitOnlyOnePartner One partner may have more mutations
+cbBPOnlyOneSuggestionForFemales Only best suggestion for females
cbBPTagExcludeDefaultTT "Check if all creatures should be excluded and only be included when have the include-mark on their tag.
If this checkbox is unchecked, all creatures will be included by default, and only excluded if one of their tags has the exclude-mark and none has the include-mark."
cbExactlyImprinting Exactly, don't adjust
@@ -85,6 +88,7 @@ de German
deadCreaturesToolStripMenuItem Dead Creatures
Default Default
deleteSelectedToolStripMenuItem Remove…
+Descendants Descendants
Details Details
domesticatedAt Domesticated at
domLevelExplanation Levels assigned manually to this stat after the creature was domesticated
@@ -180,6 +184,7 @@ loadToolStripMenuItem &Load...
Longneck Longneck
Male Male
malesToolStripMenuItem Males
+matingTime Mating Time
Maturation Maturation
modValueManagerToolStripMenuItem Load additional values…
Mother Mother
@@ -218,6 +223,7 @@ pasteCreatureToolStripMenuItem Paste Creature
pedigree Pedigree
Player Player
ProbabilityForBest Probability for this Best Possible outcome
+ProbabilityForOneMutation Probability for one mutation
quitToolStripMenuItem &Quit
Raising Raising
rbBPHighStats High Stats