From ed19961bd7653daa531d0a6e7ec5b226ded87e1e Mon Sep 17 00:00:00 2001 From: Kwoth Date: Tue, 6 Dec 2016 12:23:21 +0100 Subject: [PATCH 1/3] Prettier >settype --- src/NadekoBot/Modules/Pokemon/Pokemon.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/NadekoBot/Modules/Pokemon/Pokemon.cs b/src/NadekoBot/Modules/Pokemon/Pokemon.cs index 9395cf7b..eebeabb2 100644 --- a/src/NadekoBot/Modules/Pokemon/Pokemon.cs +++ b/src/NadekoBot/Modules/Pokemon/Pokemon.cs @@ -316,7 +316,7 @@ namespace NadekoBot.Modules.Pokemon var targetType = StringToPokemonType(typeTargeted); if (targetType == null) { - await channel.SendTableAsync("`Available types:`\n", PokemonTypes, (t) => $"{t.Icon} {t.Name,-10}").ConfigureAwait(false); + await channel.EmbedAsync(PokemonTypes.Aggregate(new EmbedBuilder().WithDescription("List of the available types:"), (eb, pt) => eb.AddField(efb => efb.WithName(pt.Name).WithValue(pt.Icon).WithIsInline(true))).Build()).ConfigureAwait(false); return; } if (targetType == GetPokeType(user.Id)) From 3d46a77ae10e51ac980f4e3659a74fb0acde7578 Mon Sep 17 00:00:00 2001 From: Kwoth Date: Tue, 6 Dec 2016 12:53:19 +0100 Subject: [PATCH 2/3] pokeman color --- src/NadekoBot/Modules/Pokemon/Pokemon.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/NadekoBot/Modules/Pokemon/Pokemon.cs b/src/NadekoBot/Modules/Pokemon/Pokemon.cs index eebeabb2..35e1b703 100644 --- a/src/NadekoBot/Modules/Pokemon/Pokemon.cs +++ b/src/NadekoBot/Modules/Pokemon/Pokemon.cs @@ -316,7 +316,7 @@ namespace NadekoBot.Modules.Pokemon var targetType = StringToPokemonType(typeTargeted); if (targetType == null) { - await channel.EmbedAsync(PokemonTypes.Aggregate(new EmbedBuilder().WithDescription("List of the available types:"), (eb, pt) => eb.AddField(efb => efb.WithName(pt.Name).WithValue(pt.Icon).WithIsInline(true))).Build()).ConfigureAwait(false); + await channel.EmbedAsync(PokemonTypes.Aggregate(new EmbedBuilder().WithDescription("List of the available types:"), (eb, pt) => eb.AddField(efb => efb.WithName(pt.Name).WithValue(pt.Icon).WithIsInline(true))).WithColor(NadekoBot.OkColor).Build()).ConfigureAwait(false); return; } if (targetType == GetPokeType(user.Id)) From ecd9b5403b92cc738ce845787ed57e9a2bdf25a6 Mon Sep 17 00:00:00 2001 From: Kwoth Date: Tue, 6 Dec 2016 18:02:02 +0100 Subject: [PATCH 3/3] Simplified -h command --- src/NadekoBot/Modules/Help/Help.cs | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/src/NadekoBot/Modules/Help/Help.cs b/src/NadekoBot/Modules/Help/Help.cs index 5661c2b0..0166cf4c 100644 --- a/src/NadekoBot/Modules/Help/Help.cs +++ b/src/NadekoBot/Modules/Help/Help.cs @@ -88,15 +88,7 @@ namespace NadekoBot.Modules.Help if (com == null) { - //await channel.SendMessageAsync("🔍 **I can't find that command.**"); - var erro = new EmbedBuilder() - .WithAuthor(eau => eau.WithName("Sorry!") - .WithUrl("http://nadekobot.readthedocs.io/en/latest/Commands%20List/") - .WithIconUrl(NadekoBot.Client.GetCurrentUser().AvatarUrl)) - //.WithTitle("Sorry!") - .WithDescription("I can't find that command. Please check the **command** and **command prefix** before trying again.") - .WithColor(NadekoBot.ErrorColor); - await channel.EmbedAsync(erro.Build()); + await channel.SendErrorAsync("I can't find that command. Please check the **command** and **command prefix** before trying again."); return; } var str = $"**`{com.Text}`**"; @@ -104,19 +96,11 @@ namespace NadekoBot.Modules.Help if (alias != null) str += $" **/** **`{alias}`**"; var embed = new EmbedBuilder() - .WithAuthor(eau => eau.WithName("Command") - .WithUrl("http://nadekobot.readthedocs.io/en/latest/Commands%20List/") - .WithIconUrl(NadekoBot.Client.GetCurrentUser().AvatarUrl)) - //.WithTitle(str) - //.WithDescription($"{ string.Format(com.Summary, com.Module.Prefix)}{ GetCommandRequirements(com)}") .AddField(fb => fb.WithIndex(1).WithName(str).WithValue($"{ string.Format(com.Summary, com.Module.Prefix)} { GetCommandRequirements(com)}").WithIsInline(true)) .AddField(fb => fb.WithIndex(2).WithName("**Usage**").WithValue($"{string.Format(com.Remarks, com.Module.Prefix)}").WithIsInline(false)) - //.AddField(fb => fb.WithIndex(3).WithName("**Description**").WithValue($"{ string.Format(com.Summary, com.Module.Prefix)}{ GetCommandRequirements(com)}").WithIsInline(true)) .WithColor(NadekoBot.OkColor); if (com != null) await channel.EmbedAsync(embed.Build()).ConfigureAwait(false); - //await channel.SendMessageAsync(str + $@"{Environment.NewLine}**Desc:** {string.Format(com.Summary, com.Module.Prefix)} {GetCommandRequirements(com)} -//**Usage:** {string.Format(com.Remarks, com.Module.Prefix)}").ConfigureAwait(false); } private string GetCommandRequirements(Command cmd)