Esempio n. 1
0
 private async Task ReactionAdded(Cacheable <IUserMessage, ulong> cacheMessage, ISocketMessageChannel channel, SocketReaction reaction)
 {
     if (reaction.User.Value.IsBot)
     {
         return;
     }
     _triviaGames.HandleReactionAdded(cacheMessage, reaction);
     BlogHandler.ReactionAdded(reaction);
 }
        private async Task ReactionAdded(Cacheable <IUserMessage, ulong> cacheMessage, ISocketMessageChannel channel, SocketReaction reaction)
        {
            if (reaction.User.Value.IsBot)
            {
                return;
            }

            InversionOfControl.Container.GetInstance <ListManager>().HandleReactionAdded(cacheMessage, reaction);

            _triviaGames.HandleReactionAdded(cacheMessage, reaction);
            BlogHandler.ReactionAdded(reaction);
        }
        private async Task ReactionAdded(Cacheable <IUserMessage, ulong> cacheMessage, ISocketMessageChannel channel, SocketReaction reaction)
        {
            if (reaction.User.Value.IsBot)
            {
                return;
            }

            var user    = _client.Guilds.First().GetUser(reaction.UserId);
            var roleIds = user.Roles.Select(r => r.Id).ToArray();

            (new ListReactionHandler()).HandleReactionAdded(new ListHelper.UserInfo(user.Id, roleIds), _listManager, cacheMessage, reaction);

            _triviaGames.HandleReactionAdded(cacheMessage, reaction);
            BlogHandler.ReactionAdded(reaction);
        }