Ejemplo n.º 1
0
        public async Task ReceiveMessageAsync(string message, SocketUser user, ulong chanId) // Called everytimes a message is sent somewhere
        {
            AGame game = _games.Find(x => x.IsSelf(chanId));

            if (game != null)
            {
                await game.CheckCorrectAsync(user, message);
            }
        }
Ejemplo n.º 2
0
        public async Task ReceiveMessageAsync(string message, SocketUser user, ulong chanId, SocketUserMessage msg) // Called everytimes a message is sent somewhere
        {
            if (message.ToLower().EndsWith("replay") || message.ToLower().EndsWith("cancel"))                       // replay and cancel are commands that can be used in the middle of a game
            {
                return;
            }
            AGame game = _games.Find(x => x.IsSelf(chanId));

            if (game != null)
            {
                await game.CheckCorrectAsync(user, message, msg);
            }
        }