Basically I want to move an object left or right from where it is facing.
I've tried simply CFraming along a Z axis, but that of course only goes along the Z axis. I want the object to be able to face any direction and still move a solid left or right.
ball.CFrame = (ball.CFrame + Vector3.new(0,0,.15)) * CFrame.Angles(0,0,math.pi/24)
You might notice that its also being rotated along the Zaxis. Would there be a way to move it left or right and rotate it? Logically, it would cause the motion to form a circle, but I don't want that.
You're almost there with the CFrame, but to make sure it works every time you're going left or right, you multiply on another CFrame rather than adding a Vector3.
Your Angles isn't correct also, the 3rd value would change the Z orientation which isn't your intended objective I'd assume as you're trying to turn left/right. Instead, the Y Axis should have math.pi/24
added to it
Finished off, it'd look like this:
ball.CFrame = ball.CFrame * CFrame.new(0,0,.15) * CFrame.Angles(math.pi/24,0,0)
I've only sorted turning right here, to turn left, it'd obviously just be -math.pi/24