Пример #1
0
        public async Task ToggleGoodbye()
        {
            var config = GreetingsService.GetGoodbyeConfig(Context.Guild.Id);

            config.Enabled = !config.Enabled;
            GreetingsService.SaveGoodbyeConfig(config);
            await ReplyAsync($"Display Goodbye Messages: {config.Enabled}\nNOTE: You will need to run the `SetGoodbyeChannel` command or enable dms in order for this to work.");
        }
Пример #2
0
        public async Task SetGoodbyeChannel()
        {
            var config = GreetingsService.GetGoodbyeConfig(Context.Guild.Id);

            config.GoodbyeChannel = Context.Channel.Id;
            GreetingsService.SaveGoodbyeConfig(config);
            await ReplyAsync($"Display Goodbye Messages: {config.Enabled}\n" +
                             $"Goodbye channel set to: {Context.Channel.Name}");
        }
Пример #3
0
        public async Task ToggleGoodbyeDms()
        {
            var config = GreetingsService.GetGoodbyeConfig(Context.Guild.Id);

            config.DirectMessage = !config.DirectMessage;
            GreetingsService.SaveGoodbyeConfig(config);
            await ReplyAsync($"Display Goodbye Messages: {config.Enabled}\n" +
                             $"Direct Message Goodbyes: {config.DirectMessage}");
        }
Пример #4
0
        public async Task SetGoodbyeMessage([Remainder] string message = null)
        {
            var config = GreetingsService.GetGoodbyeConfig(Context.Guild.Id);

            config.GoodbyeMessage = message;
            GreetingsService.SaveGoodbyeConfig(config);
            await ReplyAsync($"Display Goodbye Messages: {config.Enabled}\n" +
                             $"**Message**\n" +
                             $"{message ?? "DEFAULT"}");
        }