Navigation
API > API/Plugins > API/Plugins/CommonUI > API/Plugins/CommonUI/UCommonLoadGuard > API/Plugins/CommonUI/UCommonLoadGuard/GuardAndLoadAsset
References
| Module | CommonUI |
| Header | /Engine/Plugins/Runtime/CommonUI/Source/CommonUI/Public/CommonLoadGuard.h |
| Include | #include "CommonLoadGuard.h" |
template<typename ObjectType>
void GuardAndLoadAsset
&40;
const TSoftObjectPtr< ObjectType > & InLazyAsset,
TFunction< void(ObjectType &42;)> OnAssetLoaded
&41;
Remarks
Displays the loading spinner until the asset is loaded Will pass a casted pointer to the given asset in the lambda callback - could be nullptr if you provide an incompatible type or invalid asset.