Hi. I’m working with python plugins and would like to be able to create a LevelSequenceActor, given some LevelSequence so that when I play my game, the LevelSequence is played.
So far, I have a script that creates the LevelSequence and LevelSequenceActor as well. In fact, the following is a result of doing so:
However, upon playing, the LevelSequenceActor disappears from the Outliner:
Is there a reason my LevelSequenceActor is disappearing? I can manually drag the LevelSequence I created programmatically into the Viewport and then set playback settings with its details menu and that will cause my LevelSequence to play during runtime. But, I really wanted to be able to completely automate LevelSequence creation and indefinite loop playing.
The LevelSequenceActor has been verified not to be editor-only, main-world-only or hidden either. So, it’s quite vexing that is does not remain in the world outliner during play.
While the following is not a complete answer, it does provide a mechanism by which to spawn persistent actors.
First, the reason the LevelSequenceActor, as seen in the video above, is “disappearing” from the outliner, upon play (PIE), is that it is a temporary actor. For some reason, using the LevelSequencePlayer.create_level_sequence_player api creates a temporar actor.
On the other hand, using the EditorActorSubsystem in the following manner produces a persistent actor: