예제 #1
0
        private void EditSkillBtn_Click(object sender, EventArgs e)
        {
            if (this.SelectedSkill == null)
            {
                return;
            }
            string            keyAbility        = Skills.GetKeyAbility(this.SelectedSkill.SkillName);
            CreatureSkillForm creatureSkillForm = new CreatureSkillForm(this.SelectedSkill.SkillName, keyAbility, this.SelectedSkill.Ability, this.SelectedSkill.Level, this.SelectedSkill.Trained, this.SelectedSkill.Misc);

            if (creatureSkillForm.ShowDialog() == System.Windows.Forms.DialogResult.OK)
            {
                this.SelectedSkill.Trained = creatureSkillForm.Trained;
                this.SelectedSkill.Misc    = creatureSkillForm.Misc;
                this.update_list();
            }
        }
예제 #2
0
        private void EditSkillBtn_Click(object sender, EventArgs e)
        {
            if (SelectedSkill == null)
            {
                return;
            }

            string            ability = Skills.GetKeyAbility(SelectedSkill.SkillName);
            CreatureSkillForm dlg     = new CreatureSkillForm(SelectedSkill.SkillName, ability, SelectedSkill.Ability, SelectedSkill.Level, SelectedSkill.Trained, SelectedSkill.Misc);

            if (dlg.ShowDialog() == DialogResult.OK)
            {
                SelectedSkill.Trained = dlg.Trained;
                SelectedSkill.Misc    = dlg.Misc;

                update_list();
            }
        }