Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How can I add a number value to a CFrame angle?

Asked by 10 years ago

What I want the script to do is every 1 second rotate the brick +1 on the Y axis

Workspace.Part1.BodyGyro.cframe = CFrame.Angles(0,0,0)
wait(1)
 --[[I tried CFrame.Angles(0,0,0) = CFrame.Angles(0,+1,0) But It wont work]]

1 answer

Log in to vote
1
Answered by 10 years ago
wait(1)
Workspace.Part1.BodyGyro.cframe = Workspace.Part1.BodyGyro.cframe * CFrame.Angles(0,math.rad(1),0)

You have to use math.rad function, because CFrame.Angles requires radians, instead of degrees.

0
Thanks! Really Appreciate the help! Orlando777 315 — 10y
Ad

Answer this question