feat(log): printStatus amb claudàtor acolorit al davant

This commit is contained in:
JailDesigner committed 2026-05-14 19:02:43 +02:00
1 parent 7a1261202c
commit b81a453b32
7 files changed
+112 -19

No files matched your search

+5
View File
@@ -130,6 +130,11 @@ namespace Log {
SDL_LogMessage(categoryFor(tag), toSDL(lvl), "%s", BODY.c_str());
}
void logPrefixed(Level lvl, std::string_view tag, std::string_view prefix, std::string_view msg) {
const std::string BODY = std::format("{} {}: {}", prefix, tag, msg);
SDL_LogMessage(categoryFor(tag), toSDL(lvl), "%s", BODY.c_str());
}
void raw(Level lvl, std::string_view msg) {
const std::string TEXT{msg};
SDL_LogMessage(SDL_LOG_CATEGORY_APPLICATION, toSDL(lvl), "%s", TEXT.c_str());