Beispiel #1
0
        public void Start()
        {
            QuestionUser = ((x) => UserDialog?.Invoke(x));
            Write        = ((x, z) => WriteToConsole?.Invoke(x, z));
            WriteLine    = ((x, z) => WriteLineToConsole?.Invoke(x, z));

            ThreadPool.QueueUserWorkItem(obj =>
            {
                if (!FirstTimeSetup(QuestionUser))
                {
                    throw new Exception("First Time Params Not Set");
                }

                IRCClient.Start(HandleUserCommands, Twitch.TwitchAPI._channel);

                TwitchAPI.Init();
                VoteSystem.Init();
                UserManager.Init();
                IRCClient.Init(ConsoleWrite);
                MemorySystem._instance.Init();
                Microphone.Init();
            });
        }
 public void CustomCommand(int command)
 {
     WriteToConsole?.Invoke("Service has gotten a custom command");
 }
 public void Shutdown()
 {
     WriteToConsole?.Invoke("Service has been shutdown");
 }
 public void Continue()
 {
     WriteToConsole?.Invoke("Service has continued");
 }
 public void Pause()
 {
     WriteToConsole?.Invoke("Service has paused");
 }
 public void Stop()
 {
     WriteToConsole?.Invoke("Service has stopped");
 }
 public void Start(string[] args)
 {
     WriteToConsole?.Invoke("Service has started");
 }