Ship can't decide whether or not it wants to go for maintenance #8912
Labels
component: pathfinder
This issue is related to Pathfinder
needs triage
This issue needs further investigation before it becomes actionable
Version of OpenTTD
1.10.0
Expected result
When a ship wants to go for maintenance, it should go to the nearest depot, and shouldn't suddenly decide while it's heading for the depot that actually it doesn't want to go for maintenance.
Actual result
If the nearest depot and the ship's destination are in opposite directions, the ship first decides it wants to go to maintenance, so it turns around to head for the nearest depot, which I guess is expected behavior. The problem is that after it has turned around, while it's heading for the depot, it suddenly decides that it doesn't want to go for maintenance, so it turns around again to go to its destination. Then when it's heading for its destination, it changes its mind again and decides that it wants to go for maintenance. So it gets stuck in an infinite loop.
Steps to reproduce
Download and unzip this saved game.
In order to open the game, you will need to install the following NewGRFs:
They can all be installed by going to NewGRF Settings > Check Online Content.
Open the saved game.
Go to the list of ships and open the information window for Ship 16.
Observe what Ship 16 is doing. It's stuck in an infinite loop, and can't decide whether it wants to go for maintenance at Bay Minette Ship Depot or if it wants to go directly to its destination at Norman Center Industrial Park.
I realize that in this specific case I can easily fix the problem by building a new ship depot closer to where Ship 16 is stuck (and that's what I will do in the game), but it would still be nice if you could fix this so that ships don't do that in future versions of OpenTTD.
The text was updated successfully, but these errors were encountered: