Announcement

Collapse
No announcement yet.

sequencer python scripting limitations

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

    sequencer python scripting limitations

    I'm finding that it's not possible to add an animation clip to a track in sequencer via python. Has anyone else tried this? I am able to create a level sequence, add a track for a character, add a skeletal mesh animation track, add a section to that track... But not add actual animation to it. Here's my working code up to that point:

    char = ue.EditorLevelLibrary.spawn_actor_from_object(charAsset, [0,0,0])
    charTrack = sequence.add_possessable(char)
    animTrack = charTrack.add_track(ue.MovieSceneSkeletalAnimationTrack)

    Has anyone gotten beyond this with python?

    #2
    You'll need to add a section on the track and set its range/duration. The section points to the animation asset.

    Something like:
    animSection = animTrack.add_section()
    animSection.set_range(make_range_seconds(0, length))

    You'll need to set the animation asset on the section as well. I can't remember off the top of my head, but it's probably something like:

    animSection.set_editor_property("Animation", yourAnimimationAsset)

    Take a look in here for examples: Engine\Plugins\MovieScene\SequencerScripting\Content\Python

    Comment


      #3
      These examples are fantastic! Thanks, I didn't realize there were examples hidden in the engine folder. Will dig into this.

      Comment


        #4
        i have a problem , how can i use python sequencer

        Comment


          #5
          I'm finding that it's not possible from Python to add sequencer tracks for camera properties (like focal length) or particle systems toggle tracks. Has anyone found a way to do either?

          Comment


            #6
            Originally posted by johnson5jr View Post
            I'm finding that it's not possible from Python to add sequencer tracks for camera properties (like focal length) or particle systems toggle tracks. Has anyone found a way to do either?
            I have same problem,add sequencer tracks for particle systems toggle tracks,did you find a way to do this?

            Comment


              #7
              I was able to add a particle systems toggle track, but not add keys to it. Adding the track is much the same as adding other tracks.

              Comment

              Working...
              X