Exemplo n.º 1
0
        public async Task Mreact(
            [Summary("The message")] ulong mid,
            [Summary("The reaction (Use the actual emoji.)")] string reaction)
        {
            var msg = await Context.Channel.GetMessageAsync(mid) as RestUserMessage;

            await msg.AddReactionAsync(UtilityModule.InterfacedEmoteConstructor(reaction));

            await Context.Message.DeleteAsync();
        }
Exemplo n.º 2
0
        public async Task Mreact(
            [Summary("The reaction")][Remainder] string reaction)
        {
            IEmote res = UtilityModule.InterfacedEmoteConstructor(reaction);

            var items = await Context.Channel.GetMessagesAsync(2).Flatten();

            int i = 0;

            foreach (IMessage message in items)
            {
                if (i == 1)
                {
                    var msg = await Context.Channel.GetMessageAsync(message.Id) as RestUserMessage;

                    await msg.AddReactionAsync(res);

                    await Context.Message.DeleteAsync();
                }
                i++;
            }
        }