Possible Bug: TwoBoneIK continues to use TakeRotationFromEffectorSpace even when EffectorLocationSpace is in WorldSpace

Sorry if there’s already a bug on this but I’m new to the and I didn’t have time to figure out how to search for existing bugs outside of the AnswerHub and the documentation.

While trying to get Hand IK working on an FPS demo, I was having a problem with the TwoBoneIK node. I wanted to feed it a WorldSpace EffectorLocation based off a socket on the weapon they’re holding. At one point I had copied some other tutorials and had checked bTakeRotationFromEffectorSpace before changing EffectorLocation from BoneSpace to WorldSpace. Once WorldSpace is set, the ‘End Effector’ section of properties is hidden and bTakeRotationFromEffectorSpace is no longer visible to uncheck. However in AnimNode_TwoBoneIK.cpp, it still uses that variable to determine the EndBoneCSTransform.

I believe this is a bug b/c the EffectorTransform has no Rotation in it as it came from a WorldSpace location. So my IKBone was always facing north in world space. Once I unchecked bTakeRotationFromEffectorSpace it started working properly and left the rotation of my IKBone unchanged. I believe the lines in AnimNode_HandIK that check both bTakeRotationFromEffectorSpace and bMaintainEffectorRelRot to modify the EndBoneCSTransform should be guarded by “if ( bBoneSpace ) { … }”.

Hey qaat,

I’m working on setting up a test project for this, but it might be a little quicker to ask you if you have a standalone project with an example of this. If not, I’ll conteinue trying to repro on my end, but figured I would ask before eating up too much time setting this up.

-.

I do not. However you should be able to see the User Interface issue of hiding those options on any Two Bone IK node. And you should be able to see the code issue just by reading through FAnimNode_TwoBoneIK::EvaluateBoneTransforms. Towards the bottom when it’s calculating EndBoneCSTransform is where you’ll see the issue of using bTakeRotationFromEffectorSpace despite EffectorLocationSpace being BCS_WorldSpace.

Hi qaat,

Sorry for the delay in getting back to you. We have used the information you have provided to enter the following bug report: JIRA [UE-28876]. When this issue has been resolved, we will notify you with an update to this post.

Thanks for bringing this to our attention,

.

This bug has been verified fixed for a future release of the Engine. Thanks again for the feedback.