mirror of
https://github.com/overte-org/overte.git
synced 2025-08-08 22:16:58 +02:00
fix a couple of missing-parent bugs
This commit is contained in:
parent
b55596689f
commit
45d19167c9
3 changed files with 6 additions and 5 deletions
|
@ -15,10 +15,9 @@ SpatiallyNestableWeakPointer AssignmentParentFinder::find(QUuid parentID, bool&
|
||||||
SpatiallyNestableWeakPointer parent;
|
SpatiallyNestableWeakPointer parent;
|
||||||
// search entities
|
// search entities
|
||||||
parent = _tree->findEntityByEntityItemID(parentID);
|
parent = _tree->findEntityByEntityItemID(parentID);
|
||||||
if (parent.lock()) {
|
if (parent.expired()) {
|
||||||
success = true;
|
|
||||||
} else {
|
|
||||||
success = false;
|
success = false;
|
||||||
}
|
}
|
||||||
|
success = true;
|
||||||
return parent;
|
return parent;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1254,6 +1254,8 @@ const AABox& EntityItem::getAABox(bool& success) const {
|
||||||
_cachedAABox = AABox(rotatedExtentsRelativeToRegistrationPoint);
|
_cachedAABox = AABox(rotatedExtentsRelativeToRegistrationPoint);
|
||||||
_recalcAABox = false;
|
_recalcAABox = false;
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
success = true;
|
||||||
}
|
}
|
||||||
return _cachedAABox;
|
return _cachedAABox;
|
||||||
}
|
}
|
||||||
|
|
|
@ -240,8 +240,8 @@ bool EntityTree::updateEntityWithElement(EntityItemPointer entity, const EntityI
|
||||||
bool success;
|
bool success;
|
||||||
AACube queryCube = childEntity->getQueryAACube(success);
|
AACube queryCube = childEntity->getQueryAACube(success);
|
||||||
if (!success) {
|
if (!success) {
|
||||||
qCDebug(entities) << "Can't update child -- failed to get query-cube for" << childEntity->getID();
|
_missingParent.append(childEntity);
|
||||||
// XXX put on a list for later checking?
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
UpdateEntityOperator theChildOperator(getThisPointer(), containingElement, childEntity, queryCube);
|
UpdateEntityOperator theChildOperator(getThisPointer(), containingElement, childEntity, queryCube);
|
||||||
|
|
Loading…
Reference in a new issue