Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

Anyone know why this isn't welding properly? Check description what this code is suppose to do

The torso is supposed to be welded to the torso the other way, so it is the same length as the torso.

function weld(a, b)
    local weld = Instance.new("Weld", a)
    weld.Part0 = a
    weld.Part1 = b
    weld.C0 = (a.CFrame:inverse() * b.CFrame)
    return weld
end

go here for pictures: http://prntscr.com/frod8z

1 answer

✓ Accepted answer

On line 5 you could rotate the part by putting

* CFrame.Angles(0,math.rad(90),0)

after whats there and changing the argument to satisfy your need

This discussion is preserved as it was. New answers, comments, and votes are closed.