Bronze Challenge


The bronze challenge was pretty straight forward.
1 line change.
added [worldView setMapType:MKMapTypeSatellite]; to viewDidLoad

-(void)viewDidLoad {
    [worldView setShowsUserLocation:YES];
    [worldView setMapType:MKMapTypeSatellite];


That’s exactly how I did it - works perfectly. :smiley:


Does the order in viewDidLoad matter? i.e. is one of these better than the other?

Option 1:
[worldView setShowsUserLocation:YES];
[worldView setMapType:MKMapTypeSatellite];

Option 2:
[worldView setMapType:MKMapTypeSatellite];
[worldView setShowsUserLocation:YES];


Is this a question, or are you suggesting we should think about it this way? I can’t work out if you’re a beginner because you seem to have some pretty quality answers…

For what it’s worth, I did the setMapType: before setShowsUserLocation: because I figured you should set the type before the default mapType gets put on screen - no point changing the type after it’s put on screen, right?


I wrote that back when I was still trying to get some of the concepts solidified in my head. Ultimately the answer is: it really doesn’t matter. But stylistically, option #2 is better.


The implication here was that you wanted us to do this programmatically,
but the easiest, quickest way to do this would be to change the view in the xib file, yes?
One check box and done.