Look at a Player's Socket

I’m working on a turret and it currently tracks and fires at the player. However, turret head does not track the player if it changes on the Z direction. The rotation is fine. It seems to focusing on the arrow component of the player. I’d like it to aim at the chest. I tried adding a socket to one of the spine bones near the chest area and tried to get it’s location and use that as the target in the FindLookRotation but that doesn’t seem to work. Am I going about this the right way or is there a better way?

Get a reference to the target. From the reference get the mesh, then get socket location.
Use spine_1 or spine_2.

For your turret to track targets on Z the turret must be able to adjust is Pitch. Find look at rotation will give you this, you just need to apply it. Pitch and Yaw… No Roll.

1 Like

Thanks for the response. That was the approach I took. I’m probably missing something.

I do have a socket on the SKM_Simple mesh called PlayerAimPoint attached to spine_02. I did check the spelling in the GetSocketLoacation node. The line trace does follow the player on all axis’s.

Ok, I got it. I needed to find the Look At Rotation for the Turret Head separate from the base.

1 Like