Add backwards compatibility with servers using previous setup method

* MasterServer will nolonger require cdclient.fdb

* Added support for packed/unpacked clients not requiring .fdb file if .sqlite exsits
This commit is contained in:
Demetri Van Sickle 2022-11-21 14:19:37 -08:00 committed by GitHub
parent 416021c208
commit 9d62a8cd0b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -26,11 +26,11 @@ AssetManager::AssetManager(const std::string& path) {
m_RootPath = (m_Path / ".." / "..");
m_ResPath = m_Path;
} else if (std::filesystem::exists(m_Path / "res" / "cdclient.fdb") && !std::filesystem::exists(m_Path / "res" / "pack")) {
} else if ((std::filesystem::exists(m_Path / "res" / "cdclient.fdb") || std::filesystem::exists(m_Path / "res" / "CDServer.sqlite")) && !std::filesystem::exists(m_Path / "res" / "pack")) {
m_AssetBundleType = eAssetBundleType::Unpacked;
m_ResPath = (m_Path / "res");
} else if (std::filesystem::exists(m_Path / "cdclient.fdb") && !std::filesystem::exists(m_Path / "pack")) {
} else if ((std::filesystem::exists(m_Path / "cdclient.fdb") || std::filesystem::exists(m_Path / "CDServer.sqlite")) && !std::filesystem::exists(m_Path / "pack")) {
m_AssetBundleType = eAssetBundleType::Unpacked;
m_ResPath = m_Path;