diff options
Diffstat (limited to 'DiscoBot/Commands/ProbenTest.cs')
-rw-r--r-- | DiscoBot/Commands/ProbenTest.cs | 29 |
1 files changed, 28 insertions, 1 deletions
diff --git a/DiscoBot/Commands/ProbenTest.cs b/DiscoBot/Commands/ProbenTest.cs index bdfaf23..1d8f8b0 100644 --- a/DiscoBot/Commands/ProbenTest.cs +++ b/DiscoBot/Commands/ProbenTest.cs @@ -2,12 +2,14 @@ { using System.Threading.Tasks; + using DiscoBot.DSA_Game; + using Discord.Commands; public class ProbenTest : ModuleBase { [Command("t"), Summary("Würfelt ein Talent-/Zauberprobe")] - [Alias("T", "Talent", "talent", "zauber", "z", "versuche")] + [Alias("T", "Talent", "talent", "versuche")] public Task TalentAsync([Summary("Talent oder Zaubername")] string talent, int erschwernis = 0) { string res; @@ -31,6 +33,31 @@ return this.ReplyAsync("```xl\n" + res + "\n```"); } + [Command("Zauber"), Summary("Würfelt ein Zauberprobe")] + [Alias("Z", "zauber", "z")] + public Task ZauberAsync([Summary("Zaubername")] string zauber, int erschwernis = 0) + { + string res; + try + { + res = Gm.CheckCommand( + Dsa.Relation[this.Context.User.Username], + CommandTypes.Zauber, + zauber, + erschwernis); + } + catch + { + res = Gm.CheckCommand( + Dsa.Relation["Tardis"], + CommandTypes.Zauber, + zauber, + erschwernis); + } + + return this.ReplyAsync("```xl\n" + res + "\n```"); + } + [Command("e"), Summary("Würfelt eine Eigenschaftsprobe")] [Alias("E", "Eigenschaft", "eigenschaft", "eigen")] public Task EigenschaftAsync([Summary("Eigenschaftskürzel und Erschwernis")] string talent, int erschwernis = 0) |