mirror of
https://github.com/AxioDL/metaforce.git
synced 2025-12-08 13:44:56 +00:00
Proper handling for persistently resident resources
This commit is contained in:
@@ -1188,15 +1188,7 @@ void CModel::Draw(const CModelFlags& flags) const {
|
||||
|
||||
bool CModel::IsLoaded(int shaderIdx) const {
|
||||
const_cast<CBooModel&>(*x28_modelInst).VerifyCurrentShader(shaderIdx);
|
||||
std::vector<TCachedToken<CTexture>>& texs = x28_modelInst->x1c_textures;
|
||||
bool loaded = true;
|
||||
for (TCachedToken<CTexture>& tex : texs) {
|
||||
if (!tex.IsLoaded()) {
|
||||
loaded = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
return loaded;
|
||||
return const_cast<CBooModel&>(*x28_modelInst).TryLockTextures();
|
||||
}
|
||||
|
||||
size_t CModel::GetPoolVertexOffset(size_t idx) const { return m_hmdlMeta.vertStride * idx; }
|
||||
|
||||
Reference in New Issue
Block a user