mirror of
https://github.com/overte-org/overte.git
synced 2025-08-08 13:38:02 +02:00
Move asset resource directory out of /resources
This commit is contained in:
parent
1b856ee79d
commit
c417bc0fb3
1 changed files with 4 additions and 3 deletions
|
@ -50,13 +50,14 @@ void AssetServer::run() {
|
||||||
auto nodeList = DependencyManager::get<NodeList>();
|
auto nodeList = DependencyManager::get<NodeList>();
|
||||||
nodeList->addNodeTypeToInterestSet(NodeType::Agent);
|
nodeList->addNodeTypeToInterestSet(NodeType::Agent);
|
||||||
|
|
||||||
const QString RESOURCES_PATH = "resources/assets";
|
const QString OLD_RESOURCES_PATH = "resources/assets";
|
||||||
|
const QString RESOURCES_PATH = "assets";
|
||||||
|
|
||||||
_resourcesDirectory = QDir(ServerPathUtils::getDataDirectory()).filePath(RESOURCES_PATH);
|
_resourcesDirectory = QDir(ServerPathUtils::getDataFilePath(RESOURCES_PATH));
|
||||||
if (!_resourcesDirectory.exists()) {
|
if (!_resourcesDirectory.exists()) {
|
||||||
qDebug() << "Asset resources directory not found, searching for existing asset resources";
|
qDebug() << "Asset resources directory not found, searching for existing asset resources";
|
||||||
QString oldDataDirectory = QCoreApplication::applicationDirPath();
|
QString oldDataDirectory = QCoreApplication::applicationDirPath();
|
||||||
auto oldResourcesDirectory = QDir(oldDataDirectory).filePath(RESOURCES_PATH);
|
auto oldResourcesDirectory = QDir(oldDataDirectory).filePath(OLD_RESOURCES_PATH);
|
||||||
|
|
||||||
if (QDir(oldResourcesDirectory).exists()) {
|
if (QDir(oldResourcesDirectory).exists()) {
|
||||||
qDebug() << "Existing assets found in " << oldResourcesDirectory << ", copying to " << _resourcesDirectory;
|
qDebug() << "Existing assets found in " << oldResourcesDirectory << ", copying to " << _resourcesDirectory;
|
||||||
|
|
Loading…
Reference in a new issue