Jump to content

Transit tubes pathfinding


riwenna
  • Branch: Preview Branch Version: Windows Pending

Transit tube path finding for small tubes seems a bit off. There's a transit tube from my kitchen to my vacuumed food storage area to avoid dupes getting sopping wet. Since they all sometimes hoard for the food, one or two of them usually did end up getting the debuff, but it was working well enough. They understood that they could go from one area to the other using that transit tube.

One of my transit tube enterances was one tile moved, so since I was waiting for some water to cool I decided to make it nice and neat and symetrical. Except, after they using it shifted for for several hundered cycles, after rebuilding it symetrically, suddenly they can't find a path through it at all! They prefer to go through the water lock and get sopping wet instead. They don't see the path on the pathfinding, and when I manually order them to go in and out of the vacuumed storage, they chose to go through the water every time never using the transit tube.

5b907e2cbff74_Screenshot2018-09-0600_58_44.thumb.png.0377f369c2664b1885fca6390fef114e.png

 

So since I'm still waiting for the water to cool down, I destroyed the left-hand side access again and re-build it at it's old space just to test if it will be working there. Now that I re-moved one of the locks, the pathfinding looks incorrect, but they still seem to be using the tube system when I manually tell them to move left and right of the waterlock (and when they need to go left and right, most of the time). I reloaded my old save and checked the pathfinding there, it was also drawn incorrect but they were passing fine.

5b907e345274f_Screenshot2018-09-0601_03_45.thumb.png.762c2e7363c2b868ec065b20fb4326ea.png

I tried closing and reopening the game...I checked that it's not due to the stations not having power... but it seems that even after being alive for nearly a 1000 cycles, the dupes can't distinguish between bathtime and dinner time, after I finally decide they have time for some symetrical remodelling :)

Closing the waterlock off for dupe access completely is not an option to force them to use the tube, when too many of them hoard at it at dinner time and drain the batteries, the late ones aren't able to find their path to dinner since the batteries are low (so they go do something else, then when they do that, somebody else drained the batteries and they're recharging again...) in any case I've tried it (with the shifted asymetrical lock), and one of them almost starved.

Savegame attached just in case but I guess it can be reproduced easily by building a waterlock shaped like above and a transit tube system to pass from one side to another, symetrical around the waterlock (as in the first picture).

Also, I managed to lose the entire game UI while trying to tab between the game and writting the bug report while loading all the different saves to test it all for the bug report, but i guess I really shouldn't be tabbing around while it's loading.

Tomato Soup.sav


Steps to Reproduce
Building a waterlock shaped like above and a transit tube system to pass from one side to another, symetrical around the waterlock. Tell dupes to go left and right. They prefer to get wet.



User Feedback


Hi @riwenna,

It looks to me like things are working as designed. Dupes always try to find the fastest path, but there are some hidden considerations in this case.

For one thing, tubes are optimized (and intended) mainly for long distance travel. There is an added cost to standing and waiting at the entrance, so for very short tubes the dupes may simply decide that walking is faster, even if it's through water.

Secondly each entrance has a limited amount of charge, and will allow as many dupes as it can currently transport to "wait in line", up to 4 dupes can try to use a fully charged entrance. If it's only half charged, only 2 will attempt to use it.  Any dupe that would exceed the current charge will take another path if one is available.

As for the navigation rendering, that's a quirk of how our pathfinding interacts with tubes. The navigation line shows where the dupe is currently allowed to path to, and until they actually try to travel through a tube and reserve a spot at the entrance, they aren't allowed to access the tube. Once a dupe has started pathfinding through a tube, the navigation line should draw through it.

Great base by the way :) 

Share this comment


Link to comment
Share on other sites

So, making the distance from tube enterance to tube enterance 1 tile longer in my second example makes them opt to use the tube since it makes the distance just about long enough?

If I may ask, does the fastest path calculation take into account: a) transit tube distance (i.e. would the "path weight" through the tube be smaller if I used a transit tube crossing to make it shorter), and b) the time they take to shake their feet while passing through water? As shaking themselves dry after passing through water is a fairly new animation taking a while to play out time, it actually makes it longer (in time) for them to go through water then through a transit tube I think (haven't timed it).

As for the navigation rendering, it still doesn't look quite correct: please look at my second example. The rendering shows a path into the right tube enterance (while not through, it clearly seems to indicate they can enter it), but not into the left tube enterance. They are still taking the tube gladly both ways.

Share this comment


Link to comment
Share on other sites

56 minutes ago, riwenna said:

So, making the distance from tube enterance to tube enterance 1 tile longer in my second example makes them opt to use the tube since it makes the distance just about long enough?

Yep.

57 minutes ago, riwenna said:

If I may ask, does the fastest path calculation take into account: a) transit tube distance (i.e. would the "path weight" through the tube be smaller if I used a transit tube crossing to make it shorter), and b) the time they take to shake their feet while passing through water? As shaking themselves dry after passing through water is a fairly new animation taking a while to play out time, it actually makes it longer (in time) for them to go through water then through a transit tube I think (haven't timed it).

a) yes, tube distance is considered, a crossing instead of a bend might make it short enough

b) no, time spent reacting to being wet (or anything) is not considered during pathfinding

1 hour ago, riwenna said:

As for the navigation rendering, it still doesn't look quite correct: please look at my second example. The rendering shows a path into the right tube enterance (while not through, it clearly seems to indicate they can enter it), but not into the left tube enterance. They are still taking the tube gladly both ways.

Yes, that is the current limitation. The tube won't correctly display as a valid path unless they've already decided to take the tube. Basically this is a reflection of whether they currently have a spot in line at the entrance.

  • Thanks 1

Share this comment


Link to comment
Share on other sites

Ty for the info :) Not a bug then I guess, but since some of the emotes take quite a while, the shortest path even when runspeed is considered often isn't any more...

I guess displaying the correct paths is of less imporance as long as they find em, but still, since the dupe who's path I'm displaying in the second screenshot is not inside the vacuum fridge area, it's odd that he would've already decided to take the tube exit (but not the enterance to get there in the first place).

Share this comment


Link to comment
Share on other sites



Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
  • Create New...