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
NPF refuses to pathfind when the destination tile is the same as where the vehicle currently is #7060
Comments
Yes. Seems a bug.
Solves the problem. |
Okay, but why does it need to pathfind to reach the tile its already at? Or do you mean it refuses to pathfind through the vehicle's current tile? If so, what is wrong with turning around? |
Because it is leaving the tile and needs to find a path back.
Yes. NPF fails if destination tile is origin tile at the moment. It returns INVALID_TRACKDIR. I am looking into it. I have a branch here (6 commits), but I still have to investigate whether this works and doesn't cause new problems.
What is wrong in choosing a track on next tile? Are all-of-a-sudden-180º-turns better? |
I don't know, I'm just asking questions to work out what the actual problem is! |
I don't know either. Maybe just reversing is ok, but other pathfinders go ahead. I don't think reversing is ok in this situation, but I am not sure about it. |
For ships this means it will reverse (do a 180º turn) when there are tracks in front of it. It does not walk back. This doesn't happen with OPF or YAPF.
NPF reverses the ship at the end of the tile. The other pathfinders walk back the tiles ahead.
Best way to reproduce:
Send a ship to a buoy as the only order.
The text was updated successfully, but these errors were encountered: