Is there a way to list the contents of a Level without loading the level? I’m looping through maps and my script slows down as it goes along. I’d like to avoid loading maps, if there is a way to get a list of the map contents without loading it. Any suggestions?
I was running into this the other day too. Specifically I want the contained/placed actors, which do not seem to create reference connections to the level asset(s) in my case.
Did you ever find a solution, other than loading each map to sort through its contents?
I never did, but my slowing down problem went away - I think I was able to use unreal-Cmd.exe instead of unreal.exe to speed it up. This is what I’m doing, basically…
from unreal import AssetRegistryHelpers as AssetRegHelpers from unreal import EditorLevelLibrary as ELL asset_reg_h = AssetRegHelpers.get_asset_registry() all_assets = asset_reg_h.get_assets_by_path('/Game/Maps', True) for this_asset in all_assets: full_name = this_asset.get_full_name() this_type, this_path = full_name.split(" ") if this_type == "World": ELL.load_level(this_path) level_contents = ELL.get_all_level_actors() for item in level_contents: