protected virtual void ReactionRemoved(MessageReactionRemoveEventArgs e)
        {
            if (!CheckRequirements(e.Channel, e.Message))
            {
                return;
            }

            OnReactionRemoved?.Invoke(e);
        }
Example #2
0
 private Task ReactionRemoved(MessageReactionRemoveEventArgs e)
 {
     if (e.User.IsCurrent)
     {
         return(Task.CompletedTask);
     }
     if (e.Message.Id == _lastBotMessage.Id)
     {
         Console.WriteLine("[{0}] {1} removed reaction {2}", e.User.Id, e.User.Username, e.Emoji.GetDiscordName());
         OnReactionRemoved?.Invoke(e);
     }
     return(Task.CompletedTask);
 }
        private Task Discord_ReactionRemoved(ulong messageId, Optional <SocketUserMessage> arg2, SocketReaction reaction)
        {
            try
            {
                if (messageId == Message.Id)
                {
                    OnReactionRemoved?.Invoke(reaction);
                }
            }
            catch { }

            return(Task.CompletedTask);
        }
Example #4
0
        private Task Discord_ReactionRemoved(Cacheable <IUserMessage, ulong> msg, ISocketMessageChannel channel, SocketReaction reaction)
        {
            Task.Run(() =>
            {
                try
                {
                    if (msg.Id == Message.Id)
                    {
                        OnReactionRemoved?.Invoke(reaction);
                    }
                }
                catch { }
            });

            return(Task.CompletedTask);
        }