Exemplo n.º 1
0
        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.");
        }
Exemplo n.º 2
0
        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.");
        }
Exemplo n.º 3
0
 private void questTab_KeyDown(object sender, KeyEventArgs e)
 {
     if (e.KeyboardDevice.Modifiers == ModifierKeys.Control && e.Key == Key.S)
     {
         quest_template q = questList.SelectedItem as quest_template;
         if (q != null)
         {
             WorldWorker.SaveQuestTemplate(q);
         }
         LegacyToolBox.AppendMessage("Quest Template " + q.Id + " Saved.");
         e.Handled = true;
     }
 }