From 926be73c0a09b514ccaa7a6399206425875ae11a Mon Sep 17 00:00:00 2001 From: Seth Alves Date: Tue, 6 Mar 2018 15:50:03 -0800 Subject: [PATCH] make this work again --- interface/src/Application.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index 1a5ceec34c..cd9e3992ac 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -3140,6 +3140,14 @@ void Application::loadServerlessDomain(QUrl domainURL) { return; } + QUuid serverlessSessionID = QUuid::createUuid(); + getMyAvatar()->setSessionUUID(serverlessSessionID); + nodeList->setSessionUUID(serverlessSessionID); + + // there is no domain-server to tell us our permissions, so enable all + permissions.setAll(true); + nodeList->setPermissions(permissions); + // we can't import directly into the main tree because we would need to lock it, and // Octree::readFromURL calls loop.exec which can run code which will also attempt to lock the tree. EntityTreePointer tmpTree(new EntityTree()); @@ -3149,14 +3157,6 @@ void Application::loadServerlessDomain(QUrl domainURL) { tmpTree->setMyAvatar(myAvatar); bool success = tmpTree->readFromURL(domainURL.toString()); if (success) { - QUuid serverlessSessionID = QUuid::createUuid(); - getMyAvatar()->setSessionUUID(serverlessSessionID); - nodeList->setSessionUUID(serverlessSessionID); - - // there is no domain-server to tell us our permissions, so enable all - permissions.setAll(true); - nodeList->setPermissions(permissions); - tmpTree->reaverageOctreeElements(); tmpTree->sendEntities(&_entityEditSender, getEntities()->getTree(), 0, 0, 0); }