private void __Button_AddBoosters_Click(object sender, EventArgs e) { // Add boosters to league: List <SkillBoosterPack> boosters = SkillBoosterPack.GenerateBoosterBox(__SelectedSet.SelectedIndex < 0 ? 0 : __SelectedSet.SelectedIndex, (int)__NumberOfBoostersToAdd.Value); // Temporary league to hold the added skills for display purposes... BoosterLeaguePool newBoosters = new BoosterLeaguePool(); newBoosters.AddBox(boosters); newBoosters.SortByProfessionAttribute(); newBoosters.SortByRarity(); League.AddBox(boosters); // Redraw the pool... __LeaguePoolDisplay.Redraw(); // Show a dialog containing the new skills: NewBoostersForLeagueDialog.ShowAddedBoostersDialog((int)__NumberOfBoostersToAdd.Value, newBoosters); }
private void __SortButton_Rarity_Click(object sender, EventArgs e) { League.SortByRarity(); __LeaguePoolDisplay.Redraw(); }