The app I am developing(using Xcode 9 and swift 4) requires the user to move through the map in hybrid flyover mode. I have achieved that much, but I want to permanently change the angle (so they can see buildings and statues) as the navigate through the map. As of right now they can see the map from directly overhead and have the adjust angles manually. below is the code I have used so far
let distance: CLLocationDistance = 650
let pitch: CGFloat = 65
let heading = 0.0
var camera: MKMapCamera?
override func viewDidLoad() {
super.viewDidLoad()
mapView.mapType = .satelliteFlyover
let coordinate = CLLocationCoordinate2D(latitude: 40.7484405,
`enter code here` longitude: -73.9856644)
camera = MKMapCamera(lookingAtCenter: coordinate,
fromDistance: distance,
pitch: pitch,
heading: `enter code here`heading)
mapView.camera = camera!
}
@IBAction func animateCamera(_ sender: AnyObject) {
}