Foot placement node: Speed Threshold and Unalignment Speed Threshold parameters seem unsupported

Hi,

This is a follow-up to this previous question: [Foot placement node: option to gradually match the ground normal on [Content removed]

sorry I have not been able to take a deeper look at this until now.

I just looked at the GAS project and found the part [screenshotted in the answer to the original [Content removed] Basically the setup is the same as mine, the Remap curves excluded since we’re on 5.6. I’m using absolute speed curves instead, with the SpeedThreshold set to 60 and the Unalignment one set to 200. However, I noticed that even in the GAS project (with the original curve setup), this doesn’t seem to impact the foot rotation at all, the foot being rotated during the whole animation to match the ground normal, even when unplanted. Alpha’s value seems correct though, according to debug information.

While taking a look at the code as suggested, I found that the AlignmentAlpha variable is not used in any way, at least nothing related to foot orientation: it seems like this alpha and, thus, the Speed Threshold and Unalignment Speed Threshold parameters don’t impact the foot alignment.

Is this something planned, or missed, and do you have any ETA about this implementation?

Thanks.

[Attachment Removed]

Hey there,

Yes, Euan is right that would be the normal variables to use but there was some code removed in this CL: https://github.com/EpicGames/UnrealEngine/commit/e4fe8af46e0587f9b01f9d7e4d89b32b51318766

Specifically:

	// The target transform is a blend based on FkAlignmentAlpha.
	// Until we have prediction, favor the ground aligned position, 
	// since this will likely have a more accurate distance from plane
	FTransform BlendedPlantTransformCS = AlignedFootTransformCS;
	// When unplanted/unaligned, favor FK orientation and fix penetrations later. 
	BlendedPlantTransformCS.SetRotation(
		FQuat::Slerp(
			InputPose.FootTransformCS.GetRotation(),
			AlignedFootTransformCS.GetRotation(),
			InputPose.AlignmentAlpha));

in FAnimNode_FootPlacement::ProcessFootAlignment

The reason it was removed was that he didn’t really like how it was functioning, and the rest was in a good spot for the overall use cases.

From the dev: “Better behavior would be to preserve the original animation’s ankle angle, but this would require doing an IK in the node itself.”

If you want, you could add that back in (it’s at the end of that function) and you could tie the blended output to a float to have better control over it.

Dustin

[Attachment Removed]

Hey Dustin,

This code change worked well for us.

Thanks.

Hubert

[Attachment Removed]