mirror of
https://github.com/JulianGro/overte.git
synced 2025-08-16 12:12:14 +02:00
TEMPORARY fix for older content not containing these fields (keylight, skybox, ambient light).
This commit is contained in:
parent
5b7ef9a3d3
commit
e8770ec204
1 changed files with 11 additions and 0 deletions
|
@ -2281,6 +2281,17 @@ bool EntityTree::readFromMap(QVariantMap& map) {
|
|||
properties.setOwningAvatarID(myNodeID);
|
||||
}
|
||||
|
||||
// TEMPORARY fix for older content not containing these fields
|
||||
if (!entityMap.contains("keyLightMode")) {
|
||||
properties.setKeyLightMode(COMPONENT_MODE_ENABLED);
|
||||
}
|
||||
if (!entityMap.contains("skyboxMode")) {
|
||||
properties.setSkyboxMode(COMPONENT_MODE_ENABLED);
|
||||
}
|
||||
if (!entityMap.contains("ambientLightMode")) {
|
||||
properties.setAmbientLightMode(COMPONENT_MODE_ENABLED);
|
||||
}
|
||||
|
||||
EntityItemPointer entity = addEntity(entityItemID, properties);
|
||||
if (!entity) {
|
||||
qCDebug(entities) << "adding Entity failed:" << entityItemID << properties.getType();
|
||||
|
|
Loading…
Reference in a new issue