tileX = Math.floor(playerX / tileWidth);tileY = Math.floor(playerY / tileHeight);
I don't even have to use the ScreenTo or the MapTo after all. It never even occurred to me to do it that way.