I have a man with gun sprite and I’d like the bullet to actually come from his gun rather than the center of the sprite (his head).
The problem is that I can’t just use a simple offset as the guy can rotate 360 degrees.
I imagine there’s some kind of formula that would take into account his current rotation, but my math-fu isn’t that strong.
Anyone know such a formula or some other way to handle that? (If it’s stupid easy and I’m just overlooking it, let’s chalk it up to the fact that it’s coming up on finals and I shouldn’t even be coding at all right now!)
Jay
Here’s a look at the guy.