private void NewCharacter_Click_1(object sender, EventArgs e) { using (var form = new CharacterCreation()) { var result = form.ShowDialog(); if (result == DialogResult.OK) { this.New = form.NewCharacter; //values preserved after close Roster.Add(this.New); CharacterScrollList.Clear(); update_List(); } } }
private void NewNPC_Click(object sender, EventArgs e) { using (var form = new CharacterCreation()) { var result = form.ShowDialog(); if (result == DialogResult.OK) { Character C = form.NewCharacter; //values preserved after close FULL_Roster.Add(C); PartyRoster.Clear(); update_List(); } } }
private void Edit_Character_Click(object sender, EventArgs e) { if (CharacterScrollList.SelectedItems.Count < 1) { return; } using (var form = new CharacterCreation((Character)CharacterScrollList.SelectedItems[0].Tag)) { var result = form.ShowDialog(); if (result == DialogResult.OK) { this.New = form.NewCharacter; //values preserved after close Roster.RemoveAt(CharacterScrollList.SelectedItems[0].Index); Roster.Add(this.New); CharacterScrollList.Clear(); update_List(); } } }