Fixing the case when the bound changes without the rest of the properties

This commit is contained in:
samcake 2017-05-25 13:01:54 -07:00
parent 6dbbd6c8d0
commit cba913c068

View file

@ -145,10 +145,7 @@ void RenderableZoneEntityItem::somethingChangedNotification() {
DependencyManager::get<EntityTreeRenderer>()->updateZone(_id);
// If graphics elements are changed, we need to update the render items
if (_keyLightPropertiesChanged || _backgroundPropertiesChanged || _stagePropertiesChanged || _skyboxPropertiesChanged) {
notifyChangedRenderItem();
}
notifyChangedRenderItem();
// Poopagate back to parent
ZoneEntityItem::somethingChangedNotification();
@ -290,17 +287,7 @@ void RenderableZoneEntityItem::removeFromScene(EntityItemPointer self, const ren
}
void RenderableZoneEntityItem::notifyBoundChanged() {
if (!render::Item::isValidID(_myMetaItem)) {
return;
}
render::Transaction transaction;
render::ScenePointer scene = AbstractViewStateInterface::instance()->getMain3DScene();
if (scene) {
transaction.updateItem<RenderableZoneEntityItemMeta>(_myMetaItem, [](RenderableZoneEntityItemMeta& data) {});
scene->enqueueTransaction(transaction);
} else {
qCWarning(entitiesrenderer) << "RenderableZoneEntityItem::notifyBoundChanged(), Unexpected null scene, possibly during application shutdown";
}
notifyChangedRenderItem();
}
void RenderableZoneEntityItem::updateKeySunFromEntity(RenderableZoneEntityItemMeta& keyZonePayload) {