I’m currently fighting off pulling my hair out over an issue that I thought would be pretty menial but, I’m evidently having an issue with generating a motor6d in place.
I thought it would be exactly like welds in place, where you set the C0 and the C1 to the inverse of each part’s CFrame but, for whatever reason, it ended up doing this?
Here’s the function I’m working with currently:
function module.M6DInPlaceWeld(sendModule, part0, part1)
local m6D = Instance.new("Motor6D")
m6D.Part0 = part0
m6D.Part1 = part1
m6D.C0 = part0.CFrame:Inverse()
m6D.C1 = part1.CFrame:Inverse()
m6D.Parent = part0
m6D.Name = part1.Name
return
end
I have a feeling I just need to offset it in some specific way, but I can’t find what that offset is anywhere. Any help is greatly appreciated.
If you are animating it you need to use the same C0 and C1 as the one the animation uses or else the bug you are experiencing will happen as it Changes the joint position and the animation CFrame maths.
Use Motor6D:Clone() to ensure the same C0 and C1 as the one you used on the animation.