示例#1
0
        private async Task OnJoinedGuild(SocketGuild arg)
        {
            await arg.DefaultChannel.TriggerTypingAsync();

            var builder = new EmbedBuilder()
                          .WithThumbnailUrl(arg.CurrentUser.GetAvatarUrl())
                          .WithTitle("Thanks for inviting me!")
                          .WithDescription("I'm still in training, please take care of me...\nType !help for a list of commands.")
                          .WithColor(new Color(33, 176, 252))
                          .WithCurrentTimestamp();
            var embed = builder.Build();
            await arg.DefaultChannel.SendMessageAsync(null, false, embed);

            //calls this method whenever bibs joins a new server so bibs doesn't do a die
            await _servers.ClearFilterAsync(arg.Id);

            await _servers.ClearRaidAsync(arg.Id);

            await _servers.ClearNoWeebAsync(arg.Id);

            await _servers.ClearHasLimitAsync(arg.Id);

            await _servers.ClearHasMarkovAsync(arg.Id);

            await _client.SetGameAsync($"over {_client.Guilds.Count} servers!", null, ActivityType.Watching);
        }