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

What the difference between Vector3 and CFrame?

So basically I been using CFrame and then I came across Vector3. I wanted to know what the Difference between them and the advantage and disadvantage between these two.I would be **grateful **if you could answer my question .

1 answer

✓ Accepted answer

CFrame includes rotation; Vector3 does not. Setting a part's CFrame will allow it to be clipped through other parts. Setting a part's position will put it on top of anything it collides with.

CFrame is essentially Vector3 with a rotation matrix, and also can be used like this:

CFrame.new(Vector3) -- creates a CFrame at Vector3 with no rotation
CFrame.new(Vector3,Vector3) -- creates a CFrame at the first Vector3 whose rotation is towards the second Vector3

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