示例#1
0
        public void Start()
        {
            if (!IsListening)
            {
                IsListening = true;

                LiveDataService.MonitorCurrentScreen(OnScreenUpdated);
                LiveDataService.MonitorFormulae(UpdateFormulae);
                LiveDataService.MonitorSaints(UpdateSaints);
            }
        }
示例#2
0
 private static void DoListSaints(string[] args)
 {
     if (args.Length == 1 || args[1] == "list")
     {
         foreach (var l in StaticDataService.Saints)
         {
             Console.WriteLine(l);
         }
     }
     else if (args[1] == "listen")
     {
         StartLiveDataService(() =>
         {
             LiveDataService.MonitorSaints(saints =>
             {
                 Console.WriteLine();
                 foreach (var s in saints)
                 {
                     Console.WriteLine(s);
                 }
             });
         });
     }
 }