2
0
mirror of https://github.com/Laupetin/OpenAssetTools.git synced 2025-11-30 16:27:47 +00:00

chore: update all logging to use centralized logging component

This commit is contained in:
Jan Laupetin
2025-09-10 19:52:42 +02:00
parent 1bf4033f41
commit 02f20f09b6
161 changed files with 824 additions and 664 deletions

View File

@@ -3,6 +3,7 @@
#include "Game/IW5/IW5.h"
#include "Game/IW5/Leaderboard/JsonLeaderboardDef.h"
#include "Leaderboard/LeaderboardCommon.h"
#include "Utils/Logging/Log.h"
#include <cstring>
#include <format>
@@ -36,7 +37,7 @@ namespace
if (type != "leaderboard" || version != 1u)
{
std::cerr << std::format("Tried to load leaderboard \"{}\" but did not find expected type leaderboard of version 1\n", leaderboardDef.name);
con::error("Tried to load leaderboard \"{}\" but did not find expected type leaderboard of version 1", leaderboardDef.name);
return false;
}
@@ -45,7 +46,7 @@ namespace
}
catch (const json::exception& e)
{
std::cerr << std::format("Failed to parse json of leaderboard: {}\n", e.what());
con::error("Failed to parse json of leaderboard: {}", e.what());
}
return false;
@@ -142,7 +143,7 @@ namespace
const JsonLoader loader(*file.m_stream, m_memory);
if (!loader.Load(*leaderboardDef))
{
std::cerr << std::format("Failed to load leaderboard \"{}\"\n", assetName);
con::error("Failed to load leaderboard \"{}\"", assetName);
return AssetCreationResult::Failure();
}