1
0
Fork 0
mirror of https://gitlab.com/niansa/SomeBot.git synced 2025-03-06 20:48:26 +01:00

Changed cout log format a bit

This commit is contained in:
niansa 2022-11-02 15:45:15 +01:00
parent de7a101a21
commit 28a97e5b8b

View file

@ -331,7 +331,7 @@ int main(int argc, char **argv) {
bot.cluster.on_log([&](const dpp::log_t& event) {
auto t = std::time(nullptr);
logfile << "(" << std::put_time(std::localtime(&t), "%Y-%m-%d %H:%M:%S") << ") [" << dpp::utility::loglevel(event.severity) << "]: " << event.message << std::endl;
std::cout << "(" << std::put_time(std::localtime(&t), "%Y-%m-%d %H:%M:%S") << ") [" << dpp::utility::loglevel(event.severity) << "]: <" << bot.config.id << "> " << event.message << std::endl;
std::cout << "(" << std::put_time(std::localtime(&t), "%Y-%m-%d %H:%M:%S") << ") [" << bot.config.id << "/" << dpp::utility::loglevel(event.severity) << "]: " << event.message << std::endl;
});
bot.config.reregister_commands = argc == 2;
bot.add_property("main_all_instances", &instances, instances_mutex);