I am trying to offline my map using Mapbox and Xcode, however it seems to get stuck during the download process without any warning. I use this code to check what tile it's currently on:
- (void)tileCache:(RMTileCache *)tileCache didBackgroundCacheTile:(RMTile)tile withIndex:(int)tileIndex ofTotalTileCount:(int)totalTileCount
{
NSLog(@"Caching Tile %i", tileIndex);
}
However the map always gets stuck caching tile 495 but never hits
- (void)tileCacheDidFinishBackgroundCache:(RMTileCache *)tileCache
or
- (void)tileCacheDidCancelBackgroundCache:(RMTileCache *)tileCache
I had this issue before and fixed it by creating a new project on the Mapbox website. I don't want to do this again as I have layers etc and this problem seems to occur if I don't use the map for a little while. Has anyone else had this issue or can anyone offer any advice as to how I can debug / counter this?
Thanks