mirror of
https://github.com/overte-org/overte.git
synced 2025-08-10 07:23:00 +02:00
make json importer understand AVATAR_SELF_ID
This commit is contained in:
parent
ca11d19b3e
commit
e7fa8131ea
1 changed files with 5 additions and 2 deletions
|
@ -1935,11 +1935,14 @@ bool EntityTree::readFromMap(QVariantMap& map) {
|
||||||
entityItemID = EntityItemID(QUuid::createUuid());
|
entityItemID = EntityItemID(QUuid::createUuid());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
auto nodeList = DependencyManager::get<NodeList>();
|
||||||
|
const QUuid myNodeID = nodeList->getSessionUUID();
|
||||||
if (properties.getClientOnly()) {
|
if (properties.getClientOnly()) {
|
||||||
auto nodeList = DependencyManager::get<NodeList>();
|
|
||||||
const QUuid myNodeID = nodeList->getSessionUUID();
|
|
||||||
properties.setOwningAvatarID(myNodeID);
|
properties.setOwningAvatarID(myNodeID);
|
||||||
}
|
}
|
||||||
|
if (properties.getParentID() == AVATAR_SELF_ID) {
|
||||||
|
properties.setParentID(myNodeID);
|
||||||
|
}
|
||||||
|
|
||||||
EntityItemPointer entity = addEntity(entityItemID, properties);
|
EntityItemPointer entity = addEntity(entityItemID, properties);
|
||||||
if (!entity) {
|
if (!entity) {
|
||||||
|
|
Loading…
Reference in a new issue