✓ Accepted answer
Your script isn't working since it has these fundamental flaws:
- Setting
BasePart.Orientation.X does not change the orientation of the part itself. BasePart.Orientation.X is just the X property of the Vector3 returned.
- Since
BasePart.Orientation is a Vector3, you must provide all three arguments in it's constructor as such: Vector3.new(x, y, z)
To fix this, you can add a Vector3 to the orientation
and use the X property of the same

Finally to write the script, this should do whatever you're trying to achieve:
Script using orientation:
while true do
wait(0.1)
part.Orientation = part.Orientation + Vector3.new(0.1, 0, 0)
end
Also, as commented on your post and mentioned by the wiki,
For better control over the rotation of a part, it is recommended that BasePart.CFrame is set instead
Script using CFrames:
while true do
wait(0.1)
part.CFrame = part.CFrame * CFrame.Angles(math.rad(0.1), 0, 0)
end
Please comment if you have questions or I have made a mistake
Useful links and articles:
1 comment
You should be using CFrame instead of Vector3 for this as they are intended for rotating parts. If you delete the part.Orientation.X line and replace it with part.CFrame = part.CFrame * CFrame.Angles(0,0.1,0) it will work.