Converting Motor6D to Attachment

I’m trying to convert a Motor6D to an attachment. Meaning, I want the attachment to have the same offset from Part0 as the motor. I recall there being some weld equality like

Part0.CFrame * C0 = Part1.CFrame:Inverse() * C1

but I’m totally making that up. Math bois, what do I do?

EDIT: I think I got it, though I don’t know why it works. Attachment.CFrame = C0 * C1:Inverse()

2 Likes
M6D.Part0.Attachment.Position = M6D.C0.p
M6D.Part1.Attachment.Position = M6D.C1.p

assuming both parts included in the m6d have attachments
also, doesn’t apply the rotation of it, but that’s above my pay grade.