|
|
@ -15,10 +15,11 @@ namespace DetourNavigator
|
|
|
|
std::unique_ptr<NavMeshDb> db;
|
|
|
|
std::unique_ptr<NavMeshDb> db;
|
|
|
|
if (settings.mEnableNavMeshDiskCache)
|
|
|
|
if (settings.mEnableNavMeshDiskCache)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
const std::string path = Files::pathToUnicodeString(userDataPath / "navmesh.db");
|
|
|
|
|
|
|
|
Log(Debug::Info) << "Using " << path << " to store navigation mesh cache";
|
|
|
|
try
|
|
|
|
try
|
|
|
|
{
|
|
|
|
{
|
|
|
|
db = std::make_unique<NavMeshDb>(
|
|
|
|
db = std::make_unique<NavMeshDb>(path, settings.mMaxDbFileSize);
|
|
|
|
Files::pathToUnicodeString(userDataPath / "navmesh.db"), settings.mMaxDbFileSize);
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (const std::exception& e)
|
|
|
|
catch (const std::exception& e)
|
|
|
|
{
|
|
|
|
{
|
|
|
|