Issue with changing leg bone length while using IK feet

Hello! I am trying to make a character that I can adjust the proportions of (changing arm length and leg length for example), so I can have one base character that can easily be adjusted in order to create several other characters.

Although when I added foot IK to the mixture I ran into some issues - Unity doesn’t seem to take the modified bone lengths into consideration when positioning the IK. So the result is that the foot becomes offset from the IK target.

6562291--743488--not extended.png
This is the leg in its original length.

6562291--743491--extended.png
This is the leg when the bones have been stretched. The red lines indicate what I want to achieve.

I might have to resort to other solutions but I really hope I’ll get this working. Any help is appreciated!

Just a note in case someone stumbles upon this in the future: The issue was that the character was still using the original Avatar assigned in the import settings, so the animation system didn’t know that the size of the leg had changed. The solution was to get all the position data from the joints in the modified character skeleton and use AvatarBuilder.BuildHumanAvatar to create a new avatar in runtime.

2 Likes