I can get the start frame and end frame, but what about the current frame? How do I do this? I need to know the percent through the section, so I figure I can get the length of the section from the difference between the start and end, and divide that by the current frame - the start frame (writing fast, ignore any errors there if you spot them, not the point).
Ideally, I’d also like to know how much time has passed as well. If I can get the framerate of the sequence as well as the current frame, I can nab that.
I’m making cartoons and I want to have certain custom stuff scrubbable.
Thanks so much … this is blocking me right now. I’m transitioning here from Unity where I knew how to do all of this, and this seems so simple, but Im blocked :/.
Okay, it seems like I can get the info I need from the sequence director. Is there any way to get access to that from the custom sequence track?
If not, the only thing I can think of is to write this stuff to the gamestate every frame using a repeating event, and then have my track which belongs to an object query the gamestate.
Which is really, really dumb. If this isn’t working yet, where do I get in touch with UE requesting this feature, since it basically destroys the ability to use this correctly if I cant get access to this data in the custom track. Something like this makes me question my switching from Unity to UE5 for creating films … since I need this to “just work”, and not have to jump through hoops for simple things like this :/.
I managed to get it working in the editor by storing the sequence directory in the gamestate, and having the custom track query the gamestate through the actor its attached to … my characters lip sync properly based on that, since I can get the current frame and the time passed that way.
However, when I use MovieRenderQueue, the characters mouth stops moving. My eyes blink so I know the morphs are working fine, so it must be this system breaks.
Definitely would love the right way to do this …
So for these custom tracks since you’re using the Customizable Sequencer Tracks I should be able to help a bit.
In the OnInputAdded event you get an object reference to the Section this event is being triggered on (of type UMovieSceneSection).
If you get the Outer object of this, you can get a reference to the Track (UMovieSceneTrack).
The Outer object of the Track is the UMovieScene.
The Outer object of the MovieScene is the ULevelSequence.
Unfortunately there’s no great way I know of to get the actual LevelSequenceActor.
But you could do a Get All Actors of Class and then for each LevelSequenceActor check if the sequence they have assigned is the same as the LevelSequence of your Section.
If it is, you know this is your LevelSequenceActor (as an extra check you may want to see if the LevelSequenceActor is actually playing, otherwise you might get issues if there are multiple LevelSequenceActors in your world that are all set to play the same sequence).
Now that you have a reference to your LevelSequenceActor you can get its LevelSequencePlayer and get the current frame from there.
Bit roundabout but this has worked for me. Let me know if there are better ways to do this!