Skip to content

Commit

Permalink
feat: add colour for version command output
Browse files Browse the repository at this point in the history
  • Loading branch information
wu-vincent committed Mar 4, 2024
1 parent d4e2c84 commit 7e9e713
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/endstone_core/command/defaults/version_command.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
#include "endstone/detail/command/command_map.h"
#include "endstone/detail/server.h"
#include "endstone/detail/singleton.h"
#include "endstone/util/color_format.h"

endstone::detail::VersionCommand::VersionCommand() : Command("version")
{
Expand All @@ -28,7 +29,7 @@ endstone::detail::VersionCommand::VersionCommand() : Command("version")
bool endstone::detail::VersionCommand::execute(CommandSender &sender,
const std::map<std::string, std::string> &args) const
{
sender.sendMessage("This server is running Endstone version: {}",
sender.sendMessage(ColorFormat::GOLD + "This server is running Endstone version: {}",
Singleton<EndstoneServer>::getInstance().getVersion());
return true;
}

0 comments on commit 7e9e713

Please sign in to comment.