Head/arms aiming at the camera direction not working

I’m working on a third person guns mechanic, and its going great except i cant get the arms to aim where the camera looks at properly.

I have this code, its connected to a onserverevent that fires on renderstepped from a local script, and it works fine as long as no animations are playing. With animations, the arms barely move, move the wrong direction or dont move at all.

Weirdly, it also worked on top of animations when the animations were published to my profile, instead of the group the game is from, but the anims dont work outside of testing otherwise.

	local leftMotor6 = character:WaitForChild("LeftUpperArm").LeftShoulder
	local rightMotor6 = character:WaitForChild("RightUpperArm").RightShoulder
	local headMotor6 = character:WaitForChild("Head").Neck

	leftMotor6.C0 = CFrame.new(leftMotor6.C0.Position) * CFrame.Angles(camera.LookVector.Y, 0, 0)
	rightMotor6.C0 = CFrame.new(rightMotor6.C0.Position) * CFrame.Angles(camera.LookVector.Y, 0, 0)
	headMotor6.C0 = CFrame.new(headMotor6.C0.Position) * CFrame.Angles(camera.LookVector.Y, 0, 0)

I’m looking for any assistance on how to get it to work again, because it DOES work with the animations before I reuploaded them to the group.

Did you give the group permission to use the animations?

I think. the animations work fine, i own the group anyway

Is the priority level or whatever its called of the animations set to what it should be?

Yes, but from what I understand you have to check off if you are able to use it. If you don’t then it doesn’t work.

sry for the late reply, but why would I wanna check it off? I need to use them. i want the script to work on top of the animations

Sorry, I meant “check it off” as what you’d do to click the box to check it ‘on’.

im not sure what you mean but my animations work. its the script block i shared that doesnt

try inverse kinematics rather than this

Thanks but how would I use inverse kinematics for this?