From c328ec68d3aa4068f42294816ce6ac1bb3e6e0d3 Mon Sep 17 00:00:00 2001 From: samvaio Date: Thu, 13 Jul 2017 17:34:28 +0530 Subject: [PATCH 1/5] Documents updated macOS prerequisite info added --- docs/JSON Explanations.md | 3 ++- docs/guides/OSX Guide.md | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/docs/JSON Explanations.md b/docs/JSON Explanations.md index 028b1891..eb6fabe4 100644 --- a/docs/JSON Explanations.md +++ b/docs/JSON Explanations.md @@ -185,6 +185,8 @@ in order to open the database file you will need [DB Browser for SQLite](http:// - click on **Apply** - click on **Write Changes** +![nadekodb](https://cdn.discordapp.com/attachments/251504306010849280/254067055240806400/nadekodb.gif) + and that will save all the changes. ## Sharding your bot @@ -205,7 +207,6 @@ and that will save all the changes. - Bot uses a random UDP port in [5000, 6000) range for communication between shards -![nadekodb](https://cdn.discordapp.com/attachments/251504306010849280/254067055240806400/nadekodb.gif) [Google Console]: https://console.developers.google.com [DiscordApp]: https://discordapp.com/developers/applications/me diff --git a/docs/guides/OSX Guide.md b/docs/guides/OSX Guide.md index b9256356..a9d53736 100644 --- a/docs/guides/OSX Guide.md +++ b/docs/guides/OSX Guide.md @@ -24,6 +24,8 @@ brew install opusfile brew install libffi brew install libsodium brew install tmux +brew install python +brew install youtube-dl ``` #### Installing .NET Core SDK From fd410bc85600aff87e3d84fd0879e676cd02336b Mon Sep 17 00:00:00 2001 From: samvaio Date: Thu, 13 Jul 2017 17:36:49 +0530 Subject: [PATCH 2/5] Stop works as it used to before. Auto rpl disabled. Bot no longer repeats playlist on default. Bot now clears the queued songs list (playlist) - if `.stop` command is used. - if the last song of the queue is playing and `.next` command is used. - if the the last song of the queue finished playing. --- src/NadekoBot/Services/Music/MusicPlayer.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/NadekoBot/Services/Music/MusicPlayer.cs b/src/NadekoBot/Services/Music/MusicPlayer.cs index 50779c85..bae20574 100644 --- a/src/NadekoBot/Services/Music/MusicPlayer.cs +++ b/src/NadekoBot/Services/Music/MusicPlayer.cs @@ -62,7 +62,7 @@ namespace NadekoBot.Services.Music public bool RepeatCurrentSong { get; private set; } public bool Shuffle { get; private set; } public bool Autoplay { get; private set; } - public bool RepeatPlaylist { get; private set; } = true; + public bool RepeatPlaylist { get; private set; } = false; public uint MaxQueueSize { get => Queue.MaxQueueSize; @@ -442,12 +442,12 @@ namespace NadekoBot.Services.Music } } - public void Stop(bool clearQueue = false) + public void Stop(bool clearQueue = true) { lock (locker) { - Stopped = true; - Queue.ResetCurrent(); + //Stopped = true; + //Queue.ResetCurrent(); if (clearQueue) Queue.Clear(); Unpause(); From 202c5e98a5006833746d4c40264d13b9338a5627 Mon Sep 17 00:00:00 2001 From: samvaio Date: Thu, 13 Jul 2017 17:45:46 +0530 Subject: [PATCH 3/5] Makeover to highlight the information. Look is similar to early version of Nadeko. --- .../Modules/Administration/Commands/LogCommand.cs | 4 ++-- .../Modules/Administration/Commands/SelfCommands.cs | 8 ++++---- src/NadekoBot/Modules/Utility/Utility.cs | 7 ++++--- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/src/NadekoBot/Modules/Administration/Commands/LogCommand.cs b/src/NadekoBot/Modules/Administration/Commands/LogCommand.cs index 9823d735..dbdb63dc 100644 --- a/src/NadekoBot/Modules/Administration/Commands/LogCommand.cs +++ b/src/NadekoBot/Modules/Administration/Commands/LogCommand.cs @@ -106,8 +106,8 @@ namespace NadekoBot.Modules.Administration [OwnerOnly] public async Task LogEvents() { - await Context.Channel.SendConfirmAsync(GetText("log_events") + "\n" + - string.Join(", ", Enum.GetNames(typeof(LogType)).Cast())) + await Context.Channel.SendConfirmAsync(Format.Bold(GetText("log_events")) + "\n" + + $"```fix\n{string.Join(", ", Enum.GetNames(typeof(LogType)).Cast())}```") .ConfigureAwait(false); } diff --git a/src/NadekoBot/Modules/Administration/Commands/SelfCommands.cs b/src/NadekoBot/Modules/Administration/Commands/SelfCommands.cs index bd1a8eb6..14a9e196 100644 --- a/src/NadekoBot/Modules/Administration/Commands/SelfCommands.cs +++ b/src/NadekoBot/Modules/Administration/Commands/SelfCommands.cs @@ -100,13 +100,13 @@ namespace NadekoBot.Modules.Administration } else { - await Context.Channel.SendConfirmAsync("", string.Join("\n--\n", scmds.Select(x => + await Context.Channel.SendConfirmAsync("", string.Join("\n", scmds.Select(x => { - string str = Format.Code(GetText("server")) + ": " + (x.GuildId == null ? "-" : x.GuildName + "/" + x.GuildId); + string str = $"```css\n[{GetText("server") + "]: " + (x.GuildId == null ? "-" : x.GuildName + " #" + x.GuildId)}"; str += $@" -{Format.Code(GetText("channel"))}: {x.ChannelName}/{x.ChannelId} -{Format.Code(GetText("command_text"))}: {x.CommandText}"; +[{GetText("channel")}]: {x.ChannelName} #{x.ChannelId} +[{GetText("command_text")}]: {x.CommandText}```"; return str; })), footer: GetText("page", page + 1)) .ConfigureAwait(false); diff --git a/src/NadekoBot/Modules/Utility/Utility.cs b/src/NadekoBot/Modules/Utility/Utility.cs index ea76c755..e1cf1226 100644 --- a/src/NadekoBot/Modules/Utility/Utility.cs +++ b/src/NadekoBot/Modules/Utility/Utility.cs @@ -161,11 +161,12 @@ namespace NadekoBot.Modules.Utility var usrs = (await Context.Guild.GetUsersAsync()).ToArray(); var roleUsers = usrs.Where(u => u.RoleIds.Contains(role.Id)).Select(u => u.ToString()) .ToArray(); + var inroleusers = string.Join(", ", roleUsers + .OrderBy(x => rng.Next()) + .Take(50)); var embed = new EmbedBuilder().WithOkColor() .WithTitle("ℹ️ " + Format.Bold(GetText("inrole_list", Format.Bold(role.Name))) + $" - {roleUsers.Length}") - .WithDescription(string.Join(", ", roleUsers - .OrderBy(x => rng.Next()) - .Take(50))); + .WithDescription($"```css\n[{role.Name}]\n{inroleusers}```"); await Context.Channel.EmbedAsync(embed).ConfigureAwait(false); } From f26a7de704ddd92e6321eba04fc5909bac2a0392 Mon Sep 17 00:00:00 2001 From: samvaio Date: Fri, 14 Jul 2017 00:54:23 +0530 Subject: [PATCH 4/5] Revert "Stop works as it used to before. Auto rpl disabled." This reverts commit fd410bc85600aff87e3d84fd0879e676cd02336b. --- src/NadekoBot/Services/Music/MusicPlayer.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/NadekoBot/Services/Music/MusicPlayer.cs b/src/NadekoBot/Services/Music/MusicPlayer.cs index bae20574..50779c85 100644 --- a/src/NadekoBot/Services/Music/MusicPlayer.cs +++ b/src/NadekoBot/Services/Music/MusicPlayer.cs @@ -62,7 +62,7 @@ namespace NadekoBot.Services.Music public bool RepeatCurrentSong { get; private set; } public bool Shuffle { get; private set; } public bool Autoplay { get; private set; } - public bool RepeatPlaylist { get; private set; } = false; + public bool RepeatPlaylist { get; private set; } = true; public uint MaxQueueSize { get => Queue.MaxQueueSize; @@ -442,12 +442,12 @@ namespace NadekoBot.Services.Music } } - public void Stop(bool clearQueue = true) + public void Stop(bool clearQueue = false) { lock (locker) { - //Stopped = true; - //Queue.ResetCurrent(); + Stopped = true; + Queue.ResetCurrent(); if (clearQueue) Queue.Clear(); Unpause(); From 11b533c3b7e596947a811da8acc29f3e422a813e Mon Sep 17 00:00:00 2001 From: samvaio Date: Fri, 14 Jul 2017 09:45:31 +0530 Subject: [PATCH 5/5] Done as per Kwoth. --- src/NadekoBot/Services/Music/MusicPlayer.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/NadekoBot/Services/Music/MusicPlayer.cs b/src/NadekoBot/Services/Music/MusicPlayer.cs index 50779c85..8e47e984 100644 --- a/src/NadekoBot/Services/Music/MusicPlayer.cs +++ b/src/NadekoBot/Services/Music/MusicPlayer.cs @@ -62,7 +62,7 @@ namespace NadekoBot.Services.Music public bool RepeatCurrentSong { get; private set; } public bool Shuffle { get; private set; } public bool Autoplay { get; private set; } - public bool RepeatPlaylist { get; private set; } = true; + public bool RepeatPlaylist { get; private set; } = false; public uint MaxQueueSize { get => Queue.MaxQueueSize; @@ -447,7 +447,7 @@ namespace NadekoBot.Services.Music lock (locker) { Stopped = true; - Queue.ResetCurrent(); + //Queue.ResetCurrent(); if (clearQueue) Queue.Clear(); Unpause();