Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Burrows to reduce pathfinding.  (Read 1961 times)

Vehudur

  • Bay Watcher
  • [evil]
    • View Profile
Burrows to reduce pathfinding.
« on: September 21, 2011, 03:56:58 pm »

I had the idea of using burrows to reduce pathfinding and thus increase FPS...

Just to limit dwarves to places they should never need to go - I.E. a weaver never needs to go down to the forges.  Haulers would be limited to being inside the fortress.  It would also be a good way to prevent sock syndrome, because everyone is already in burrows.

Is this viable, or will dwarves still check paths outside of the burrow?

Also, butchering all the cats.
Logged
Quote
...and a third died in his bunk of natural causes - for a dagger in the heart quite naturally ends one's life.

I used to have an avatar, but I was told to remove it after it kept making people go insane.

Roraborialisforealis

  • Bay Watcher
  • [HATEBILLION:UNTHINKABLE]
    • View Profile
Re: Burrows to reduce pathfinding.
« Reply #1 on: September 21, 2011, 04:17:11 pm »

Yes. And whine about stuff that isn't in it. All you get is a lot of very pissed off announcements. Traffic zones is what you want.
Logged
Spoiler (click to show/hide)

Sphalerite

  • Bay Watcher
    • View Profile
    • Drew's Robots and stuff
Re: Burrows to reduce pathfinding.
« Reply #2 on: September 21, 2011, 04:39:43 pm »

Burrows have no effect on pathfinding.  Burrow assignments control what dwarves do, but not where they walk.  The pathfinding code ignores burrow assignment.

It's still a good idea to use burrows to limit dwarves to areas they actually need to be in, but it's not going to help pathfinding much.
Logged
Any intelligent fool can make things bigger and more complex... It takes a touch of genius --- and a lot of courage to move in the opposite direction.

DrGravitas

  • Bay Watcher
    • View Profile
Re: Burrows to reduce pathfinding.
« Reply #3 on: September 21, 2011, 06:14:10 pm »

I also highly suggest judicious use of traffic-density designators, even though they can't be assigned to particular dwarves (or stop them from charging after socks.) Nothing reduces the pathfinding time better than telling the algorithm that this node tile is too costly to even bother expanding, unless it's all out of options.

Use them all the time in my high population forts, to make highways with on and off ramps to the more common local destination groups. Heh, even took the highway metaphore literally once and built an elevated road system in the surrounding territory so I could maximize the forest growth to fuel my insatiable (and magma-less) steel works industry.
Logged

Vehudur

  • Bay Watcher
  • [evil]
    • View Profile
Re: Burrows to reduce pathfinding.
« Reply #4 on: September 21, 2011, 07:37:30 pm »

What should I set the weight of the restricted traffic areas as (per tile, default is 25 I think)
Logged
Quote
...and a third died in his bunk of natural causes - for a dagger in the heart quite naturally ends one's life.

I used to have an avatar, but I was told to remove it after it kept making people go insane.

DrGravitas

  • Bay Watcher
    • View Profile
Re: Burrows to reduce pathfinding.
« Reply #5 on: September 21, 2011, 10:35:46 pm »

I think that's fine. As I recall, the regular tiles are only rated a 1 or 5 or something.
Logged

krenshala

  • Bay Watcher
    • View Profile
Re: Burrows to reduce pathfinding.
« Reply #6 on: September 21, 2011, 10:56:25 pm »

Its 1 (restricted), 2 (low), 5 (normal), 25 (high) for traffic levels.
Logged
Quote from: Haspen
Quote from: phoenixuk
Zepave Dawnhogs the Butterfly of Vales the Marsh Titan ... was taken out by a single novice axedwarf and his pet war kitten. Long Live Domas Etasastesh Adilloram, slayer of the snow butterfly!
Doesn't quite have the ring of heroics to it...
Mother: "...and after the evil snow butterfly was defeated, Domas and his kitten lived happily ever after!"
Kids: "Yaaaay!"

acetech09

  • Bay Watcher
  • Bay Watcher
    • View Profile
Re: Burrows to reduce pathfinding.
« Reply #7 on: September 21, 2011, 11:42:49 pm »

That's backwards. 1 high traffic, 2 normal, 5 low, 25 restricted.
Logged
I challenge you to a game of 'Hide the Sausage', to the death.

Girlinhat

  • Bay Watcher
  • [PREFSTRING:large ears]
    • View Profile
Re: Burrows to reduce pathfinding.
« Reply #8 on: September 21, 2011, 11:48:56 pm »

Yeah, it means that a dwarf will try to path through 5 tiles before pathing through a restricted zone, and if they've got a nice High passage, then it's 25 times more costly.  If there happens to ever be a job in the restricted zone, it will cost more pathfinding, but this is infinitely compensated by the everyday pathfinding.

If you've got all your worthwhile things underground, or above ground in a tower, or something else very localized, then restricting the entire surface can reduce pathing quite a bit, because let's face it, your dwarves are only loitering between the farm, the stockpiles, and the dining hall.  They don't need to path through the bright and happy forest to fetch their kitten tallow roasts.

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: Burrows to reduce pathfinding.
« Reply #9 on: September 22, 2011, 07:02:54 pm »

Yeah, it means that a dwarf will try to path through 5 tiles before pathing through a restricted zone, and if they've got a nice High passage, then it's 25 times more costly.  If there happens to ever be a job in the restricted zone, it will cost more pathfinding, but this is infinitely compensated by the everyday pathfinding.

If you've got all your worthwhile things underground, or above ground in a tower, or something else very localized, then restricting the entire surface can reduce pathing quite a bit, because let's face it, your dwarves are only loitering between the farm, the stockpiles, and the dining hall.  They don't need to path through the bright and happy forest to fetch their kitten tallow roasts.

No, they'll try to path through 12 tiles before pathing through a restricted zone.  2 is normal, not 5.

Girlinhat

  • Bay Watcher
  • [PREFSTRING:large ears]
    • View Profile
Re: Burrows to reduce pathfinding.
« Reply #10 on: September 22, 2011, 07:34:04 pm »

Oh, derp, then yeah!  Even better!