Skip to main content
GameDev.net gamedev.net
🔒 Locked

Rotating Images With Angles On KeyPresses

Started by Bench3 Aug 16, 2012 at 3:30 PM 0 replies 1k views
Original Post
Bench3
Bench3
Hi, I was wondering how I could rotate an image when I press a key. For example, if I pressed D it would rotate right and A left. I know how to set up keyListeners but not sure about the rotation.

I then wondered about how I would go about getting something to face a direction. So if I pressed G, the image would turn to face a certain angle?

Thanks in advance!

~Ben

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.