1
0
Fork 0

TerraSync: wait on Models as well

Avoid starting tile load until Models is done sync-ing, since this
causes may missing file errors.
This commit is contained in:
James Turner 2020-11-03 17:02:33 +00:00 committed by James Turner
parent c63594acec
commit ce65b84c20

View file

@ -625,6 +625,12 @@ bool FGTileMgr::isTileDirSyncing(const std::string& tileFileName) const
return false;
}
// if Models is syncing, also wait for it, since otherwise
// we get load errors
if (terraSync->isDataDirPending("Models")) {
return true;
}
std::string nameWithoutExtension = tileFileName.substr(0, tileFileName.size() - 4);
long int bucketIndex = simgear::strutils::to_int(nameWithoutExtension);
SGBucket bucket(bucketIndex);