Asset Registry can't find files

I’m trying to find assets of a type and decided the asset registry would be a better way than to have a massive array of “loaded assets” The trick is that I’m not actually getting any results back from the Asset Registry. I tried looking for something basic and got the

   //Load the module
    FAssetRegistryModule& AssetRegistryModule = FModuleManager::LoadModuleChecked<FAssetRegistryModule>("AssetRegistry");
    //Setup output array
    TArray<FAssetData> AssetData;
    //Get the asset Registry and find assets of type RWallTile, store in AssetData, include subclasses
    AssetRegistryModule.Get().GetAssetsByClass(ARWallTile::StaticClass()->GetFName(), AssetData,true);
    //Output the result for testing
    UE_LOG(LogTemp, Warning, TEXT("Found %d Assets of type %s"),AssetData.Num(), *ARWallTile::StaticClass()->GetFName().ToString());

This results in the following being output

LogTemp: Warning: Found 0 Assets of type RWallTile

Are you sure the call to ARWallTile::StaticClass()->GetFName() is giving you what you want? I use Asset Registry heavily in my game and I usually just hard-code the names of the classes I want to find. I’ve noticed that Asset Registry wants the class name to be the name of the class without the “A”, “U”, “S”, “F”, etc prefix.

So since you’re looking for all assets of type ARWallTile, pass in the string "RWallTile" into the asset registry call. That’s how I do it in my game and it works fine.

Though, I do have issues with asset registry and standalone builds of my game. You may want to make sure the assets you want to load are actually being cooked and packaged when you ship your build, otherwise you end up with

Thanks for the reply. I’ve actually abandoned this approach a few months ago. Instead we went with a slightly more restrictive approach of having a specific naming convention. Then we parse the name and can identify an asset that way.