mirror of
https://gitlab.com/Kwoth/nadekobot.git
synced 2025-09-11 01:38:27 -04:00
All .AddField calls no longer use builder
- Cleaned up convertlist and listserver embeds slightly
This commit is contained in:
@@ -87,8 +87,8 @@ namespace NadekoBot.Modules.Games.Common.Trivia
|
||||
{
|
||||
questionEmbed = new EmbedBuilder().WithOkColor()
|
||||
.WithTitle(GetText("trivia_game"))
|
||||
.AddField(eab => eab.WithName(GetText("category")).WithValue(CurrentQuestion.Category))
|
||||
.AddField(eab => eab.WithName(GetText("question")).WithValue(CurrentQuestion.Question));
|
||||
.AddField(GetText("category"), CurrentQuestion.Category)
|
||||
.AddField(GetText("question"), CurrentQuestion.Question);
|
||||
|
||||
if (showHowToQuit)
|
||||
questionEmbed.WithFooter(GetText("trivia_quit", _quitCommand));
|
||||
|
@@ -157,15 +157,11 @@ namespace NadekoBot.Modules.Games.Common
|
||||
var wpm = CurrentSentence.Length / WORD_VALUE / elapsed.TotalSeconds * 60;
|
||||
finishedUserIds.Add(msg.Author.Id);
|
||||
await this.Channel.EmbedAsync(new EmbedBuilder().WithOkColor()
|
||||
.WithTitle($"{msg.Author} finished the race!")
|
||||
.AddField(efb =>
|
||||
efb.WithName("Place").WithValue($"#{finishedUserIds.Count}").WithIsInline(true))
|
||||
.AddField(efb =>
|
||||
efb.WithName("WPM").WithValue($"{wpm:F1} *[{elapsed.TotalSeconds:F2}sec]*")
|
||||
.WithIsInline(true))
|
||||
.AddField(efb =>
|
||||
efb.WithName("Errors").WithValue(distance.ToString()).WithIsInline(true)))
|
||||
.ConfigureAwait(false);
|
||||
.WithTitle($"{msg.Author} finished the race!")
|
||||
.AddField("Place", $"#{finishedUserIds.Count}", true)
|
||||
.AddField("WPM", $"{wpm:F1} *[{elapsed.TotalSeconds:F2}sec]*", true)
|
||||
.AddField("Errors", distance.ToString(), true));
|
||||
|
||||
if (finishedUserIds.Count % 4 == 0)
|
||||
{
|
||||
await this.Channel.SendConfirmAsync(
|
||||
|
@@ -89,7 +89,7 @@ namespace NadekoBot.Modules.Games
|
||||
{
|
||||
var loseEmbed = new EmbedBuilder().WithTitle($"Hangman Game ({game.TermType}) - Ended")
|
||||
.WithDescription(Format.Bold("You lose."))
|
||||
.AddField(efb => efb.WithName("It was").WithValue(game.Term.GetWord()))
|
||||
.AddField("It was", game.Term.GetWord())
|
||||
.WithFooter(string.Join(" ", game.PreviousGuesses))
|
||||
.WithErrorColor();
|
||||
|
||||
@@ -101,7 +101,7 @@ namespace NadekoBot.Modules.Games
|
||||
|
||||
var winEmbed = new EmbedBuilder().WithTitle($"Hangman Game ({game.TermType}) - Ended")
|
||||
.WithDescription(Format.Bold($"{winner} Won."))
|
||||
.AddField(efb => efb.WithName("It was").WithValue(game.Term.GetWord()))
|
||||
.AddField("It was", game.Term.GetWord())
|
||||
.WithFooter(string.Join(" ", game.PreviousGuesses))
|
||||
.WithOkColor();
|
||||
|
||||
|
Reference in New Issue
Block a user