--attachmentWorldCFrame = part1.CFrame * attachment.CFrame --how attachment.WorldCFrame is calculated
--inverse both sides by attachment.CFrame
--attachmentWorldCFrame * attachment.CFrame:Inverse() = part1.CFrame


local part1 = script.Parent
local attachment1 = script.Parent.Attachment
local attachment2 = script.Parent.Parent.Partw.Attachment

part1.CFrame = attachment2.WorldCFrame * attachment1.CFrame:Inverse()
