1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-27 12:35:46 +00:00

fixed cell change crash

This commit is contained in:
Marc Zinnschlag 2011-05-30 14:21:55 +02:00
parent c7fb27e801
commit bed45a936e

View File

@ -402,7 +402,11 @@ void ExteriorCellRender::destroy()
mBase = NULL; mBase = NULL;
std::cout << "destroy"; std::cout << "destroy";
if (sg)
{
Ogre::Root::getSingleton().getSceneManagerIterator().getNext()->destroyStaticGeometry(sg); Ogre::Root::getSingleton().getSceneManagerIterator().getNext()->destroyStaticGeometry(sg);
sg = 0;
}
} }
// Switch through lighting modes. // Switch through lighting modes.