I don’t know if it’s because i’m running a development build, but i just packaged my game and the async level loading is so slow. When i run it on the editor it’s almost instantaneous, although it does not seem to use async, since my game thread gets bogged down. Is there any way to speed up the loading of my packaged build? Thank you.
I’ve tried with a distribution build and it has the same problem. This also happens when you do play in standalone from the editor. I’ve tried using it without async and it’s a terrible experience, so where can i go from here? A level that in PIE takes 0.2ms to load takes 10 seconds playing standalone. Does anyone have this issue?
Because Editor caches everything and it won’t discard them.
As a popular work around, you can manually preload necessary assets before loading a level using StreambableManager (or recently introduced AssetManager.)
It should be noted that you need to hold the references to prevent the loaded assets from getting GCed until the level load finishes, then you can release the references.
Can i hold a reference to all of the levels at the same time? I’m asking this because the game i’m making is in a house and most of divisions (because they have a lot of stuff in them) are different levels (i use a door to trigger the loading) so that means i can walk out and go back again a lot of times and i dont want to wait 20 seconds for the door to open.
Yes, you can load all the assets and hold them in memory until the game ends.
However, the plausibility highly depends on the size of the assets, and the minimum system requirements of your game.
If you are using UE4.17 or newer, you might want to check AssetManager.
[Asset Management in Unreal Engine | Unreal Engine 5.1 Documentation]
I’ll take a look at it, thanks !