|
|
@ -112,12 +112,12 @@ bool Objects::removeObject (const MWWorld::Ptr& ptr)
|
|
|
|
PtrAnimationMap::iterator iter = mObjects.find(ptr);
|
|
|
|
PtrAnimationMap::iterator iter = mObjects.find(ptr);
|
|
|
|
if(iter != mObjects.end())
|
|
|
|
if(iter != mObjects.end())
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
if (mUnrefQueue.get())
|
|
|
|
|
|
|
|
mUnrefQueue->push(iter->second->getObjectRoot());
|
|
|
|
|
|
|
|
|
|
|
|
delete iter->second;
|
|
|
|
delete iter->second;
|
|
|
|
mObjects.erase(iter);
|
|
|
|
mObjects.erase(iter);
|
|
|
|
|
|
|
|
|
|
|
|
if (mUnrefQueue.get())
|
|
|
|
|
|
|
|
mUnrefQueue->push(ptr.getRefData().getBaseNode());
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ptr.getRefData().getBaseNode()->getParent(0)->removeChild(ptr.getRefData().getBaseNode());
|
|
|
|
ptr.getRefData().getBaseNode()->getParent(0)->removeChild(ptr.getRefData().getBaseNode());
|
|
|
|
|
|
|
|
|
|
|
|
ptr.getRefData().setBaseNode(NULL);
|
|
|
|
ptr.getRefData().setBaseNode(NULL);
|
|
|
|