private void LoadSkillResponses() { Model vm = GetDialogCustomData <Model>(); List <PCSkill> skills = SkillService.GetPCSkillsForCategory(GetPC().GlobalID, vm.SelectedCategoryID); ClearPageResponses("SkillListPage"); foreach (PCSkill pcSkill in skills) { Skill skill = SkillService.GetSkill(pcSkill.SkillID); AddResponseToPage("SkillListPage", skill.Name + " (Lvl. " + pcSkill.Rank + ")", true, skill.ID); } }
private void HandleCategoryPageResponse(int responseID) { DialogResponse response = GetResponseByID("CategoryPage", responseID); int categoryID = (int)response.CustomData; List <PCSkill> pcSkills = SkillService.GetPCSkillsForCategory(GetPC().GlobalID, categoryID); ClearPageResponses("SkillListPage"); foreach (PCSkill pcSkill in pcSkills) { Skill skill = SkillService.GetSkill(pcSkill.SkillID); AddResponseToPage("SkillListPage", skill.Name, true, pcSkill.SkillID); } ChangePage("SkillListPage"); }