Animation Curves Blended by Montage?

Lets say you have an idle/walk/run setup and play a montage which blends into another animation.

So it blends into and out of the animation in the montage but it also seems to blend float curve data that I have in the animation controlled by the montage. This is undesirable in my current setup. Is there a way to avoid blending the curve data while still blending the animation. Or is there a way to get access to the original unblended curve data?

Thanks.

I found a simple workaround. I added a metadata curve (which has a value of 1) to the animation sequence. This curve is similarly reduced during blend-in and blend-out. I then divide my curve by this metadata value to get the original unblended value. In my case I was using a curve to control drawing my bow, but the instant release of the blow string was blended and was not instant. Here’s my workaround code:

3 Likes

not sure if it’s safely handled, there’s a probability ofdividing by zero, might wanna multiply by 1.0f - bowactive, and to add on top of that, if you have a reference to your montage object that’s playing, you can use get the blend weight without the metadata curve workaround by using the montage instance that can return the weight:

		FAnimMontageInstance* montageInstance = characterAnimInstance->GetActiveInstanceForMontage(currentMontage);
		float blendWeight = characterAnimInstance->Montage_GetBlendTime(currentMontage);
		if (montageInstance)
		{
			blendWeight = montageInstance->GetWeight();
		}