I have been hard at work on a space sim. Right now I'm working on the radar functionality. I generated a bunch of random planets and am trying to track them on a radar. At first I wanted a radar like most space sim games have, where the middle of the radar is straight ahead and up is above you, down is below you, left is to your left, right is to your right, and on the edges of the radar means your target is behind you.
This was a little beyond my capabilities.
So then I figured I'd try a 2d-style radar and let the player figure out for himself if the target was above or below him, and wind up with a minimap of sorts. This is a bummer, especially in a free-roaming space sim. I don't really want it, but for now, at least until I figure out something better, I'm going to have to go with it.
Unfortunately, I can't get it working.
I figured I'd tell it the central point on the radar, tell it the angle it needs to move and the distance it needs to move, and then draw the dot right there.
It decided not to do what I wanted.
If anyone can give me a hand, especially if said hand includes helping me realize my original intent for this radar thing, that would be fantastic.
The functions for the radar are the last two, so just scroll all the way to the end.
Sanba Games: Because We Can