I came across the following code in a game book but I can't get it, does it check if a point ( left,top) in a rectangle?
bool CheckCollision(float left, float top, float SpriteX, float SpriteWidth, float SpriteY, float SpriteHeight)
{
return !((left >SpriteX + SpriteWidth) ||
(top > SpriteY + SpriteHeight) ||
(SpriteX > left + SpriteWidth) ||
(SpriteY> top +SpriteHeight));
}