How to add information to and read from level files?

Say that you want your menu to add all the maps in your maps folder to a list and display information about the maps that has been saved into the file, like name, description, an icon, booleans to mark it as experimental, etc… How would you go about making that possible? Can you read information from a map file if you add variables to your custom LevelScriptActor, or is that information not saved in the map files?

LevelScriptActor would work too as it indeed saved on level… but there something way better, AWorldSettings:

This actor same as level blueprint is saved with the level, it reponcible to store world settings that you can access in “Settings” toolbar button (you probably already accessed it atleast once ;p). What you see there is practically property editor for AWorldSettings actor on the level, so as you may guess you can create your own AWorldSettings same as you can do with blueprint level and set it in project settings, all you need to is make UPROPERTY with EditAnywhere or EditInstanceOnly and ofcorse Category and they will apper there like in any actor. And same as in properties of actors on the level you can reference other actors on that level in there, which is very useful

Then you can access that actor from () :

And ULevel even without opening the world straight from level asset:

Ah, thank you! That’s awesome!