I placed this script in the cylinder part:
function onTouched() script.Parent.CFrame = CFrame.new(script.Parent.Position.X, script.Parent.Position.Y - 0.2, script.Parent.Position.Z) end script.Parent.Touched:connect(onTouched)
When I touch the cylinder part, it's rotation goes from (0, 0, -90) to (0, 0, 0)! How can I prevent this? Thank you!
You are setting its CFrame. The CFrame you are setting it to does not have a rotation. Multiply it by CFrame.Angles(0,0,-math.pi/2)
to add the (0,0,-90) rotation.