public static NodePaths PtoPWithVIA(Tasker server, Storage st, double startX, double startY, double stopX, double stopY, double[] viaPointsX, double[] viaPointsY) { // Create a Router class using default accuracy and routing over time, and calculate the route Router router = new Router(server, Environment.ProcessorCount, st, CostType.Time); NodePaths route = router.RouteVIA(startX, startY, stopX, stopY, viaPointsX, viaPointsY, TSP.TSPType.StartToStop, true); return route; }