diff --git a/DiscordIntegration.Bot/Bot.cs b/DiscordIntegration.Bot/Bot.cs index 31e764f..6f8f263 100644 --- a/DiscordIntegration.Bot/Bot.cs +++ b/DiscordIntegration.Bot/Bot.cs @@ -118,7 +118,8 @@ private async void OnReceived(object? sender, ReceivedFullEventArgs ev) else await Client.SetStatusAsync(UserStatus.AFK); - await Client.SetActivityAsync(new Game(command.Parameters[0].ToString())); + if (Client.Activity.Name != command.Parameters[0].ToString()) + await Client.SetActivityAsync(new Game(command.Parameters[0].ToString())); break; } @@ -151,8 +152,13 @@ private async Task DequeueMessages() { string msg = string.Empty; string[] split = message.Value.Split('\n'); + int i = 0; while (msg.Length < 1900) - msg += split; + { + msg += split[i]; + i++; + } + _ = Guild.GetTextChannel(message.Key).SendMessageAsync(embed: await EmbedBuilderService.CreateBasicEmbed($"Server {ServerNumber} Logs", msg, Color.Green)); messages.Add(message.Key, message.Value.Replace(msg, string.Empty)); } diff --git a/DiscordIntegration.Bot/DiscordIntegration.Bot.csproj b/DiscordIntegration.Bot/DiscordIntegration.Bot.csproj index 2ea5285..68de5bf 100644 --- a/DiscordIntegration.Bot/DiscordIntegration.Bot.csproj +++ b/DiscordIntegration.Bot/DiscordIntegration.Bot.csproj @@ -5,8 +5,8 @@ net6.0 enable enable - 1.3.0 - 1.3.0 + 1.3.1 + 1.3.1