I have a 3d model which rotates around my screen, it's always on the Z axis = 0 where everything of my 2d images are. My 2d images fly out of the center and get bigger to give the view as getting closer. I'm trying to detect a collision so I can disable my 2d images to load new ones into the game.
My collision detection isn't working at all and I'm wondering if anyone can shed any light on this.
foreach (coins coin in coins)
{
coin.Update(_graphics.GraphicsDevice);
if ((coin.getCoinXPosition() + scale < getModelXPosition() - scale) &&
(coin.getCoinXPosition() - scale > getModelXPosition() + scale) &&
(coin.getCoinYPosition() + scale < getModelYPosition() - scale) &&
(coin.getCoinYPosition() - scale > getModelYPosition() + scale))
{
coin.coinVisible = false;
score++;
//coins.Remove(coin);
}
}