I have always had this problem and am finally looking into it. I have a code that rotates a brick 90*. Yet for some reason it is not rotating correctly. I have heard stuff such as floating point errors and stuff but I don't think that is the problem. Please help!
local part = script.Parent part.CFrame = part.CFrame * CFrame.Angles(math.deg(0),math.deg(90),math.deg(0))
You're looking for math.rad(x)
which takes degrees and converts to radians as opposed to math.deg(x)
which takes radians and converts to degrees. The CFrame.Angles
function takes the angles as radians so you need to adjust your arguments.
To reiterate, you want:
local part = script.Parent part.CFrame = part.CFrame * CFrame.Angles(math.rad(0),math.rad(90),math.rad(0))
Hopefully that answers your question for you