Strange pathfinding in 0.47??

General discussion about the game

Strange pathfinding in 0.47??

Postby City Builder » Sat May 26, 2012 2:48 am

Anybody else experiencing strange pathfinding in 0.47?

I've attached the image below to show what I'm talking about...

Some of the Townies are taking seedlings along the path marked by the black arrows and some are taking the seedlings along the path marked by the red arrows.

The red arrow path is the fastest and shortest so I'm baffled why some of them are taking the black arrow path. Also an oddity to it, is that some townies start to take the black path and they get to about the end of the first black arrow and then immediately make a left turn and head along the path of the red arrow.

Anybody else experiencing odd path finding in version 0.47?

Image
burningpet wrote:And yeah, the Majesty reference is correct, towns will eventually aim to be a much more advanced Majesty rather than a dumbed down dwarf fortress.

Play Towns on an unlimited amount of maps: viewtopic.php?f=13&t=1659
User avatar
City Builder
 
Posts: 1944
Joined: Fri Mar 02, 2012 5:32 am
Location: Check your Mom's basement.

Re: Strange pathfinding in 0.47??

Postby uplink » Sat May 26, 2012 3:25 am

Can't test it in .47 myself yet, but in .46 I did notice they'll take a longer path if it has any roads on it when the other path has none, which seems to be the case here.

Edit: Also, they seemed to take a more circular path instead of straight, so if you had two possible routes to an area they would use one to get there and the other to return.
uplink
 
Posts: 45
Joined: Sat Mar 10, 2012 3:17 pm

Re: Strange pathfinding in 0.47??

Postby City Builder » Sat May 26, 2012 3:38 am

Well what would be strange in the image above if the road is coming into play would be that they have the option when they climb down the ladder to go the left towards the red arrow and the shortest path, or to go right along the road and take the round about way of the black arrow.

They seem to be splitting up, 60% taking the black arrow route and 40% taking the red arrow route, and all returning to the ladder via the red arrow route.
User avatar
City Builder
 
Posts: 1944
Joined: Fri Mar 02, 2012 5:32 am
Location: Check your Mom's basement.

Re: Strange pathfinding in 0.47??

Postby Torgen » Sat May 26, 2012 4:19 am

They're doing because they know you're watching, and just want to screw with you. :lol:
Torgen
 
Posts: 244
Joined: Sun Apr 01, 2012 9:46 pm

Re: Strange pathfinding in 0.47??

Postby caprontos » Sat May 26, 2012 4:41 am

not sure, but I can confirm this kinda thing happened as early as .45b.. where I had some.. interesting path choices through the moat and Baily town i made.. (much more out of the way then yours.. )

watch them after playing awhile and see if they all start going the shortest?..

also try blocking then unblocking the far path and see if it makes them always take the slowest (if you wanna play with it)..
Image
Cha Cha Cha!
User avatar
caprontos
 
Posts: 3327
Joined: Wed Apr 04, 2012 3:18 am

Re: Strange pathfinding in 0.47??

Postby Torgen » Sat May 26, 2012 4:44 am

Oh, I have an idea! Maybe some are hungrier than others, so moving slower. The speed boost the road provides the non-hungry ones is enough that it makes them choose the road over the "red" path. (If roads give a % speed boost. If it's a flat rate, it probably doesn't apply.)
Torgen
 
Posts: 244
Joined: Sun Apr 01, 2012 9:46 pm

Re: Strange pathfinding in 0.47??

Postby YetiChow » Sat May 26, 2012 6:36 am

Actually, there is another consideration as well. The townies do everything in a pre-determined order starting in the NW and ending in the SE (at leat I think it's the NW; this may have changed or I might have the directions wrong, but using these directions will work for the example) - for example if you get all the townies in the same place and issue a large order, they will work Southward from the NW corner to the SW corner, go to the Northern end of the next line and work Southward again; continuing until the order is complete. This is not always noticable because the townies often have to travel from far and wide to complete the task; so the work gets done in "patches", but when everyone starts on the same quare it's quite obvious.

I would assume that pathfinding is done in the same fashion. Contrary to popular belief, mobs in Towns try to spread apart from each other whenever possible (the reason sieges clump is because taking the shortest route possible overrides the spreading out behaviour - you'll notice that before they select a target, they spread out quite a bit, and if there is a large open area between them and their target/s they don't clump until right at the last minute, when they all rush the same townie and hence all move towards the same square). This means that if multiple townies want to move along the same path, they will still try not to occuppy the same square unless something with more priority (roads etc.) causes them to. Hence; if they can't all go the same way at the same time without clumping, then some will take the short way and some will take the long way.

The best way to avoid this is to a) have wide paths, b) stagger the orders which cause the townies to move, so only as amny as can fit on the shortest path occupy it at any one time, or c) only have one path and make sure it is paved with the fastest roads possible.

Also, this is true for all versions of Towns, not just 0.47
What's that you're eating? A nice, juicy apple? You weren't supposed to eat that you fool, you were supposed to make it into a pie! - last words recorded words of Francis D'Avre before he went looking for snowcherries, but found a hungry Yeti instead.
YetiChow
 
Posts: 2143
Joined: Wed Apr 25, 2012 9:26 am
Location: Cramped between a Yeti's small intestine and its stomach... trying not to dissolve!


Return to General discussion

Who is online

Users browsing this forum: Bing [Bot], Google [Bot] and 11 guests