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

How do i make a brick rotate to face a clicked position?

How would i make a brick rotate to face a clicked position?

1 answer

✓ Accepted answer
CFrame.new(Vector3 pos, Vector3 lookAt)

So the pos would be the position of origin or the current position of the part, and the lookAt would be to clicked position using, mouse.Hit.P assuming your using the mouse.

Doing CFrame.new() with two vector3 in the constructor makes the part point toward the second vector3.

1 comment

0

Thank you so much.

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