Retrieving the current rotation of a custom PShape

I am teaching myself to code through coding games, I am currently working on asteroids.

The player is rendered as a custom PShape, and is rotated with ship.rotate(RotVel);
RotVel is a float that is modified by the A and D keys.

In order to have the ship go in the direction it is facing I need to retrieve it’s rotation.

Is there any method to retrieve the current rotation, and if not, what should I do to get it?

1 Like

is the current angle

Please ask more specifically

RotVel is the velocity of rotation, each frame ship.rotate(RotVel) is called

No, it’s the current angle, it just adds up

:wink:

1 Like

Ohhh, that makes sense now.