mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-29 18:32:36 +00:00
Don't try to get the center of a null bounding box
This commit is contained in:
parent
80d271aeb1
commit
b4b095ca72
@ -355,7 +355,8 @@ void Animation::addExtraLight(Ogre::SceneManager *sceneMgr, NifOgre::ObjectList
|
||||
bounds.merge(ent->getBoundingBox());
|
||||
}
|
||||
|
||||
Ogre::SceneNode *node = mInsert->createChildSceneNode(bounds.getCenter());
|
||||
Ogre::SceneNode *node = bounds.isFinite() ? mInsert->createChildSceneNode(bounds.getCenter())
|
||||
: mInsert->createChildSceneNode();
|
||||
node->attachObject(olight);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user