I am using ServerTravel for switching maps in a single player game. ServerTravel returns true even if the map does not exist. The map name will be given by the user and I have to check if it exists first. How can I do that?
Thanks for your reply. Is there an equivalent method C++?
Of course, all blueprint methods use underlying C++ functions under the hood.
#include "AssetRegistry/IAssetRegistry.h"
if (auto AssetRegistry = IAssetRegistry::Get())
{
TArray<FAssetData> MapList;
AssetRegistry->GetAssetsByClass(FTopLevelAssetPath(UWorld::StaticClass()->GetPathName()), MapList);
//...
}
