1
0
Fork 0
mirror of https://github.com/AquariaOSE/Aquaria.git synced 2024-11-25 09:44:02 +00:00

Fix possible crash when loading applying a skeletal twice in one frame.

Possibly a regression from 300f326777.
This commit is contained in:
fgenesis 2016-05-12 00:25:00 +02:00
parent d6dc3a8a09
commit 65179870a9
2 changed files with 4 additions and 1 deletions

View file

@ -967,6 +967,10 @@ void RenderObject::enqueueChildDeletion(RenderObject *r)
{
if (r->parent == this)
{
// Don't garbage a child more than once
for (size_t i = 0; i < childGarbage.size(); ++i)
if(childGarbage[i] == r)
return;
childGarbage.push_back(r);
}
}

View file

@ -1105,7 +1105,6 @@ void SkeletalSprite::deleteBones()
{
(*it)->safeKill();
}
bones.clear();
}
Animation *SkeletalSprite::getAnimation(const std::string& anim)