So recently I made a welding script for one of my games, but I am trying to figure out why manual welds change the position and orientation of some of the parts in a tool. Here is the script (Server Script):
Parts = Handi:GetChildren() PrimaryPart = Handi for i = 1, #Parts do if Parts[i]:IsA('BasePart') then local weld = Instance.new("Weld") weld.Part0 = PrimaryPart weld.Part1 = Parts[i] weld.C0 = PrimaryPart.CFrame:inverse() weld.C1 = Parts[i].CFrame:inverse() weld.Parent = PrimaryPart end end
This also happens with a weld plugin I am using: https://gyazo.com/1271e3811455bb87b7205014fb0366d4
How can I avoid changing the parts position and orientation?