Example #1
0
        public static void RunTwitchCommandQueue()
        {
            WriteToConsole("Executing new twitch command queue:");
            while (twitchCommandQueue.Count > 0)
            {
                TwitchCommandInfo commandInfo = twitchCommandQueue.Dequeue();
                switch (commandInfo.command)
                {
                case TwitchCommand.KillRandomPlayer:
                    MurderRandomPlayer();
                    break;

                case TwitchCommand.SwapPlayers:
                    RandomlySwapAllPlayers();
                    break;

                case TwitchCommand.KillNamedPlayer:
                    MurderPlayerByName(commandInfo.infoString);
                    break;

                default:
                    break;
                }
            }
        }
Example #2
0
 public static void AddTwitchCommand(TwitchCommandInfo command)
 {
     twitchCommandQueue.Enqueue(command);
 }