mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-01-19 20:24:49 +00:00
getAssetIdByFilename loaded state fix
getAssetIdByFilename should set the <type>Asset->mLoadedState = AssetErrCode::BadFileReference; so we know we're using a fallback
This commit is contained in:
parent
96fd520eb7
commit
0136af477f
|
|
@ -219,6 +219,11 @@ StringTableEntry ImageAsset::getAssetIdByFilename(StringTableEntry fileName)
|
|||
//acquire and bind the asset, and return it out
|
||||
imageAssetId = query.mAssetList[0];
|
||||
}
|
||||
else
|
||||
{
|
||||
AssetPtr<ImageAsset> imageAsset = imageAssetId;
|
||||
imageAsset->mLoadedState = AssetErrCode::BadFileReference;
|
||||
}
|
||||
|
||||
return imageAssetId;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -473,6 +473,11 @@ StringTableEntry ShapeAsset::getAssetIdByFilename(StringTableEntry fileName)
|
|||
//acquire and bind the asset, and return it out
|
||||
shapeAssetId = query.mAssetList[0];
|
||||
}
|
||||
else
|
||||
{
|
||||
AssetPtr<ShapeAsset> shapeAsset = shapeAssetId;
|
||||
shapeAsset->mLoadedState = AssetErrCode::BadFileReference;
|
||||
}
|
||||
|
||||
return shapeAssetId;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue