Load folder texture packs

This commit is contained in:
Soggy_Pancake 2026-03-21 22:22:09 -07:00
parent 66343a5ba1
commit caaca129ad

View file

@ -249,7 +249,19 @@ void TexturePackRepository::updateList()
}
}
else if (file->isDirectory()) {
app.DebugPrintf("Found texture pack folder! %s", name);
app.DebugPrintf("Found folder texture pack! %s", name.c_str());
DWORD id = 0;
for (int i = 0; i < INT_MAX; i++)
if (cacheById.find(i) == cacheById.end()) {
id = i;
break;
}
FolderTexturePack* tp = new FolderTexturePack(id, file->getName(), file, DEFAULT_TEXTURE_PACK);
if (tp->hasData()) {
texturePacks->push_back(tp);
cacheById[id] = tp;
}
}
}
catch (exception e) {