diff --git a/MonsterForm.Designer.cs b/MonsterForm.Designer.cs index 2c5e84a..3cf65f8 100644 --- a/MonsterForm.Designer.cs +++ b/MonsterForm.Designer.cs @@ -47,36 +47,121 @@ private void InitializeComponent() this.symbolTextBox = new System.Windows.Forms.TextBox(); this.symbolLabel = new System.Windows.Forms.Label(); this.armorPanel = new System.Windows.Forms.Panel(); - this.numericUpDown1 = new System.Windows.Forms.NumericUpDown(); - this.numericUpDown2 = new System.Windows.Forms.NumericUpDown(); - this.numericUpDown3 = new System.Windows.Forms.NumericUpDown(); - this.numericUpDown4 = new System.Windows.Forms.NumericUpDown(); - this.numericUpDown5 = new System.Windows.Forms.NumericUpDown(); - this.armorLabel = new System.Windows.Forms.Label(); - this.bashArmorLabel = new System.Windows.Forms.Label(); - this.cutArmorLabel = new System.Windows.Forms.Label(); - this.stabArmorLabel = new System.Windows.Forms.Label(); - this.acidArmorLabel = new System.Windows.Forms.Label(); this.fireArmorLabel = new System.Windows.Forms.Label(); + this.acidArmorLabel = new System.Windows.Forms.Label(); + this.stabArmorLabel = new System.Windows.Forms.Label(); + this.cutArmorLabel = new System.Windows.Forms.Label(); + this.bashArmorLabel = new System.Windows.Forms.Label(); + this.armorLabel = new System.Windows.Forms.Label(); + this.stabArmorUpDown = new System.Windows.Forms.NumericUpDown(); + this.acidArmorUpDown = new System.Windows.Forms.NumericUpDown(); + this.cutArmorUpDown = new System.Windows.Forms.NumericUpDown(); + this.fireArmorUpDown = new System.Windows.Forms.NumericUpDown(); + this.bashArmorUpDown = new System.Windows.Forms.NumericUpDown(); this.bodytypeComboBox = new System.Windows.Forms.ComboBox(); this.bodytypeId = new System.Windows.Forms.Label(); this.descriptionTextBox = new System.Windows.Forms.TextBox(); this.descriptionLabel = new System.Windows.Forms.Label(); this.colorComboBox = new System.Windows.Forms.ComboBox(); this.colorLabel = new System.Windows.Forms.Label(); + this.materialDataGrid = new System.Windows.Forms.DataGridView(); + this.Material = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.materialBindingSource = new System.Windows.Forms.BindingSource(this.components); + this.speciesDataGrid = new System.Windows.Forms.DataGridView(); + this.species = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.categoriesDataGrid = new System.Windows.Forms.DataGridView(); + this.Categories = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.label1 = new System.Windows.Forms.Label(); + this.defaultFactionLabel = new System.Windows.Forms.Label(); + this.defaultFactionTextBox = new System.Windows.Forms.TextBox(); + this.looksLikeTextBox = new System.Windows.Forms.TextBox(); + this.diffUpDown = new System.Windows.Forms.NumericUpDown(); + this.diffLabel = new System.Windows.Forms.Label(); + this.difficultyLabel = new System.Windows.Forms.Label(); + this.aggressionUpDown = new System.Windows.Forms.NumericUpDown(); + this.aggressionLabel = new System.Windows.Forms.Label(); + this.combatEffectivenessPanel = new System.Windows.Forms.Panel(); + this.damageInstanceTypeComboBox = new System.Windows.Forms.ComboBox(); + this.damageInstanceDataGrid = new System.Windows.Forms.DataGridView(); + this.Type = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.Amount = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.ArmorPenetration = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.ArmorMultiplier = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.DamageMultiplier = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.dodgeLabel = new System.Windows.Forms.Label(); + this.dodgeUpDown = new System.Windows.Forms.NumericUpDown(); + this.grabStrengthLabel = new System.Windows.Forms.Label(); + this.grabStrengthUpDown = new System.Windows.Forms.NumericUpDown(); + this.moraleLabel = new System.Windows.Forms.Label(); + this.moraleUpDown = new System.Windows.Forms.NumericUpDown(); + this.speedLabel = new System.Windows.Forms.Label(); + this.speedUpDown = new System.Windows.Forms.NumericUpDown(); + this.damageInstanceArmorPenetrationUpDown = new System.Windows.Forms.NumericUpDown(); + this.damageInstanceAmountUpDown = new System.Windows.Forms.NumericUpDown(); + this.damageInstanceArmorMultiplierUpDown = new System.Windows.Forms.NumericUpDown(); + this.damageInstanceDamageMultiplierUpDown = new System.Windows.Forms.NumericUpDown(); + this.damageInstanceAddButton = new System.Windows.Forms.Button(); + this.meleeDamageLabel = new System.Windows.Forms.Label(); + this.bonusCutUpDown = new System.Windows.Forms.NumericUpDown(); + this.bonusCutLabel = new System.Windows.Forms.Label(); + this.meleeDiceLabel = new System.Windows.Forms.Label(); + this.meleeDiceUpdown = new System.Windows.Forms.NumericUpDown(); + this.meleeDiceSidesUpDown = new System.Windows.Forms.NumericUpDown(); + this.label2 = new System.Windows.Forms.Label(); + this.label3 = new System.Windows.Forms.Label(); + this.meleeDamageRangeLabel = new System.Windows.Forms.Label(); + this.meleeSkillUpDown = new System.Windows.Forms.NumericUpDown(); + this.meleeSkillLabel = new System.Windows.Forms.Label(); this.mtypeBindingSource = new System.Windows.Forms.BindingSource(this.components); this.monsterNameStringsBindingSource = new System.Windows.Forms.BindingSource(this.components); + this.pathSettingsPanel = new System.Windows.Forms.Panel(); + this.pathSettingsMaxDistUpDown = new System.Windows.Forms.NumericUpDown(); + this.pathSettingsMaxLengthUpDown = new System.Windows.Forms.NumericUpDown(); + this.pathSettingsBashStrengthUpDown = new System.Windows.Forms.NumericUpDown(); + this.label4 = new System.Windows.Forms.Label(); + this.label5 = new System.Windows.Forms.Label(); + this.label6 = new System.Windows.Forms.Label(); + this.checkBox1 = new System.Windows.Forms.CheckBox(); + this.checkBox2 = new System.Windows.Forms.CheckBox(); + this.checkBox3 = new System.Windows.Forms.CheckBox(); + this.label7 = new System.Windows.Forms.Label(); + this.pathSettingsDataBindingSource = new System.Windows.Forms.BindingSource(this.components); ((System.ComponentModel.ISupportInitialize)(this.hpUpDown)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.volumeUpDown)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.weightUpDown)).BeginInit(); this.armorPanel.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.numericUpDown1)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.numericUpDown2)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.numericUpDown3)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.numericUpDown4)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.numericUpDown5)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.stabArmorUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.acidArmorUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.cutArmorUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.fireArmorUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.bashArmorUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.materialDataGrid)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.materialBindingSource)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.speciesDataGrid)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.categoriesDataGrid)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.diffUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.aggressionUpDown)).BeginInit(); + this.combatEffectivenessPanel.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.damageInstanceDataGrid)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.dodgeUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.grabStrengthUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.moraleUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.speedUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.damageInstanceArmorPenetrationUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.damageInstanceAmountUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.damageInstanceArmorMultiplierUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.damageInstanceDamageMultiplierUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.bonusCutUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.meleeDiceUpdown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.meleeDiceSidesUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.meleeSkillUpDown)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.mtypeBindingSource)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.monsterNameStringsBindingSource)).BeginInit(); + this.pathSettingsPanel.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.pathSettingsMaxDistUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.pathSettingsMaxLengthUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.pathSettingsBashStrengthUpDown)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.pathSettingsDataBindingSource)).BeginInit(); this.SuspendLayout(); // // nameTextBox @@ -143,7 +228,7 @@ private void InitializeComponent() // hpUpDown // this.hpUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "Hp", true)); - this.hpUpDown.Location = new System.Drawing.Point(224, 64); + this.hpUpDown.Location = new System.Drawing.Point(81, 8); this.hpUpDown.Maximum = new decimal(new int[] { 99999, 0, @@ -166,7 +251,7 @@ private void InitializeComponent() // hpLabel // this.hpLabel.AutoSize = true; - this.hpLabel.Location = new System.Drawing.Point(226, 48); + this.hpLabel.Location = new System.Drawing.Point(53, 10); this.hpLabel.Name = "hpLabel"; this.hpLabel.Size = new System.Drawing.Size(22, 13); this.hpLabel.TabIndex = 8; @@ -284,55 +369,60 @@ private void InitializeComponent() this.armorPanel.Controls.Add(this.cutArmorLabel); this.armorPanel.Controls.Add(this.bashArmorLabel); this.armorPanel.Controls.Add(this.armorLabel); - this.armorPanel.Controls.Add(this.numericUpDown5); - this.armorPanel.Controls.Add(this.numericUpDown4); - this.armorPanel.Controls.Add(this.numericUpDown3); - this.armorPanel.Controls.Add(this.numericUpDown2); - this.armorPanel.Controls.Add(this.numericUpDown1); - this.armorPanel.Location = new System.Drawing.Point(347, 26); + this.armorPanel.Controls.Add(this.stabArmorUpDown); + this.armorPanel.Controls.Add(this.acidArmorUpDown); + this.armorPanel.Controls.Add(this.cutArmorUpDown); + this.armorPanel.Controls.Add(this.fireArmorUpDown); + this.armorPanel.Controls.Add(this.bashArmorUpDown); + this.armorPanel.Location = new System.Drawing.Point(347, 25); this.armorPanel.Name = "armorPanel"; this.armorPanel.Size = new System.Drawing.Size(93, 150); this.armorPanel.TabIndex = 50; // - // numericUpDown1 + // fireArmorLabel // - this.numericUpDown1.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "ArmorBash", true)); - this.numericUpDown1.Location = new System.Drawing.Point(36, 19); - this.numericUpDown1.Name = "numericUpDown1"; - this.numericUpDown1.Size = new System.Drawing.Size(50, 20); - this.numericUpDown1.TabIndex = 0; + this.fireArmorLabel.AutoSize = true; + this.fireArmorLabel.Location = new System.Drawing.Point(10, 127); + this.fireArmorLabel.Name = "fireArmorLabel"; + this.fireArmorLabel.Size = new System.Drawing.Size(24, 13); + this.fireArmorLabel.TabIndex = 10; + this.fireArmorLabel.Text = "Fire"; // - // numericUpDown2 + // acidArmorLabel // - this.numericUpDown2.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "ArmorFire", true)); - this.numericUpDown2.Location = new System.Drawing.Point(36, 124); - this.numericUpDown2.Name = "numericUpDown2"; - this.numericUpDown2.Size = new System.Drawing.Size(50, 20); - this.numericUpDown2.TabIndex = 1; + this.acidArmorLabel.AutoSize = true; + this.acidArmorLabel.Location = new System.Drawing.Point(6, 101); + this.acidArmorLabel.Name = "acidArmorLabel"; + this.acidArmorLabel.Size = new System.Drawing.Size(28, 13); + this.acidArmorLabel.TabIndex = 9; + this.acidArmorLabel.Text = "Acid"; // - // numericUpDown3 + // stabArmorLabel // - this.numericUpDown3.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "ArmorCut", true)); - this.numericUpDown3.Location = new System.Drawing.Point(36, 45); - this.numericUpDown3.Name = "numericUpDown3"; - this.numericUpDown3.Size = new System.Drawing.Size(50, 20); - this.numericUpDown3.TabIndex = 2; + this.stabArmorLabel.AutoSize = true; + this.stabArmorLabel.Location = new System.Drawing.Point(5, 75); + this.stabArmorLabel.Name = "stabArmorLabel"; + this.stabArmorLabel.Size = new System.Drawing.Size(29, 13); + this.stabArmorLabel.TabIndex = 8; + this.stabArmorLabel.Text = "Stab"; // - // numericUpDown4 + // cutArmorLabel // - this.numericUpDown4.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "ArmorAcid", true)); - this.numericUpDown4.Location = new System.Drawing.Point(36, 98); - this.numericUpDown4.Name = "numericUpDown4"; - this.numericUpDown4.Size = new System.Drawing.Size(50, 20); - this.numericUpDown4.TabIndex = 3; + this.cutArmorLabel.AutoSize = true; + this.cutArmorLabel.Location = new System.Drawing.Point(11, 48); + this.cutArmorLabel.Name = "cutArmorLabel"; + this.cutArmorLabel.Size = new System.Drawing.Size(23, 13); + this.cutArmorLabel.TabIndex = 7; + this.cutArmorLabel.Text = "Cut"; // - // numericUpDown5 + // bashArmorLabel // - this.numericUpDown5.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "ArmorStab", true)); - this.numericUpDown5.Location = new System.Drawing.Point(36, 72); - this.numericUpDown5.Name = "numericUpDown5"; - this.numericUpDown5.Size = new System.Drawing.Size(50, 20); - this.numericUpDown5.TabIndex = 4; + this.bashArmorLabel.AutoSize = true; + this.bashArmorLabel.Location = new System.Drawing.Point(3, 22); + this.bashArmorLabel.Name = "bashArmorLabel"; + this.bashArmorLabel.Size = new System.Drawing.Size(31, 13); + this.bashArmorLabel.TabIndex = 6; + this.bashArmorLabel.Text = "Bash"; // // armorLabel // @@ -344,50 +434,45 @@ private void InitializeComponent() this.armorLabel.TabIndex = 5; this.armorLabel.Text = "Armor"; // - // bashArmorLabel + // stabArmorUpDown // - this.bashArmorLabel.AutoSize = true; - this.bashArmorLabel.Location = new System.Drawing.Point(3, 22); - this.bashArmorLabel.Name = "bashArmorLabel"; - this.bashArmorLabel.Size = new System.Drawing.Size(31, 13); - this.bashArmorLabel.TabIndex = 6; - this.bashArmorLabel.Text = "Bash"; + this.stabArmorUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "ArmorStab", true)); + this.stabArmorUpDown.Location = new System.Drawing.Point(36, 72); + this.stabArmorUpDown.Name = "stabArmorUpDown"; + this.stabArmorUpDown.Size = new System.Drawing.Size(50, 20); + this.stabArmorUpDown.TabIndex = 4; // - // cutArmorLabel + // acidArmorUpDown // - this.cutArmorLabel.AutoSize = true; - this.cutArmorLabel.Location = new System.Drawing.Point(11, 48); - this.cutArmorLabel.Name = "cutArmorLabel"; - this.cutArmorLabel.Size = new System.Drawing.Size(23, 13); - this.cutArmorLabel.TabIndex = 7; - this.cutArmorLabel.Text = "Cut"; + this.acidArmorUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "ArmorAcid", true)); + this.acidArmorUpDown.Location = new System.Drawing.Point(36, 98); + this.acidArmorUpDown.Name = "acidArmorUpDown"; + this.acidArmorUpDown.Size = new System.Drawing.Size(50, 20); + this.acidArmorUpDown.TabIndex = 3; // - // stabArmorLabel + // cutArmorUpDown // - this.stabArmorLabel.AutoSize = true; - this.stabArmorLabel.Location = new System.Drawing.Point(5, 75); - this.stabArmorLabel.Name = "stabArmorLabel"; - this.stabArmorLabel.Size = new System.Drawing.Size(29, 13); - this.stabArmorLabel.TabIndex = 8; - this.stabArmorLabel.Text = "Stab"; + this.cutArmorUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "ArmorCut", true)); + this.cutArmorUpDown.Location = new System.Drawing.Point(36, 45); + this.cutArmorUpDown.Name = "cutArmorUpDown"; + this.cutArmorUpDown.Size = new System.Drawing.Size(50, 20); + this.cutArmorUpDown.TabIndex = 2; // - // acidArmorLabel + // fireArmorUpDown // - this.acidArmorLabel.AutoSize = true; - this.acidArmorLabel.Location = new System.Drawing.Point(6, 101); - this.acidArmorLabel.Name = "acidArmorLabel"; - this.acidArmorLabel.Size = new System.Drawing.Size(28, 13); - this.acidArmorLabel.TabIndex = 9; - this.acidArmorLabel.Text = "Acid"; + this.fireArmorUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "ArmorFire", true)); + this.fireArmorUpDown.Location = new System.Drawing.Point(36, 124); + this.fireArmorUpDown.Name = "fireArmorUpDown"; + this.fireArmorUpDown.Size = new System.Drawing.Size(50, 20); + this.fireArmorUpDown.TabIndex = 1; // - // fireArmorLabel + // bashArmorUpDown // - this.fireArmorLabel.AutoSize = true; - this.fireArmorLabel.Location = new System.Drawing.Point(10, 127); - this.fireArmorLabel.Name = "fireArmorLabel"; - this.fireArmorLabel.Size = new System.Drawing.Size(24, 13); - this.fireArmorLabel.TabIndex = 10; - this.fireArmorLabel.Text = "Fire"; + this.bashArmorUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "ArmorBash", true)); + this.bashArmorUpDown.Location = new System.Drawing.Point(36, 19); + this.bashArmorUpDown.Name = "bashArmorUpDown"; + this.bashArmorUpDown.Size = new System.Drawing.Size(50, 20); + this.bashArmorUpDown.TabIndex = 0; // // bodytypeComboBox // @@ -409,7 +494,7 @@ private void InitializeComponent() // bodytypeId // this.bodytypeId.AutoSize = true; - this.bodytypeId.Location = new System.Drawing.Point(119, 48); + this.bodytypeId.Location = new System.Drawing.Point(119, 49); this.bodytypeId.Name = "bodytypeId"; this.bodytypeId.Size = new System.Drawing.Size(58, 13); this.bodytypeId.TabIndex = 52; @@ -418,7 +503,7 @@ private void InitializeComponent() // descriptionTextBox // this.descriptionTextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.mtypeBindingSource, "Description", true)); - this.descriptionTextBox.Location = new System.Drawing.Point(12, 104); + this.descriptionTextBox.Location = new System.Drawing.Point(12, 142); this.descriptionTextBox.Multiline = true; this.descriptionTextBox.Name = "descriptionTextBox"; this.descriptionTextBox.Size = new System.Drawing.Size(206, 72); @@ -427,7 +512,7 @@ private void InitializeComponent() // descriptionLabel // this.descriptionLabel.AutoSize = true; - this.descriptionLabel.Location = new System.Drawing.Point(12, 88); + this.descriptionLabel.Location = new System.Drawing.Point(12, 126); this.descriptionLabel.Name = "descriptionLabel"; this.descriptionLabel.Size = new System.Drawing.Size(60, 13); this.descriptionLabel.TabIndex = 54; @@ -451,6 +536,597 @@ private void InitializeComponent() this.colorLabel.TabIndex = 56; this.colorLabel.Text = "Color"; // + // materialDataGrid + // + this.materialDataGrid.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; + this.materialDataGrid.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { + this.Material}); + this.materialDataGrid.Location = new System.Drawing.Point(12, 220); + this.materialDataGrid.Name = "materialDataGrid"; + this.materialDataGrid.Size = new System.Drawing.Size(206, 68); + this.materialDataGrid.TabIndex = 57; + // + // Material + // + this.Material.HeaderText = "Material"; + this.Material.Name = "Material"; + this.Material.Width = 130; + // + // materialBindingSource + // + this.materialBindingSource.DataMember = "Material"; + this.materialBindingSource.DataSource = this.mtypeBindingSource; + // + // speciesDataGrid + // + this.speciesDataGrid.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; + this.speciesDataGrid.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { + this.species}); + this.speciesDataGrid.Location = new System.Drawing.Point(12, 294); + this.speciesDataGrid.Name = "speciesDataGrid"; + this.speciesDataGrid.Size = new System.Drawing.Size(206, 68); + this.speciesDataGrid.TabIndex = 58; + // + // species + // + this.species.HeaderText = "Species"; + this.species.Name = "species"; + this.species.Width = 130; + // + // categoriesDataGrid + // + this.categoriesDataGrid.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; + this.categoriesDataGrid.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { + this.Categories}); + this.categoriesDataGrid.Location = new System.Drawing.Point(12, 368); + this.categoriesDataGrid.Name = "categoriesDataGrid"; + this.categoriesDataGrid.Size = new System.Drawing.Size(206, 68); + this.categoriesDataGrid.TabIndex = 59; + // + // Categories + // + this.Categories.HeaderText = "Categories"; + this.Categories.Name = "Categories"; + this.Categories.Width = 130; + // + // label1 + // + this.label1.AutoSize = true; + this.label1.Location = new System.Drawing.Point(119, 88); + this.label1.Name = "label1"; + this.label1.Size = new System.Drawing.Size(59, 13); + this.label1.TabIndex = 63; + this.label1.Text = "Looks Like"; + // + // defaultFactionLabel + // + this.defaultFactionLabel.AutoSize = true; + this.defaultFactionLabel.Location = new System.Drawing.Point(12, 87); + this.defaultFactionLabel.Name = "defaultFactionLabel"; + this.defaultFactionLabel.Size = new System.Drawing.Size(79, 13); + this.defaultFactionLabel.TabIndex = 61; + this.defaultFactionLabel.Text = "Default Faction"; + // + // defaultFactionTextBox + // + this.defaultFactionTextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.mtypeBindingSource, "DefaultFaction", true)); + this.defaultFactionTextBox.Location = new System.Drawing.Point(12, 103); + this.defaultFactionTextBox.Name = "defaultFactionTextBox"; + this.defaultFactionTextBox.Size = new System.Drawing.Size(100, 20); + this.defaultFactionTextBox.TabIndex = 60; + // + // looksLikeTextBox + // + this.looksLikeTextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.mtypeBindingSource, "LooksLike", true)); + this.looksLikeTextBox.Location = new System.Drawing.Point(118, 103); + this.looksLikeTextBox.Name = "looksLikeTextBox"; + this.looksLikeTextBox.Size = new System.Drawing.Size(100, 20); + this.looksLikeTextBox.TabIndex = 64; + // + // diffUpDown + // + this.diffUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "Diff", true)); + this.diffUpDown.Location = new System.Drawing.Point(224, 179); + this.diffUpDown.Maximum = new decimal(new int[] { + 99999, + 0, + 0, + 0}); + this.diffUpDown.Minimum = new decimal(new int[] { + 99999, + 0, + 0, + -2147483648}); + this.diffUpDown.Name = "diffUpDown"; + this.diffUpDown.Size = new System.Drawing.Size(58, 20); + this.diffUpDown.TabIndex = 65; + // + // diffLabel + // + this.diffLabel.AutoSize = true; + this.diffLabel.Location = new System.Drawing.Point(218, 166); + this.diffLabel.Name = "diffLabel"; + this.diffLabel.Size = new System.Drawing.Size(87, 13); + this.diffLabel.TabIndex = 66; + this.diffLabel.Text = "Difficulty Modifier"; + // + // difficultyLabel + // + this.difficultyLabel.AutoSize = true; + this.difficultyLabel.Location = new System.Drawing.Point(443, 9); + this.difficultyLabel.Name = "difficultyLabel"; + this.difficultyLabel.Size = new System.Drawing.Size(182, 13); + this.difficultyLabel.TabIndex = 67; + this.difficultyLabel.Text = "Calculated Difficulty (click to update):"; + this.difficultyLabel.Click += new System.EventHandler(this.difficultyLabel_Click); + // + // aggressionUpDown + // + this.aggressionUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "Aggression", true)); + this.aggressionUpDown.Location = new System.Drawing.Point(81, 59); + this.aggressionUpDown.Minimum = new decimal(new int[] { + 100, + 0, + 0, + -2147483648}); + this.aggressionUpDown.Name = "aggressionUpDown"; + this.aggressionUpDown.Size = new System.Drawing.Size(58, 20); + this.aggressionUpDown.TabIndex = 68; + // + // aggressionLabel + // + this.aggressionLabel.AutoSize = true; + this.aggressionLabel.Location = new System.Drawing.Point(18, 60); + this.aggressionLabel.Name = "aggressionLabel"; + this.aggressionLabel.Size = new System.Drawing.Size(59, 13); + this.aggressionLabel.TabIndex = 69; + this.aggressionLabel.Text = "Aggression"; + // + // combatEffectivenessPanel + // + this.combatEffectivenessPanel.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.combatEffectivenessPanel.Controls.Add(this.meleeSkillLabel); + this.combatEffectivenessPanel.Controls.Add(this.meleeSkillUpDown); + this.combatEffectivenessPanel.Controls.Add(this.meleeDamageRangeLabel); + this.combatEffectivenessPanel.Controls.Add(this.label3); + this.combatEffectivenessPanel.Controls.Add(this.label2); + this.combatEffectivenessPanel.Controls.Add(this.meleeDiceSidesUpDown); + this.combatEffectivenessPanel.Controls.Add(this.meleeDiceUpdown); + this.combatEffectivenessPanel.Controls.Add(this.meleeDiceLabel); + this.combatEffectivenessPanel.Controls.Add(this.bonusCutLabel); + this.combatEffectivenessPanel.Controls.Add(this.bonusCutUpDown); + this.combatEffectivenessPanel.Controls.Add(this.meleeDamageLabel); + this.combatEffectivenessPanel.Controls.Add(this.damageInstanceAddButton); + this.combatEffectivenessPanel.Controls.Add(this.damageInstanceDamageMultiplierUpDown); + this.combatEffectivenessPanel.Controls.Add(this.damageInstanceArmorMultiplierUpDown); + this.combatEffectivenessPanel.Controls.Add(this.damageInstanceAmountUpDown); + this.combatEffectivenessPanel.Controls.Add(this.damageInstanceArmorPenetrationUpDown); + this.combatEffectivenessPanel.Controls.Add(this.damageInstanceTypeComboBox); + this.combatEffectivenessPanel.Controls.Add(this.damageInstanceDataGrid); + this.combatEffectivenessPanel.Controls.Add(this.dodgeLabel); + this.combatEffectivenessPanel.Controls.Add(this.dodgeUpDown); + this.combatEffectivenessPanel.Controls.Add(this.grabStrengthLabel); + this.combatEffectivenessPanel.Controls.Add(this.grabStrengthUpDown); + this.combatEffectivenessPanel.Controls.Add(this.moraleLabel); + this.combatEffectivenessPanel.Controls.Add(this.moraleUpDown); + this.combatEffectivenessPanel.Controls.Add(this.speedLabel); + this.combatEffectivenessPanel.Controls.Add(this.aggressionLabel); + this.combatEffectivenessPanel.Controls.Add(this.speedUpDown); + this.combatEffectivenessPanel.Controls.Add(this.aggressionUpDown); + this.combatEffectivenessPanel.Controls.Add(this.hpUpDown); + this.combatEffectivenessPanel.Controls.Add(this.hpLabel); + this.combatEffectivenessPanel.Location = new System.Drawing.Point(229, 205); + this.combatEffectivenessPanel.Name = "combatEffectivenessPanel"; + this.combatEffectivenessPanel.Size = new System.Drawing.Size(530, 199); + this.combatEffectivenessPanel.TabIndex = 70; + // + // damageInstanceTypeComboBox + // + this.damageInstanceTypeComboBox.AutoCompleteCustomSource.AddRange(new string[] { + "true", + "biological", + "bash", + "cut", + "acid", + "stab", + "heat", + "cold", + "electric"}); + this.damageInstanceTypeComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; + this.damageInstanceTypeComboBox.Items.AddRange(new object[] { + "true", + "biological", + "bash", + "cut", + "acid", + "stab", + "heat", + "cold", + "electric"}); + this.damageInstanceTypeComboBox.Location = new System.Drawing.Point(186, 23); + this.damageInstanceTypeComboBox.Name = "damageInstanceTypeComboBox"; + this.damageInstanceTypeComboBox.Size = new System.Drawing.Size(67, 21); + this.damageInstanceTypeComboBox.TabIndex = 71; + // + // damageInstanceDataGrid + // + this.damageInstanceDataGrid.AllowUserToAddRows = false; + this.damageInstanceDataGrid.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; + this.damageInstanceDataGrid.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { + this.Type, + this.Amount, + this.ArmorPenetration, + this.ArmorMultiplier, + this.DamageMultiplier}); + this.damageInstanceDataGrid.Location = new System.Drawing.Point(145, 46); + this.damageInstanceDataGrid.Name = "damageInstanceDataGrid"; + this.damageInstanceDataGrid.ReadOnly = true; + this.damageInstanceDataGrid.Size = new System.Drawing.Size(370, 122); + this.damageInstanceDataGrid.TabIndex = 76; + // + // Type + // + this.Type.HeaderText = "Type"; + this.Type.Name = "Type"; + this.Type.ReadOnly = true; + this.Type.Width = 65; + // + // Amount + // + this.Amount.HeaderText = "Amount"; + this.Amount.Name = "Amount"; + this.Amount.ReadOnly = true; + this.Amount.Width = 50; + // + // ArmorPenetration + // + this.ArmorPenetration.HeaderText = "Armor Penetration"; + this.ArmorPenetration.Name = "ArmorPenetration"; + this.ArmorPenetration.ReadOnly = true; + this.ArmorPenetration.Width = 65; + // + // ArmorMultiplier + // + this.ArmorMultiplier.HeaderText = "Armor Multiplier"; + this.ArmorMultiplier.Name = "ArmorMultiplier"; + this.ArmorMultiplier.ReadOnly = true; + this.ArmorMultiplier.Width = 65; + // + // DamageMultiplier + // + this.DamageMultiplier.HeaderText = "Damage Multiplier"; + this.DamageMultiplier.Name = "DamageMultiplier"; + this.DamageMultiplier.ReadOnly = true; + this.DamageMultiplier.Width = 65; + // + // dodgeLabel + // + this.dodgeLabel.AutoSize = true; + this.dodgeLabel.Location = new System.Drawing.Point(36, 137); + this.dodgeLabel.Name = "dodgeLabel"; + this.dodgeLabel.Size = new System.Drawing.Size(39, 13); + this.dodgeLabel.TabIndex = 75; + this.dodgeLabel.Text = "Dodge"; + // + // dodgeUpDown + // + this.dodgeUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "Dodge", true)); + this.dodgeUpDown.Location = new System.Drawing.Point(81, 137); + this.dodgeUpDown.Maximum = new decimal(new int[] { + 99999, + 0, + 0, + 0}); + this.dodgeUpDown.Name = "dodgeUpDown"; + this.dodgeUpDown.Size = new System.Drawing.Size(58, 20); + this.dodgeUpDown.TabIndex = 74; + // + // grabStrengthLabel + // + this.grabStrengthLabel.AutoSize = true; + this.grabStrengthLabel.Location = new System.Drawing.Point(2, 113); + this.grabStrengthLabel.Name = "grabStrengthLabel"; + this.grabStrengthLabel.Size = new System.Drawing.Size(73, 13); + this.grabStrengthLabel.TabIndex = 73; + this.grabStrengthLabel.Text = "Grab Strength"; + // + // grabStrengthUpDown + // + this.grabStrengthUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "GrabStrength", true)); + this.grabStrengthUpDown.Location = new System.Drawing.Point(81, 111); + this.grabStrengthUpDown.Maximum = new decimal(new int[] { + 99999, + 0, + 0, + 0}); + this.grabStrengthUpDown.Minimum = new decimal(new int[] { + 99999, + 0, + 0, + -2147483648}); + this.grabStrengthUpDown.Name = "grabStrengthUpDown"; + this.grabStrengthUpDown.Size = new System.Drawing.Size(58, 20); + this.grabStrengthUpDown.TabIndex = 72; + // + // moraleLabel + // + this.moraleLabel.AutoSize = true; + this.moraleLabel.Location = new System.Drawing.Point(36, 87); + this.moraleLabel.Name = "moraleLabel"; + this.moraleLabel.Size = new System.Drawing.Size(39, 13); + this.moraleLabel.TabIndex = 71; + this.moraleLabel.Text = "Morale"; + // + // moraleUpDown + // + this.moraleUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "Morale", true)); + this.moraleUpDown.Location = new System.Drawing.Point(81, 85); + this.moraleUpDown.Maximum = new decimal(new int[] { + 99999, + 0, + 0, + 0}); + this.moraleUpDown.Minimum = new decimal(new int[] { + 99999, + 0, + 0, + -2147483648}); + this.moraleUpDown.Name = "moraleUpDown"; + this.moraleUpDown.Size = new System.Drawing.Size(58, 20); + this.moraleUpDown.TabIndex = 70; + // + // speedLabel + // + this.speedLabel.AutoSize = true; + this.speedLabel.Location = new System.Drawing.Point(38, 36); + this.speedLabel.Name = "speedLabel"; + this.speedLabel.Size = new System.Drawing.Size(38, 13); + this.speedLabel.TabIndex = 1; + this.speedLabel.Text = "Speed"; + // + // speedUpDown + // + this.speedUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "Speed", true)); + this.speedUpDown.Location = new System.Drawing.Point(81, 34); + this.speedUpDown.Maximum = new decimal(new int[] { + 99999, + 0, + 0, + 0}); + this.speedUpDown.Minimum = new decimal(new int[] { + 1, + 0, + 0, + 0}); + this.speedUpDown.Name = "speedUpDown"; + this.speedUpDown.Size = new System.Drawing.Size(58, 20); + this.speedUpDown.TabIndex = 0; + this.speedUpDown.Value = new decimal(new int[] { + 1, + 0, + 0, + 0}); + // + // damageInstanceArmorPenetrationUpDown + // + this.damageInstanceArmorPenetrationUpDown.Location = new System.Drawing.Point(303, 24); + this.damageInstanceArmorPenetrationUpDown.Maximum = new decimal(new int[] { + 99999, + 0, + 0, + 0}); + this.damageInstanceArmorPenetrationUpDown.Name = "damageInstanceArmorPenetrationUpDown"; + this.damageInstanceArmorPenetrationUpDown.Size = new System.Drawing.Size(58, 20); + this.damageInstanceArmorPenetrationUpDown.TabIndex = 77; + // + // damageInstanceAmountUpDown + // + this.damageInstanceAmountUpDown.Location = new System.Drawing.Point(259, 24); + this.damageInstanceAmountUpDown.Maximum = new decimal(new int[] { + 99999, + 0, + 0, + 0}); + this.damageInstanceAmountUpDown.Name = "damageInstanceAmountUpDown"; + this.damageInstanceAmountUpDown.Size = new System.Drawing.Size(38, 20); + this.damageInstanceAmountUpDown.TabIndex = 78; + // + // damageInstanceArmorMultiplierUpDown + // + this.damageInstanceArmorMultiplierUpDown.DecimalPlaces = 3; + this.damageInstanceArmorMultiplierUpDown.Increment = new decimal(new int[] { + 5, + 0, + 0, + 131072}); + this.damageInstanceArmorMultiplierUpDown.Location = new System.Drawing.Point(367, 24); + this.damageInstanceArmorMultiplierUpDown.Maximum = new decimal(new int[] { + 99999, + 0, + 0, + 0}); + this.damageInstanceArmorMultiplierUpDown.Name = "damageInstanceArmorMultiplierUpDown"; + this.damageInstanceArmorMultiplierUpDown.Size = new System.Drawing.Size(62, 20); + this.damageInstanceArmorMultiplierUpDown.TabIndex = 79; + this.damageInstanceArmorMultiplierUpDown.Value = new decimal(new int[] { + 1, + 0, + 0, + 0}); + // + // damageInstanceDamageMultiplierUpDown + // + this.damageInstanceDamageMultiplierUpDown.DecimalPlaces = 3; + this.damageInstanceDamageMultiplierUpDown.Increment = new decimal(new int[] { + 5, + 0, + 0, + 131072}); + this.damageInstanceDamageMultiplierUpDown.Location = new System.Drawing.Point(435, 24); + this.damageInstanceDamageMultiplierUpDown.Maximum = new decimal(new int[] { + 99999, + 0, + 0, + 0}); + this.damageInstanceDamageMultiplierUpDown.Name = "damageInstanceDamageMultiplierUpDown"; + this.damageInstanceDamageMultiplierUpDown.Size = new System.Drawing.Size(62, 20); + this.damageInstanceDamageMultiplierUpDown.TabIndex = 80; + this.damageInstanceDamageMultiplierUpDown.Value = new decimal(new int[] { + 1, + 0, + 0, + 0}); + // + // damageInstanceAddButton + // + this.damageInstanceAddButton.Location = new System.Drawing.Point(145, 22); + this.damageInstanceAddButton.Name = "damageInstanceAddButton"; + this.damageInstanceAddButton.Size = new System.Drawing.Size(35, 23); + this.damageInstanceAddButton.TabIndex = 81; + this.damageInstanceAddButton.Text = "Add"; + this.damageInstanceAddButton.UseVisualStyleBackColor = true; + this.damageInstanceAddButton.Click += new System.EventHandler(this.damageInstanceAddButton_Click); + // + // meleeDamageLabel + // + this.meleeDamageLabel.AutoSize = true; + this.meleeDamageLabel.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.meleeDamageLabel.Location = new System.Drawing.Point(243, 2); + this.meleeDamageLabel.Name = "meleeDamageLabel"; + this.meleeDamageLabel.Size = new System.Drawing.Size(129, 20); + this.meleeDamageLabel.TabIndex = 82; + this.meleeDamageLabel.Text = "Melee Damage"; + // + // bonusCutUpDown + // + this.bonusCutUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "MeleeCut", true)); + this.bonusCutUpDown.Location = new System.Drawing.Point(81, 162); + this.bonusCutUpDown.Maximum = new decimal(new int[] { + 99999, + 0, + 0, + 0}); + this.bonusCutUpDown.Name = "bonusCutUpDown"; + this.bonusCutUpDown.Size = new System.Drawing.Size(58, 20); + this.bonusCutUpDown.TabIndex = 83; + this.bonusCutUpDown.ValueChanged += new System.EventHandler(this.bonusCutUpDown_ValueChanged); + // + // bonusCutLabel + // + this.bonusCutLabel.AutoSize = true; + this.bonusCutLabel.Location = new System.Drawing.Point(20, 164); + this.bonusCutLabel.Name = "bonusCutLabel"; + this.bonusCutLabel.Size = new System.Drawing.Size(56, 13); + this.bonusCutLabel.TabIndex = 84; + this.bonusCutLabel.Text = "Bonus Cut"; + // + // meleeDiceLabel + // + this.meleeDiceLabel.AutoSize = true; + this.meleeDiceLabel.Location = new System.Drawing.Point(271, 171); + this.meleeDiceLabel.Name = "meleeDiceLabel"; + this.meleeDiceLabel.Size = new System.Drawing.Size(61, 13); + this.meleeDiceLabel.TabIndex = 85; + this.meleeDiceLabel.Text = "Melee Dice"; + // + // meleeDiceUpdown + // + this.meleeDiceUpdown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "MeleeDice", true)); + this.meleeDiceUpdown.Location = new System.Drawing.Point(338, 169); + this.meleeDiceUpdown.Maximum = new decimal(new int[] { + 99999, + 0, + 0, + 0}); + this.meleeDiceUpdown.Minimum = new decimal(new int[] { + 1, + 0, + 0, + 0}); + this.meleeDiceUpdown.Name = "meleeDiceUpdown"; + this.meleeDiceUpdown.Size = new System.Drawing.Size(41, 20); + this.meleeDiceUpdown.TabIndex = 86; + this.meleeDiceUpdown.Value = new decimal(new int[] { + 1, + 0, + 0, + 0}); + this.meleeDiceUpdown.ValueChanged += new System.EventHandler(this.meleeDiceUpdown_ValueChanged); + // + // meleeDiceSidesUpDown + // + this.meleeDiceSidesUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "MeleeDiceSides", true)); + this.meleeDiceSidesUpDown.Location = new System.Drawing.Point(396, 169); + this.meleeDiceSidesUpDown.Maximum = new decimal(new int[] { + 99999, + 0, + 0, + 0}); + this.meleeDiceSidesUpDown.Minimum = new decimal(new int[] { + 1, + 0, + 0, + 0}); + this.meleeDiceSidesUpDown.Name = "meleeDiceSidesUpDown"; + this.meleeDiceSidesUpDown.Size = new System.Drawing.Size(46, 20); + this.meleeDiceSidesUpDown.TabIndex = 87; + this.meleeDiceSidesUpDown.Value = new decimal(new int[] { + 1, + 0, + 0, + 0}); + this.meleeDiceSidesUpDown.ValueChanged += new System.EventHandler(this.meleeDiceSidesUpDown_ValueChanged); + // + // label2 + // + this.label2.AutoSize = true; + this.label2.Location = new System.Drawing.Point(381, 172); + this.label2.Name = "label2"; + this.label2.Size = new System.Drawing.Size(13, 13); + this.label2.TabIndex = 88; + this.label2.Text = "d"; + // + // label3 + // + this.label3.AutoSize = true; + this.label3.Location = new System.Drawing.Point(448, 172); + this.label3.Name = "label3"; + this.label3.Size = new System.Drawing.Size(19, 13); + this.label3.TabIndex = 89; + this.label3.Text = "=>"; + // + // meleeDamageRangeLabel + // + this.meleeDamageRangeLabel.AutoSize = true; + this.meleeDamageRangeLabel.Location = new System.Drawing.Point(473, 172); + this.meleeDamageRangeLabel.Name = "meleeDamageRangeLabel"; + this.meleeDamageRangeLabel.Size = new System.Drawing.Size(28, 13); + this.meleeDamageRangeLabel.TabIndex = 90; + this.meleeDamageRangeLabel.Text = "1 - 1"; + this.meleeDamageRangeLabel.Click += new System.EventHandler(this.meleeDamageRangeLabel_Click); + // + // meleeSkillUpDown + // + this.meleeSkillUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.mtypeBindingSource, "MeleeSkill", true)); + this.meleeSkillUpDown.Location = new System.Drawing.Point(209, 170); + this.meleeSkillUpDown.Maximum = new decimal(new int[] { + 99999, + 0, + 0, + 0}); + this.meleeSkillUpDown.Name = "meleeSkillUpDown"; + this.meleeSkillUpDown.Size = new System.Drawing.Size(58, 20); + this.meleeSkillUpDown.TabIndex = 91; + // + // meleeSkillLabel + // + this.meleeSkillLabel.AutoSize = true; + this.meleeSkillLabel.Location = new System.Drawing.Point(146, 172); + this.meleeSkillLabel.Name = "meleeSkillLabel"; + this.meleeSkillLabel.Size = new System.Drawing.Size(58, 13); + this.meleeSkillLabel.TabIndex = 92; + this.meleeSkillLabel.Text = "Melee Skill"; + // // mtypeBindingSource // this.mtypeBindingSource.DataSource = typeof(cdda_item_creator.Mtype); @@ -459,11 +1135,161 @@ private void InitializeComponent() // this.monsterNameStringsBindingSource.DataSource = typeof(cdda_item_creator.Translation); // + // pathSettingsPanel + // + this.pathSettingsPanel.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.pathSettingsPanel.Controls.Add(this.label7); + this.pathSettingsPanel.Controls.Add(this.checkBox3); + this.pathSettingsPanel.Controls.Add(this.checkBox2); + this.pathSettingsPanel.Controls.Add(this.checkBox1); + this.pathSettingsPanel.Controls.Add(this.label6); + this.pathSettingsPanel.Controls.Add(this.label5); + this.pathSettingsPanel.Controls.Add(this.label4); + this.pathSettingsPanel.Controls.Add(this.pathSettingsBashStrengthUpDown); + this.pathSettingsPanel.Controls.Add(this.pathSettingsMaxLengthUpDown); + this.pathSettingsPanel.Controls.Add(this.pathSettingsMaxDistUpDown); + this.pathSettingsPanel.Location = new System.Drawing.Point(446, 104); + this.pathSettingsPanel.Name = "pathSettingsPanel"; + this.pathSettingsPanel.Size = new System.Drawing.Size(251, 95); + this.pathSettingsPanel.TabIndex = 71; + // + // pathSettingsMaxDistUpDown + // + this.pathSettingsMaxDistUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.pathSettingsDataBindingSource, "MaxDist", true)); + this.pathSettingsMaxDistUpDown.Location = new System.Drawing.Point(77, 25); + this.pathSettingsMaxDistUpDown.Name = "pathSettingsMaxDistUpDown"; + this.pathSettingsMaxDistUpDown.Size = new System.Drawing.Size(50, 20); + this.pathSettingsMaxDistUpDown.TabIndex = 0; + // + // pathSettingsMaxLengthUpDown + // + this.pathSettingsMaxLengthUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.pathSettingsDataBindingSource, "MaxLength", true)); + this.pathSettingsMaxLengthUpDown.Location = new System.Drawing.Point(77, 47); + this.pathSettingsMaxLengthUpDown.Minimum = new decimal(new int[] { + 1, + 0, + 0, + -2147483648}); + this.pathSettingsMaxLengthUpDown.Name = "pathSettingsMaxLengthUpDown"; + this.pathSettingsMaxLengthUpDown.Size = new System.Drawing.Size(50, 20); + this.pathSettingsMaxLengthUpDown.TabIndex = 1; + this.pathSettingsMaxLengthUpDown.Value = new decimal(new int[] { + 1, + 0, + 0, + -2147483648}); + // + // pathSettingsBashStrengthUpDown + // + this.pathSettingsBashStrengthUpDown.DataBindings.Add(new System.Windows.Forms.Binding("Value", this.pathSettingsDataBindingSource, "BashStrength", true)); + this.pathSettingsBashStrengthUpDown.Location = new System.Drawing.Point(77, 69); + this.pathSettingsBashStrengthUpDown.Minimum = new decimal(new int[] { + 1, + 0, + 0, + -2147483648}); + this.pathSettingsBashStrengthUpDown.Name = "pathSettingsBashStrengthUpDown"; + this.pathSettingsBashStrengthUpDown.Size = new System.Drawing.Size(50, 20); + this.pathSettingsBashStrengthUpDown.TabIndex = 2; + this.pathSettingsBashStrengthUpDown.Value = new decimal(new int[] { + 1, + 0, + 0, + -2147483648}); + // + // label4 + // + this.label4.AutoSize = true; + this.label4.Location = new System.Drawing.Point(3, 28); + this.label4.Name = "label4"; + this.label4.Size = new System.Drawing.Size(72, 13); + this.label4.TabIndex = 3; + this.label4.Text = "Max Distance"; + // + // label5 + // + this.label5.AutoSize = true; + this.label5.Location = new System.Drawing.Point(12, 49); + this.label5.Name = "label5"; + this.label5.Size = new System.Drawing.Size(63, 13); + this.label5.TabIndex = 4; + this.label5.Text = "Max Length"; + // + // label6 + // + this.label6.AutoSize = true; + this.label6.Location = new System.Drawing.Point(1, 68); + this.label6.Name = "label6"; + this.label6.Size = new System.Drawing.Size(74, 13); + this.label6.TabIndex = 5; + this.label6.Text = "Bash Strength"; + // + // checkBox1 + // + this.checkBox1.AutoSize = true; + this.checkBox1.DataBindings.Add(new System.Windows.Forms.Binding("Checked", this.pathSettingsDataBindingSource, "AllowOpenDoors", true)); + this.checkBox1.Location = new System.Drawing.Point(133, 29); + this.checkBox1.Name = "checkBox1"; + this.checkBox1.Size = new System.Drawing.Size(111, 17); + this.checkBox1.TabIndex = 6; + this.checkBox1.Text = "Allow Open Doors"; + this.checkBox1.UseVisualStyleBackColor = true; + // + // checkBox2 + // + this.checkBox2.AutoSize = true; + this.checkBox2.DataBindings.Add(new System.Windows.Forms.Binding("Checked", this.pathSettingsDataBindingSource, "AvoidTraps", true)); + this.checkBox2.Location = new System.Drawing.Point(133, 51); + this.checkBox2.Name = "checkBox2"; + this.checkBox2.Size = new System.Drawing.Size(83, 17); + this.checkBox2.TabIndex = 7; + this.checkBox2.Text = "Avoid Traps"; + this.checkBox2.UseVisualStyleBackColor = true; + // + // checkBox3 + // + this.checkBox3.AutoSize = true; + this.checkBox3.Checked = true; + this.checkBox3.CheckState = System.Windows.Forms.CheckState.Checked; + this.checkBox3.DataBindings.Add(new System.Windows.Forms.Binding("Checked", this.pathSettingsDataBindingSource, "AllowClimbStairs", true)); + this.checkBox3.Location = new System.Drawing.Point(133, 72); + this.checkBox3.Name = "checkBox3"; + this.checkBox3.Size = new System.Drawing.Size(108, 17); + this.checkBox3.TabIndex = 8; + this.checkBox3.Text = "Allow Climb Stairs"; + this.checkBox3.UseVisualStyleBackColor = true; + // + // label7 + // + this.label7.AutoSize = true; + this.label7.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label7.Location = new System.Drawing.Point(62, 2); + this.label7.Name = "label7"; + this.label7.Size = new System.Drawing.Size(118, 20); + this.label7.TabIndex = 9; + this.label7.Text = "Path Settings"; + // + // pathSettingsDataBindingSource + // + this.pathSettingsDataBindingSource.DataSource = typeof(cdda_item_creator.PathSettingsData); + // // MonsterForm // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(800, 450); + this.Controls.Add(this.pathSettingsPanel); + this.Controls.Add(this.combatEffectivenessPanel); + this.Controls.Add(this.difficultyLabel); + this.Controls.Add(this.diffLabel); + this.Controls.Add(this.diffUpDown); + this.Controls.Add(this.looksLikeTextBox); + this.Controls.Add(this.label1); + this.Controls.Add(this.defaultFactionLabel); + this.Controls.Add(this.defaultFactionTextBox); + this.Controls.Add(this.categoriesDataGrid); + this.Controls.Add(this.speciesDataGrid); + this.Controls.Add(this.materialDataGrid); this.Controls.Add(this.colorLabel); this.Controls.Add(this.colorComboBox); this.Controls.Add(this.descriptionLabel); @@ -479,8 +1305,6 @@ private void InitializeComponent() this.Controls.Add(this.volumeListbox); this.Controls.Add(this.volumeLabel); this.Controls.Add(this.volumeUpDown); - this.Controls.Add(this.hpLabel); - this.Controls.Add(this.hpUpDown); this.Controls.Add(this.pluralNameLabel); this.Controls.Add(this.pluralNameTextBox); this.Controls.Add(this.idLabel); @@ -495,13 +1319,40 @@ private void InitializeComponent() ((System.ComponentModel.ISupportInitialize)(this.weightUpDown)).EndInit(); this.armorPanel.ResumeLayout(false); this.armorPanel.PerformLayout(); - ((System.ComponentModel.ISupportInitialize)(this.numericUpDown1)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.numericUpDown2)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.numericUpDown3)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.numericUpDown4)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.numericUpDown5)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.stabArmorUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.acidArmorUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.cutArmorUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.fireArmorUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.bashArmorUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.materialDataGrid)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.materialBindingSource)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.speciesDataGrid)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.categoriesDataGrid)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.diffUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.aggressionUpDown)).EndInit(); + this.combatEffectivenessPanel.ResumeLayout(false); + this.combatEffectivenessPanel.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.damageInstanceDataGrid)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.dodgeUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.grabStrengthUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.moraleUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.speedUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.damageInstanceArmorPenetrationUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.damageInstanceAmountUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.damageInstanceArmorMultiplierUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.damageInstanceDamageMultiplierUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.bonusCutUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.meleeDiceUpdown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.meleeDiceSidesUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.meleeSkillUpDown)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.mtypeBindingSource)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.monsterNameStringsBindingSource)).EndInit(); + this.pathSettingsPanel.ResumeLayout(false); + this.pathSettingsPanel.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.pathSettingsMaxDistUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.pathSettingsMaxLengthUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.pathSettingsBashStrengthUpDown)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.pathSettingsDataBindingSource)).EndInit(); this.ResumeLayout(false); this.PerformLayout(); @@ -529,14 +1380,14 @@ private void InitializeComponent() private System.Windows.Forms.TextBox symbolTextBox; private System.Windows.Forms.Label symbolLabel; private System.Windows.Forms.Panel armorPanel; - private System.Windows.Forms.NumericUpDown numericUpDown1; + private System.Windows.Forms.NumericUpDown bashArmorUpDown; private System.Windows.Forms.Label cutArmorLabel; private System.Windows.Forms.Label bashArmorLabel; private System.Windows.Forms.Label armorLabel; - private System.Windows.Forms.NumericUpDown numericUpDown5; - private System.Windows.Forms.NumericUpDown numericUpDown4; - private System.Windows.Forms.NumericUpDown numericUpDown3; - private System.Windows.Forms.NumericUpDown numericUpDown2; + private System.Windows.Forms.NumericUpDown stabArmorUpDown; + private System.Windows.Forms.NumericUpDown acidArmorUpDown; + private System.Windows.Forms.NumericUpDown cutArmorUpDown; + private System.Windows.Forms.NumericUpDown fireArmorUpDown; private System.Windows.Forms.Label acidArmorLabel; private System.Windows.Forms.Label stabArmorLabel; private System.Windows.Forms.Label fireArmorLabel; @@ -546,5 +1397,65 @@ private void InitializeComponent() private System.Windows.Forms.Label descriptionLabel; private System.Windows.Forms.ComboBox colorComboBox; private System.Windows.Forms.Label colorLabel; + private System.Windows.Forms.DataGridView materialDataGrid; + private System.Windows.Forms.BindingSource materialBindingSource; + private System.Windows.Forms.DataGridViewTextBoxColumn Material; + private System.Windows.Forms.DataGridView speciesDataGrid; + private System.Windows.Forms.DataGridViewTextBoxColumn species; + private System.Windows.Forms.DataGridView categoriesDataGrid; + private System.Windows.Forms.DataGridViewTextBoxColumn Categories; + private System.Windows.Forms.Label label1; + private System.Windows.Forms.Label defaultFactionLabel; + private System.Windows.Forms.TextBox defaultFactionTextBox; + private System.Windows.Forms.TextBox looksLikeTextBox; + private System.Windows.Forms.NumericUpDown diffUpDown; + private System.Windows.Forms.Label diffLabel; + private System.Windows.Forms.Label difficultyLabel; + private System.Windows.Forms.NumericUpDown aggressionUpDown; + private System.Windows.Forms.Label aggressionLabel; + private System.Windows.Forms.Panel combatEffectivenessPanel; + private System.Windows.Forms.NumericUpDown speedUpDown; + private System.Windows.Forms.Label moraleLabel; + private System.Windows.Forms.NumericUpDown moraleUpDown; + private System.Windows.Forms.Label speedLabel; + private System.Windows.Forms.Label dodgeLabel; + private System.Windows.Forms.NumericUpDown dodgeUpDown; + private System.Windows.Forms.Label grabStrengthLabel; + private System.Windows.Forms.NumericUpDown grabStrengthUpDown; + private System.Windows.Forms.DataGridView damageInstanceDataGrid; + private System.Windows.Forms.ComboBox damageInstanceTypeComboBox; + private System.Windows.Forms.DataGridViewTextBoxColumn Type; + private System.Windows.Forms.DataGridViewTextBoxColumn Amount; + private System.Windows.Forms.DataGridViewTextBoxColumn ArmorPenetration; + private System.Windows.Forms.DataGridViewTextBoxColumn ArmorMultiplier; + private System.Windows.Forms.DataGridViewTextBoxColumn DamageMultiplier; + private System.Windows.Forms.Button damageInstanceAddButton; + private System.Windows.Forms.NumericUpDown damageInstanceDamageMultiplierUpDown; + private System.Windows.Forms.NumericUpDown damageInstanceArmorMultiplierUpDown; + private System.Windows.Forms.NumericUpDown damageInstanceAmountUpDown; + private System.Windows.Forms.NumericUpDown damageInstanceArmorPenetrationUpDown; + private System.Windows.Forms.Label meleeDamageLabel; + private System.Windows.Forms.NumericUpDown bonusCutUpDown; + private System.Windows.Forms.Label bonusCutLabel; + private System.Windows.Forms.Label label2; + private System.Windows.Forms.NumericUpDown meleeDiceSidesUpDown; + private System.Windows.Forms.NumericUpDown meleeDiceUpdown; + private System.Windows.Forms.Label meleeDiceLabel; + private System.Windows.Forms.Label meleeDamageRangeLabel; + private System.Windows.Forms.Label label3; + private System.Windows.Forms.Label meleeSkillLabel; + private System.Windows.Forms.NumericUpDown meleeSkillUpDown; + private System.Windows.Forms.Panel pathSettingsPanel; + private System.Windows.Forms.Label label7; + private System.Windows.Forms.CheckBox checkBox3; + private System.Windows.Forms.CheckBox checkBox2; + private System.Windows.Forms.CheckBox checkBox1; + private System.Windows.Forms.Label label6; + private System.Windows.Forms.Label label5; + private System.Windows.Forms.Label label4; + private System.Windows.Forms.NumericUpDown pathSettingsBashStrengthUpDown; + private System.Windows.Forms.NumericUpDown pathSettingsMaxLengthUpDown; + private System.Windows.Forms.NumericUpDown pathSettingsMaxDistUpDown; + private System.Windows.Forms.BindingSource pathSettingsDataBindingSource; } } \ No newline at end of file diff --git a/MonsterForm.cs b/MonsterForm.cs index 250ecb0..dcf8028 100644 --- a/MonsterForm.cs +++ b/MonsterForm.cs @@ -30,17 +30,44 @@ public MonsterForm() loadColors(); mtypeBindingSource.Add(main_monster); monsterNameStringsBindingSource.Add(main_monster.Name); + pathSettingsDataBindingSource.Add(main_monster.PathSettings); volumeListbox.SelectedIndex = 0; weightComboBox.SelectedIndex = 1; colorComboBox.SelectedIndex = 0; + damageInstanceTypeComboBox.SelectedIndex = 0; } - - private void clipboardButton_Click(object sender, EventArgs e) + private List ListDataUpdater( DataGridView info ) + { + List ret = null; + if( info.Rows.Count > 0) + { + ret = new List { }; + } + foreach(DataGridViewRow row in info.Rows) + { + string text = (string)row.Cells[0].Value; + if( text != null) + { + ret.Add(text); + } + } + return ret; + } + private void UpdateMonsterDataGrid() { main_monster.UpdateVolume((int)volumeUpDown.Value, volumeListbox.Text); main_monster.UpdateWeight((int)weightUpDown.Value, weightComboBox.Text); - DefaultContractResolver contractResolver = new DefaultContractResolver + main_monster.Material = ListDataUpdater(materialDataGrid); + main_monster.Species = ListDataUpdater(speciesDataGrid); + main_monster.Categories = ListDataUpdater(categoriesDataGrid); + } + + private void clipboardButton_Click(object sender, EventArgs e) + { + UpdateMonsterDataGrid(); + + IgnoreEmptyEnumerablesResolver contractResolver = new IgnoreEmptyEnumerablesResolver { NamingStrategy = new SnakeCaseNamingStrategy() }; @@ -55,5 +82,50 @@ private void clipboardButton_Click(object sender, EventArgs e) } )); } + + private void damageInstanceAddButton_Click(object sender, EventArgs e) + { + damageInstanceDataGrid.Rows.Add( + damageInstanceTypeComboBox.Text, + damageInstanceAmountUpDown.Value, + damageInstanceArmorPenetrationUpDown.Value, + damageInstanceArmorMultiplierUpDown.Value, + damageInstanceDamageMultiplierUpDown.Value + ); + } + + private void difficultyLabel_Click(object sender, EventArgs e) + { + UpdateMonsterDataGrid(); + difficultyLabel.Text = "Calculated Difficulty (click to update): " + main_monster.Difficulty().ToString(); + } + private void UpdateMeleeDamageRange() + { + int min_damage = main_monster.MeleeDice; + int max_damage = min_damage * main_monster.MeleeDiceSides; + min_damage += main_monster.MeleeCut; + max_damage += main_monster.MeleeCut; + meleeDamageRangeLabel.Text = min_damage.ToString() + " - " + max_damage.ToString(); + meleeDamageRangeLabel.Refresh(); + } + private void meleeDiceUpdown_ValueChanged(object sender, EventArgs e) + { + UpdateMeleeDamageRange(); + } + + private void meleeDiceSidesUpDown_ValueChanged(object sender, EventArgs e) + { + UpdateMeleeDamageRange(); + } + + private void bonusCutUpDown_ValueChanged(object sender, EventArgs e) + { + UpdateMeleeDamageRange(); + } + + private void meleeDamageRangeLabel_Click(object sender, EventArgs e) + { + UpdateMeleeDamageRange(); + } } } diff --git a/MonsterForm.resx b/MonsterForm.resx index 7002043..e0aeea4 100644 --- a/MonsterForm.resx +++ b/MonsterForm.resx @@ -123,10 +123,64 @@ 17, 17 + + True + + + True + + + 428, 17 + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + 17, 17 182, 17 + + 603, 17 + \ No newline at end of file diff --git a/Properties/DataSources/PathSettingsData.datasource b/Properties/DataSources/PathSettingsData.datasource new file mode 100644 index 0000000..7a95bd6 --- /dev/null +++ b/Properties/DataSources/PathSettingsData.datasource @@ -0,0 +1,10 @@ + + + + cdda_item_creator.PathSettingsData, cdda-item-creator, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + \ No newline at end of file diff --git a/cdda-item-creator.csproj b/cdda-item-creator.csproj index f229c31..0107fcb 100644 --- a/cdda-item-creator.csproj +++ b/cdda-item-creator.csproj @@ -49,6 +49,7 @@ + Form @@ -95,6 +96,7 @@ + SettingsSingleFileGenerator Settings.Designer.cs diff --git a/cdda-item-creator.pdb b/cdda-item-creator.pdb index ecc9fe3..90a9f40 100644 Binary files a/cdda-item-creator.pdb and b/cdda-item-creator.pdb differ diff --git a/custom_json.cs b/custom_json.cs new file mode 100644 index 0000000..9a1c1e5 --- /dev/null +++ b/custom_json.cs @@ -0,0 +1,44 @@ +using Newtonsoft.Json; +using Newtonsoft.Json.Serialization; +using System; +using System.Collections; +using System.Collections.Generic; +using System.Linq; +using System.Reflection; +using System.Text; +using System.Threading.Tasks; + +namespace cdda_item_creator +{ + public class IgnoreEmptyEnumerablesResolver : DefaultContractResolver + { + protected override JsonProperty CreateProperty(MemberInfo member, MemberSerialization memberSerialization) + { + JsonProperty property = base.CreateProperty(member, memberSerialization); + + if (property.DeclaringType is IEnumerable) + { + property.ShouldSerialize = instance => + { + IEnumerable enumer = instance + .GetType() + .GetProperty(property.PropertyName) + .GetValue(instance, null) as IEnumerable; + + if (enumer != null) + { + // check to see if there is at least one item in the Enumerable + return enumer.GetEnumerator().MoveNext(); + } + else + { + // if the enumerable is null, we defer the decision to NullValueHandling + return true; + } + }; + } + + return property; + } + } +} diff --git a/mtype.cs b/mtype.cs index 87a98dd..0f19efb 100644 --- a/mtype.cs +++ b/mtype.cs @@ -19,20 +19,21 @@ class PathSettingsData { public int MaxDist { get; set; } [DefaultValue(-1)] - public int MaxLength { get; set; } + public int MaxLength { get; set; } = -1; [DefaultValue(-1)] - public int BashStrength { get; set; } + public int BashStrength { get; set; } = -1; [DefaultValue(false)] public bool AllowOpenDoors { get; set; } [DefaultValue(false)] public bool AvoidTraps { get; set; } [DefaultValue(true)] - public bool AllowClimbStairs { get; set; } + public bool AllowClimbStairs { get; set; } = true; } class DamageUnit { - public float amount; + public string Type; + public float Amount; public int ArmorPenetration; [DefaultValue(1.0f)] public float ArmorMultiplier = 1.0f; @@ -64,6 +65,9 @@ class Mtype [DefaultValue("")] public string Volume { get; set; } = ""; public string Color { get; set; } + public List Material { get; set; } + public List Species { get; set; } + public List Categories { get; set; } [DefaultValue("")] public string Weight { get; set; } = ""; public int Speed { get; set; } @@ -74,8 +78,8 @@ class Mtype public float MountableWeightRatio { get; set; } public int AttackCost { get; set; } public int MeleeSkill { get; set; } - public int MeleeDice { get; set; } - public int MeleeDiceSides { get; set; } + public int MeleeDice { get; set; } = 1; + public int MeleeDiceSides { get; set; } = 1; public int GrabStrength { get; set; } public int Dodge { get; set; } public int ArmorBash { get; set; } @@ -94,7 +98,7 @@ class Mtype public int MechStrBonus { get; set; } [DefaultValue("")] public string MechBattery { get; set; } = ""; - public DamageInstance melee_damage; + public DamageInstance MeleeDamage; public int MeleeCut { get; set; } // mandatory json member public string Harvest { get; set; } = ""; @@ -102,7 +106,7 @@ class Mtype public string BurnInto { get; set; } = ""; [DefaultValue(-1)] public int BashSkill { get; set; } = -1; - public PathSettingsData PathSettings { get; set; } + public PathSettingsData PathSettings { get; set; } = new PathSettingsData { }; public void UpdateVolume( int num_part, string unit ) { @@ -113,5 +117,15 @@ public void UpdateWeight( int num_part, string unit ) { Weight = num_part.ToString() + " " + unit; } + + public int Difficulty() + { + int difficulty = (int)((MeleeSkill + 1) * MeleeDice * (MeleeCut + MeleeDiceSides) * 0.04 + + (Dodge + 1) * (3 + ArmorBash + ArmorCut) * 0.04 + + (Diff /* + special_attacks.size() + 8 * emit_fields.size() */)); + difficulty = (int)( difficulty * (Hp + Speed - AttackCost + (Morale + Aggression) * 0.1) * 0.01 + + (VisionDay + 2 * VisionNight) * 0.01); + return difficulty; + } } } diff --git a/spell_form.cs b/spell_form.cs index ee3f4fd..28a6a8c 100644 --- a/spell_form.cs +++ b/spell_form.cs @@ -60,7 +60,6 @@ private void clipboard_button_Click(object sender, EventArgs e) main_spell.AffectedBps = effected_body_part_listbox.CheckedItems.Cast().ToList(); main_spell.EffectTargets = effect_filter_listbox.CheckedItems.Cast().ToList(); - main_spell.ExtraEffects = null; if(additionalSpellGrid.Rows.Count > 0) { main_spell.ExtraEffects = new List { }; @@ -76,7 +75,6 @@ private void clipboard_button_Click(object sender, EventArgs e) main_spell.ExtraEffects.Add(spell); } - main_spell.LearnSpells = null; if (spellsLearnedGrid.Rows.Count > 0) { main_spell.LearnSpells = new Dictionary { }; @@ -87,7 +85,7 @@ private void clipboard_button_Click(object sender, EventArgs e) } - DefaultContractResolver contractResolver = new DefaultContractResolver + IgnoreEmptyEnumerablesResolver contractResolver = new IgnoreEmptyEnumerablesResolver { NamingStrategy = new SnakeCaseNamingStrategy() };