1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-06 00:55:50 +00:00

Add TODOs

This commit is contained in:
elsid 2018-11-03 16:13:46 +03:00
parent 2ba026e2b2
commit b77684a135
No known key found for this signature in database
GPG Key ID: B845CB9FEE18AB40

View File

@ -63,6 +63,7 @@ namespace DetourNavigator
if (tileValues == agentValues->second.end())
return Value();
// TODO: use different function to make key to avoid unnecessary std::string allocation
const auto tile = tileValues->second.find(makeNavMeshKey(recastMesh, offMeshConnections));
if (tile == tileValues->second.end())
return Value();
@ -96,6 +97,7 @@ namespace DetourNavigator
removeLeastRecentlyUsed();
const auto iterator = mFreeItems.emplace(mFreeItems.end(), agentHalfExtents, changedTile, navMeshKey);
// TODO: use std::string_view or some alternative to avoid navMeshKey copy into both mFreeItems and mValues
const auto emplaced = mValues[agentHalfExtents][changedTile].emplace(navMeshKey, iterator);
if (!emplaced.second)