public int isValidCoords(Point p) {
        if (p.x >= foregroundTileGrid.size() || p.x < 0 || p.y >= foregroundTileGrid.get(0).size() || p.y < 0) {
            return -1; // out of bounds;
        } 
        
        return 1;
    }