set more physics flags dirty when an entity parent is found

This commit is contained in:
Seth Alves 2017-05-19 10:40:24 -07:00
parent 77ce8a19cf
commit 7220fe0ad8

View file

@ -1258,7 +1258,9 @@ void EntityTree::fixupMissingParents() {
entity->forEachDescendant([&](SpatiallyNestablePointer object) {
if (object->getNestableType() == NestableType::Entity) {
EntityItemPointer descendantEntity = std::static_pointer_cast<EntityItem>(object);
descendantEntity->markDirtyFlags(Simulation::DIRTY_POSITION);
descendantEntity->markDirtyFlags(Simulation::DIRTY_MOTION_TYPE |
Simulation::DIRTY_COLLISION_GROUP |
Simulation::DIRTY_POSITION);
entityChanged(descendantEntity);
}
});