you could always check if the mouse is over the sprite:
something like:
int IsMouseOverSprite(int Sprite)
{
int test_X = 0;
int test_Y = 0;
if ((dbMouseX() <= dbSpriteX(Sprite) + dbSpriteWidth (Sprite))&& (dbMouseX() >= dbSpriteX(Sprite))){test_X = 1;}
if ((dbMouseY() <= dbSpriteY(Sprite) + dbSpriteHeight (Sprite))&& (dbMouseY() >= dbSpriteY(Sprite))){test_Y = 1;}
if ((test_X == 1)&&(test_Y == 1)){return 1;} else {return 0;}
}
the code looks a bit ugly but it works great for buttons. so you can say: IsMouseOverSprite(rocksprite)