summaryrefslogtreecommitdiff
path: root/DiscoBot/DSA_Game/Save/SaveCommand.cs
blob: 310d38ae0d4ffbbbef65f60e331628903f67b87e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DiscoBot.DSA_Game.Save
{
    using System.IO;
    using System.Net.Http;

    using DiscoBot.Auxiliary;

    using Discord.Commands;

    public class SaveCommand : ModuleBase
    {
        [Command("save"), Summary("Save Session")]
        public async Task ReportAsync()
        {
            

            await this.ReplyAsync($"Dein report wurde hinzugefügt");
        }

        [Command("save"), Summary("Save Session")]
        public async Task ReportAsync([Remainder, Summary("Session Name")] string name)
        {
            if (name.Equals("?"))
            {
                await this.ReplyAsync($"Gespeicherte Sessions:");
                await this.ReplyAsync(this.ListSessions());
            }
        }

        private string[] ListSessions()
        {
            return Directory.GetDirectories(@"..\..\sessions");
        }


    }
}