Recast: properly free data on shutdown

Editor::m_navMesh is always deleted in the base class, removed extraneous deletion from the tilemesh editor.
This commit is contained in:
Kawe Mazidjatari 2024-10-13 21:39:12 +02:00
parent 1491f6eaac
commit 136fc4ecf5
2 changed files with 4 additions and 4 deletions

View File

@ -764,9 +764,11 @@ Editor_TempObstacles::Editor_TempObstacles()
Editor_TempObstacles::~Editor_TempObstacles()
{
dtFreeNavMesh(m_navMesh);
m_navMesh = 0;
dtFreeTileCache(m_tileCache);
delete m_talloc;
delete m_tcomp;
delete m_tmproc;
}
void Editor_TempObstacles::handleSettings()

View File

@ -463,8 +463,6 @@ Editor_TileMesh::Editor_TileMesh() :
Editor_TileMesh::~Editor_TileMesh()
{
cleanup();
dtFreeNavMesh(m_navMesh);
m_navMesh = 0;
}
void Editor_TileMesh::handleSettings()