BGE: fix a bug causing frequent crash on scene restart with navmesh.

This commit is contained in:
Benoit Bolsee 2014-08-10 00:40:15 +02:00
parent 3a53ed8d1b
commit 8aa203abc1
Notes: blender-bot 2023-02-14 10:14:11 +01:00
Referenced by issue #41385, Crash on sculpt stroke
1 changed files with 1 additions and 1 deletions

View File

@ -111,7 +111,7 @@ bool KX_NavMeshObject::BuildVertIndArrays(float *&vertices, int& nverts,
float *&dvertices, int &ndvertsuniq, unsigned short *&dtris,
int& ndtris, int &vertsPerPoly)
{
DerivedMesh* dm = mesh_create_derived_no_virtual(KX_GetActiveScene()->GetBlenderScene(), GetBlenderObject(),
DerivedMesh* dm = mesh_create_derived_no_virtual(GetScene()->GetBlenderScene(), GetBlenderObject(),
NULL, CD_MASK_MESH);
CustomData *pdata = dm->getPolyDataLayout(dm);
int* recastData = (int*) CustomData_get_layer(pdata, CD_RECAST);