Almost done. It supports both rotate clockwise and counter-clockwise since I didn't know which one you'd prefer
How it works:
- the main menu screen lets you select an option by pressing up/down, so I added orientation to it. left/right will change the orientation once the game starts
- I rotated all the images, and it loads a specific image depending on the rotation mode. I didn't have to do this, but I wanted to save the performance cost of having the hardware rotate the images since the PD doesn't have a GPU
- then I use a function to rotate all the X/Y coordinates while anything is drawn, saving myself a ton of work
Luckily I've done this exact thing before with a Star Trek program meant to run on a tiny computer that could easily be rotated, but it's built-in screen rotation didn't rotate the X/Y coordinates of the touchscreen, thus making it useless. So I had to do it myself.