included waypoints, but it returns a json-error. added and updated code in generel.