Fix dtMeshTile structure

Removed old member that should had been removed earlier. All members align now.
This commit is contained in:
Kawe Mazidjatari 2022-07-22 12:28:39 +02:00
parent 178aeeb3fd
commit ff0ae1c13b
2 changed files with 2 additions and 2 deletions

View File

@ -317,7 +317,6 @@ struct dtMeshTile
/// The tile bounding volume nodes. [Size: dtMeshHeader::bvNodeCount]
/// (Will be null if bounding volumes are disabled.)
dtBVNode* bvTree;
void* meshLink; ///< Seems shifted with 8 bytes from here (the rest seems to line up with r2) see field assignments in 'r5apex.exe 0x140F44A00'
dtOffMeshConnection* offMeshCons; ///< The tile off-mesh connections. [Size: dtMeshHeader::offMeshConCount]
dtOffMeshConnection* offMeshConsEnd; ///< The tile off-mesh connections array end pointer.
@ -327,6 +326,7 @@ struct dtMeshTile
int dataSize; ///< Size of the tile data.
int flags; ///< Tile flags. (See: #dtTileFlags)
dtMeshTile* next; ///< The next free tile, or the next tile in the spatial grid.
void* unused;
private:
dtMeshTile(const dtMeshTile&);
dtMeshTile& operator=(const dtMeshTile&);

View File

@ -1018,9 +1018,9 @@ dtStatus dtNavMesh::addTile(unsigned char* data, int dataSize, int flags,
// Init tile.
tile->header = header;
tile->data = data;
tile->meshLink = &data[offMeshLinksSize]; // tile + 58h = &v33[v17];
tile->dataSize = dataSize;
tile->flags = flags;
tile->unused = nullptr;
connectIntLinks(tile);