Thanks for the clarification! I’m at the point where I think I’ve gotten the positioning values and the offset correct, yet I’m not sure if the code I’m using to get the hand bone transform in the socket’s local space is working correctly or not. I also can’t figure out a way to get the offset values I found to apply to the socket local space variable. The issue where the gun is no longer center camera when looking up and down because of the aim offset is still persisting.
Here’s the current code I’m using for the conversion. The value being set there is sent to the Hand IK transform update variable when I press the aim button. Here’s what that looks like on its own with the issue I’m describing.The gun is almost in the right spot but I can’t seem to get the offset value to correctly add together with the variable that set in the code example I linked. Here’s what the offset looks like on its own but not in the camera’s space, which causes it to have the same issue. This is what led me to wonder if my conversion code is correct or not. I’d be very grateful if you were able to look it over and see if its correct or if I’m missing something here!
I should note; the transition between the two states has no lerp at the moment. I’m blending between the AimOffset Hip and AimOffset Iron Sights that come with the Unreal Animation Starter Pack. This issue is also not a problem anymore if I use the code from this thread’s post #12 I mentioned earlier, although I don’t think the gun is correctly aligned using this. Either way, I’m super grateful for your help! I’m so close to getting the desired effect.