Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix command message #422

Closed
wants to merge 6 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Obsidian/Commands/Framework/Entities/Command.cs
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ public async Task ExecuteAsync(CommandContext context, string[] args)
|| x.GetParameters().Last().GetCustomAttribute<RemainingAttribute>() != null))
{
//throw new InvalidCommandOverloadException($"No such overload for command {this.GetQualifiedName()}");
await context.Sender.SendMessageAsync($"&4Correct usage: {Usage}");
await context.Sender.SendMessageAsync(ChatMessage.Simple($"Correct usage: {Usage}", ChatColor.Red));

return;
}
Expand Down
5 changes: 5 additions & 0 deletions Obsidian/Server.cs
Original file line number Diff line number Diff line change
Expand Up @@ -561,6 +561,11 @@ await player.SendSoundAsync(SoundEffectBuilder.Create(SoundId.EntitySheepAmbient
// Just stop looping.
}

foreach (var client in _clients)
{
client.SendPacket(new DisconnectPacket(ChatMessage.Simple("Server closed"), client.State));
}

Comment on lines +564 to +568
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't belong in the PR

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah sorry. I suck at Git

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will re-open the PR

_logger.LogInformation("The game loop has been stopped");
await WorldManager.FlushLoadedWorldsAsync();
}
Expand Down
Loading