I am trying to create a visualisation of a location over multiple time periods.
When the player travels to a new time period the elements that are not present should sink into the floor and the new elements should rise out of the floor.
I have solved most of the problems but I have hit some issues.
Each separate element has its own level and a level sequence to animate the level. The level sequence sets the level visibility and moves the element out of the ground. The animation is then played in reverse to despawn the element.
This works but from what I understand all the levels will always be loaded into memory which isn’t scalable. I would like to unload the levels when they are no longer needed. This is the major issue I have been hitting.
I can call the load and unload streaming level nodes which does work however once the level is unloaded and loaded again the animation seems to break. The sequence can set the visibility of the level but the movement never works again.
Hopefully there is something simple I am missing.
Now for some more details
Here is an example of the sequence.
The visibility of the level is set to visible for the whole sequence and the z location is animated. I am animating the location of a cube and have all the static meshes for the element as children of that cube.
The animation object is in the main level so that it is always loaded and the main level blueprint loads and unloads the levels and plays the animations. Here is that blueprint. It is a recursive function because the load and unload stream level nodes cannot be called before the previous call has finished.
I would put the sequence in the sub-level with the static meshes but the sequence needs to be visible to play it and that would mean the meshes get shown.
The only success I had was to have two sub-levels per element. One contains just the sequence and the other the meshes. Somehow unloading the sequence allows it to work but it is a rather janky workaround.
If you have a solution or just know of anyone who has done something like this before please let me know. All my searches pointed me to animation loading screens.