Don't try to initialize an asset if the initialization has failed (closes #1830)

This commit is contained in:
Alexander Bock
2022-02-20 19:30:23 +01:00
parent a6f048e342
commit abaaf437b6

View File

@@ -182,8 +182,13 @@ void AssetManager::update() {
continue;
}
_rootAssets.push_back(a);
a->load(nullptr);
if (a->isFailed()) {
// The loading might fail because of any number of reasons, most likely of
// them some Lua syntax error
continue;
}
_rootAssets.push_back(a);
a->startSynchronizations();
_toBeInitialized.push_back(a);