So, in a script I'm making I want a part to have a constant rotation of (0, 0, 0). Unfortunately, I don't know how to change the rotation of an object through script. The current script I have is this:
function changed(Rotation)
if script.Parent.CFrame ~= script.Parent.CFrame * CFrame.fromEulerAnglesXYZ(0,0,0) then -- if rotation is not (0, 0, 0) then
script.Parent.CFrame = script.Parent.CFrame * CFrame.fromEulerAnglesXYZ(0,0,0) -- make rotation (0, 0, 0)
end
end
script.Parent.Changed:connect(changed) -- script.Parent is a part
So, I need a statement that will correctly change an object's rotation through script, without the math.pi mumbo jumbo (unless that's the only way to do it).

4 comments
Why does changing the rotation have to be so complex in Lua? It should just be the same as position...
It's not complex at all, actually. The problem with setting Position and Rotation directly is that ROBLOX will then shunt the Parts upwards until there are no collisions. This can only be circumvented by using CFrame.
So, how would I get a value out of rotation, such as putting a part's rotation into a Vector3Value?
Vector3Value.Value = Part.Rotation --Rotation as a property IS a Vector3.