Looks like a bug in the DirectionsService to me.
If I make all the waypoints {stopover:true} then it works.
function calcRoute() {
var request = {
origin: "Bad Aussee",
destination: "Rottenmann",
waypoints: [{
location:"Lucern",
stopover:true
},{
location:"Paris",
stopover:true
},{
location:"Madrid",
stopover:true
},{
location:"Granada",
stopover:true
},{
location:"Barcelona",
stopover:true
},{
location:"Monaco",
stopover:true
},{
location:"Rom",
stopover:true
}],
optimizeWaypoints: false,
travelMode: google.maps.DirectionsTravelMode.DRIVING
};
directionsService.route(request, function(response, status) {
if (status == google.maps.DirectionsStatus.OK) {
directionsDisplay.setDirections(response);
} else {
alert("Directions request failed: "+status);
}
});
}
working example - stopover:true
not working (ZERO_RESULTS) - stopover:false, same request as above otherwise
example tries the same request first with stopover:false (fails), then with stopover:true (succeeds)
walking directions (UNKNOWN_ERROR with stopover:true, weird path with stopover:false)
walking directions using multiple requests to the DirectionsService - better, but seems to want me to swim from Monaco to Rome...