Hi there,
The issue I am having is I can't get the walking & automobile transport type working together.
Lets say i have a map showing 10 pins from a distance range between 100meters and 10km around my position
Its either I make a direction request with .walking and I only get walking directions.
or .automobile and I only get driving directions.
So I dont' understand why the api is allowing us to pass a set of transport types.
https://developer.apple.com/reference/mapkit/mkdirectionsrequest/1433152-transporttype
And alternate routes
https://developer.apple.com/reference/mapkit/mkdirectionsrequest/1433154-requestsalternateroutes
Im using
let request: MKDirectionsRequest = MKDirectionsRequest()
request.source = MKMapItem.forCurrentLocation()
request.destination = MKMapItem(placemark: MKPlacemark(coordinate: coordinate, addressDictionary: nil))
request.transportType = [.walking, .automobile]
request.departureDate = Date()
request.requestsAlternateRoutes = true
let directions: MKDirections = MKDirections(request: request)
directions.calculate { [weak self] response, error in
[...]
}Is there a way to get the fastest route, regardless of the transport type ?
Thank you !