1
0
mirror of https://github.com/Mauler125/r5sdk.git synced 2025-02-09 19:15:03 +01:00

Fix naveditor log when invoked using commandline

Log must be reset pre-build, and dump post-build in order for logging to work.
This commit is contained in:
Kawe Mazidjatari 2023-01-25 22:14:46 +01:00
parent 532ada48e0
commit 306211a1b4
2 changed files with 6 additions and 2 deletions

@ -12,7 +12,6 @@ BuildContext::BuildContext() :
m_textPoolSize(0)
{
memset(m_messages, 0, sizeof(char*) * MAX_MESSAGES);
resetTimers();
}
@ -21,6 +20,7 @@ void BuildContext::doResetLog()
{
m_messageCount = 0;
m_textPoolSize = 0;
memset(m_textPool, '\0', sizeof(m_textPool));
}
void BuildContext::doLog(const rcLogCategory category, const char* msg, const int len)

@ -415,7 +415,7 @@ void Editor_TileMesh::handleDebugMode()
if (unavail)
{
imguiValue("Tick 'Keep Itermediate Results'");
imguiValue("Tick 'Keep Intermediate Results'");
imguiValue("rebuild some tiles to see");
imguiValue("more debug mode options.");
}
@ -792,8 +792,12 @@ void Editor_TileMesh::buildAllHulls()
m_navmeshName = h.name;
m_tileSize = h.tile_size;
m_ctx->resetLog();
handleSettings();
handleBuild();
m_ctx->dumpLog("Build log %s:", h.name);
Editor::saveAll(m_modelName.c_str(), m_navMesh);
}
}