예제 #1
0
        public static async Task ModifyAsyncTest(UserAccount user, IUserMessage message, IEmote emote, ContextIds idList)
        {
            switch (emote.Name)
            {
            case "1\u20E3":
                await message.ModifyAsync(m => { m.Embed = MonEmbedBuilder.ModifyAsyncTestPageOne(); });

                break;

            case "2\u20E3":
                await message.ModifyAsync(m => { m.Embed = MonEmbedBuilder.ModifyAsyncTestPageTwo(); });

                break;
            }
        }
예제 #2
0
        public static async Task ModifyAsyncTest(ContextIds context, ulong userId)
        {
            var user = UserHandler.GetUser(userId);

            var message = await _client.GetGuild(context.GuildId).GetTextChannel(context.ChannelId).SendMessageAsync(
                "Modify Async Tester",
                embed: MonEmbedBuilder.ModifyAsyncTestPageOne())
                          .ConfigureAwait(false);

            await message.AddReactionAsync(new Emoji("1\u20E3"));

            await message.AddReactionAsync(new Emoji("2\u20E3"));

            user.RemoveAllReactionMessages(1);

            user.ReactionMessages.Add(message.Id, 13);
        }