private void questCreate_Click(object sender, RoutedEventArgs e) { quest_template q = WorldWorker.GetQuestTemplate(26035); WorldWorker.SetEntityState(q, EntityState.Added); q.Id = WorldWorker.GenerateNextQuestEntry(); WorldWorker.SaveQuestTemplate(q); LegacyToolBox.Data.QuestTemplate.Add(q); LegacyToolBox.AppendMessage("New Quest " + q.Id + " Created."); }
private void questCopy_Click(object sender, RoutedEventArgs e) { quest_template o = questList.SelectedItem as quest_template; quest_template q = WorldWorker.GetQuestTemplate(o.Id); WorldWorker.SetEntityState(q, EntityState.Added); q.Id = WorldWorker.GenerateNextQuestEntry(); WorldWorker.SaveQuestTemplate(q); LegacyToolBox.Data.QuestTemplate.Add(q); LegacyToolBox.AppendMessage("Quest " + o.Id + " To Quest " + q.Id + " Copied."); }