Hello reader, hope you’re having a great day.
How would I go about pointing a players arm towards a part? More specifically, I am unsure how to go about manipulating the players’ shoulders’
Motor6D.C0 property to point towards a part each
RenderStepped while using the shoulders natural position.
I have this code so far, which works, but the shoulder remains at the midpoint of the arm (
local shoulder: Motor6D = character["LeftUpperArm"]["LeftShoulder"]; local jointPosition = shoulder.Part0.CFrame:toWorldSpace(CFrame.new(0,0,0)) local cframe = CFrame.new(jointPosition.p, workspace.PartToPointAt.Position) * CFrame.Angles(math.pi/2, 0, 0) * CFrame.new(0, -1, 0) shoulder.C0 = shoulder.Part0.CFrame:toObjectSpace(cframe)
I cannot use pre-defined offsets, as the R15 rigs scale during gameplay.
Thanks a lot for your help.