- fixed 3D floor initialization for actor spawning.

Since actors are being spawned before the renderer gets set up this needs to fully initialize the list before spawning the actors, then take it down again for creating the vertex buffer and then recreate it.
This commit is contained in:
Christoph Oelckers 2018-12-27 08:28:09 +01:00
commit b31f284e28
3 changed files with 44 additions and 4 deletions

View file

@ -3770,6 +3770,9 @@ void P_SetupLevel(const char *lumpname, int position, bool newGame)
node.len = (float)g_sqrt(fdx * fdx + fdy * fdy);
}
// CreateVBO must be run on the plain 3D floor data.
P_ClearDynamic3DFloorData();
// This must be done BEFORE the PolyObj Spawn!!!
InitRenderInfo(); // create hardware independent renderer resources for the level.
screen->mVertexData->CreateVBO();