Hey guys, just need a little bit of help on a game I've been working on.
The whole point of my game is to take pictures of a night sky, and you're basically rewarded for a picture that has the largest amount of things in it.
So I have randomly spawning meteors, stars, and a moon that follows a path. It's up to the player to try and time their photo correctly, and score the most points on it.
The screen is divided into 9 sections, and the arrow keys navigate around these sections. When spacebar is pressed, a photo is taken, and this is where I would want the score to be calculated.
The problem I am having is figuring how many meteors and stars are within the currently selected section.
I've looked at this thread, but there's one issue. My overlapping object is not circular. If I were to use this, I'd get a lot of false positives on if the selected screen is actually overlapping a meteor or star.
So basically, what is the easiest way to count up how many objects are overlapped by a rectangular object?
Here's the game if anyone is interested.
Thanks in advance.