Convert tilemap into core