예제 #1
0
 /// <summary>
 /// Handle the clearing of reactions for services
 /// </summary>
 /// <param name="message"></param>
 /// <returns></returns>
 private static async Task ReactionControlsClearedAsync(Cacheable <IUserMessage, ulong> message)
 {
     if (message.Id == QuoteManagamentService.QuoteConfirmationMessage.Id)
     {
         await QuoteManagamentService.AddReactionsAsync();
     }
 }
예제 #2
0
        /// <summary>
        /// Handle reaction controls for Quotes
        /// </summary>
        /// <param name="reaction"></param>
        private static async Task ReactionControlsAddedAsync(SocketReaction reaction)
        {
            if (QuoteManagamentService.QuoteConfirmationMessage != null)
            {
                if (reaction.MessageId == QuoteManagamentService.QuoteConfirmationMessage.Id)
                {
                    if (reaction.Emote.ToString() == "✅")
                    {
                        await QuoteManagamentService.QuoteConfirmedAsync();
                    }

                    if (reaction.Emote.ToString() == "❎")
                    {
                        await QuoteManagamentService.QuoteDeniedAsync();
                    }
                }
            }
        }