finished implementing first crude version of mbtiles support