Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

an issue about the function set_vehicle_route #130

Open
snowman109 opened this issue Jul 1, 2021 · 2 comments
Open

an issue about the function set_vehicle_route #130

snowman109 opened this issue Jul 1, 2021 · 2 comments

Comments

@snowman109
Copy link

what 's the rule for this function? for example(This is a log I printed out.):

vehicle_id:flow_1371_0, current_road:edge301, eng_current_road:edge301, new_route:['edge301', 'edge341', 'edge316', 'edge274', 'edge285', 'edge282', 'edge246'], end_road edge73

The following is the meaning of this log:
The vehicle "flow_1371_0" start road is edge301 and end road is edge73 .And this vehicle is on the edge 301, I also get the same result from the engine.
I want this car to drive in sections, so for the first section I give its route is ['edge301', 'edge341', 'edge316', 'edge274', 'edge285', 'edge282', 'edge246'], I use the function eng.set_vehicle_route('flow_1371_0',['edge301', 'edge341', 'edge316', 'edge274', 'edge285', 'edge282', 'edge246']). And I'm sure the route is connected. But I got false from this function.

@snowman109
Copy link
Author

i also use the function for other vehicles, most of them return true, and a few of them return false. But I don't know why

@snowman109
Copy link
Author

Let me correct it. I was used the last n-1 element of the list. eng.set_vehicle_route('flow_1371_0',['edge341', 'edge316', 'edge274', 'edge285', 'edge282', 'edge246'])

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant