Playing an Anim Montage right as another is ending

Right now I’m working on some character and weapon animations and I’m trying to make an anim montage play immedieately after another.

I’m having an issue where the animation starts blending out to the original base pose for a little bit before the new anim montage starts playing. It’s pretty jarring. I just want a completely clean transition from one animation to another.

I’m currently making my montage call a start blending out delegate and I start playing the new animation as soon as it begins blending out, but it’s still pretty hard to prevent a noticeable jumping. I can also just have 0 blend out on my animations but I want to avoid that so I don’t have to always design my animations to have to be in the right positions at the end and beginning in case I want to reuse some animations like a shotgun cocking in different situations.

I tried messing with the engine code to force a montage to remain frozen when it’s done playing instead of blending out until a new animation begins, but as soon as the new animation begins, it still does the noticeable jump.

I could never get animation conditions in the state machine to transition 1:1 as one is ending no matter what I tried to do (for example, jump start to loop to jump end, these transitions always have issues). There is always a huge jitter from animations “restarting” or something, or a huge overlap. This is very evident in the youtube video Zak made for the third person anim montages, and was never addressed. My only guess is that those conditions are not frame-perfect and you need to use animnotify events to transition animations. I haven’t tested it yet, but I think that’s what a good chunk of Couch Knights uses. I am not actually sure if that is also your problem but it sounds very similar.

I fixed this a while ago where I modded the engine to treat blend out times less than 0 as freezing the last frame and the transitions were perfect. Epic didn’t like my pull request so it never made it in.

Now I tried again with a different approach where I make the Play call take an optional parameter that’s false by default to do the same thing and my code is almost identical, only it seems to no longer work for some reason. Maybe they changed something since like version 4.3 or whatever I was on back then. It only works well if every animation has 0 blend in and blend out time.

My theory is the animation playing code is asynchronous in some way running on a different thread. Even though I’m telling the engine to play my new animation as soon as I get a call to the begin blend out delege, there must be a few frames in whatever thread drives animations where it doesn’t actually have a montage to blend to so it blends to the base pose.

Maybe it needs to be notified to start a transition a little before the blend out begins, or a forced synchronization of some sort needs to happen between the threads, if this is the case.

Made this pull request to hopefully fix the issue:

Starting reading this thread thinking “perfect, this is the exact issue I’m having!” Alas there’s no solution yet it seems.

The GitHub link is now dead.
Is there any proper way to blend out from 1 animMontage to another animMontage without returning idle pose immediately?