Dwarf Fortress Bug Tracker - Dwarf Fortress
View Issue Details
0001145Dwarf FortressDwarf Mode -- Combatpublic2010-04-14 08:422016-05-18 13:31
king doom 
Toady One 
normalminoralways
resolvedfixed 
0.31.02 
 
0001145: Dwarves will only flee in one direction.
I made a walled off stairway into the caverns going down several Z levels. On the bottom floor of the cavern I made an entrance in the walled off stairway on the north side of the structure, a small three by four room filled with cage traps, with the entrance proper to the cavern in the north wall of this room, one square wide. Whenever a dwarf is rearming a cage trap and is startled by a crundle, rather than fleeing south into the stairway and the rest of the fort, he will ALWAYS flee north, towards the creature that startled him, through the doorway and out into the cavern. This is fun when the doorway is occupied by the crundle that startles the dwarf, as the wretched little thing always gets trampled.
Build a stairwell from the roof of a cavern down into the floor of it. Reinforce, add a doorway to the north of this structure. Joined to thus, build a second room, fill that with cage traps, place a door in the north wall of this room and wait for crundles to come swarming in. They will scare your mechanics who will run past/over them into the caverns to the north of the entire thing.
pathfinding
has duplicate 0003730resolved Footkerchief Kobold thieves don't run from goblin ambushers. 
has duplicate 0008526resolved Footkerchief Civilian dwarves attack invaders 
related to 0007364resolved Toady One Wild animals "flee" northwest 
related to 0005676new  Dwarves Fail to Respect Burrows When Fleeing Enemy 
related to 0006903resolved Toady One Fleeing dwarves ignore dangerous terrain 
Issue History
2010-04-14 08:42king doomNew Issue
2010-04-14 08:43king doomTag Attached: pathfinding
2010-04-14 08:50king doomNote Added: 0003467
2010-04-14 08:51FootkerchiefNote Added: 0003468
2010-04-14 11:33FootkerchiefCategoryPathfinding => Dwarf Mode -- Combat
2010-04-20 04:50Khym ChanurIssue Monitored: Khym Chanur
2010-07-25 14:37FootkerchiefNote Added: 0011015
2010-07-26 08:58king doomNote Added: 0011076
2010-07-26 08:59king doomNote Edited: 0011076bug_revision_view_page.php?bugnote_id=0011076#r4316
2010-07-27 08:16king doomNote Edited: 0011076bug_revision_view_page.php?bugnote_id=0011076#r4348
2010-08-04 05:34king doomNote Added: 0011477
2010-11-20 07:14king doomNote Added: 0014054
2010-11-20 07:18king doomNote Edited: 0014054bug_revision_view_page.php?bugnote_id=0014054#r5381
2010-11-26 07:29FootkerchiefRelationship addedrelated to 0003730
2011-10-15 06:16KogutIssue Monitored: Kogut
2012-06-13 07:26TelarinNote Added: 0022978
2012-06-13 08:40TelarinIssue Monitored: Telarin
2012-06-13 17:07krenshalaNote Added: 0022984
2012-06-13 17:07krenshalaIssue Monitored: krenshala
2014-01-27 21:36FootkerchiefRelationship replacedhas duplicate 0003730
2014-07-16 08:10FootkerchiefRelationship addedrelated to 0007364
2014-07-16 08:10FootkerchiefRelationship addedrelated to 0005676
2014-07-16 21:53indigofenixNote Added: 0026710
2014-08-11 06:00FootkerchiefRelationship addedrelated to 0006903
2014-11-07 14:06FootkerchiefRelationship addedhas duplicate 0008526
2014-11-07 14:06FootkerchiefAssigned To => Footkerchief
2014-11-07 14:06FootkerchiefStatusnew => confirmed
2016-05-18 13:31Toady OneNote Added: 0035229
2016-05-18 13:31Toady OneStatusconfirmed => resolved
2016-05-18 13:31Toady OneResolutionopen => fixed
2016-05-18 13:31Toady OneAssigned ToFootkerchief => Toady One
2016-08-08 18:14krenshalaIssue End Monitor: krenshala
2018-02-01 11:56TelarinIssue End Monitor: Telarin

Notes
(0003467)
king doom   
2010-04-14 08:50   
Okay, just had this happen with a different stairway, only this one was built south instead of north. (this would be so much easier if we had a way to attach diagrams or images) and again, the dwarf ran over the crundle and out into the cavern, instead of running up the stairs and into the fort and safety.

There was nothing blocking the dwarfs path in this or my previous note, no locked doors, raised bridges, etcetera etcetera.
(0003468)
Footkerchief   
2010-04-14 08:51   
You can just upload images to tinypic (http://tinypic.com/ [^]) and post the links here. That's probably faster anyway.
(0011015)
Footkerchief   
2010-07-25 14:37   
Reminder sent to: king doom

If you can get a save that reproduces this problem, it would be helpful to upload it to http://dffd.wimbli.com/ [^]
(0011076)
king doom   
2010-07-26 08:58   
(edited on: 2010-07-27 08:16)
Just checked through my saves, I don't have the fort this happened in, and I haven't been playing for awhile, waiting for all the assorted bugs to get squashed. I did come up with an illustration of the problem though.

[IMG]http://i27.tinypic.com/6pysl0.jpg[/IMG] [^]

EDIT: I have a fort in the works with a similar setup, I'll keep an eye out and upload a save if the behaviour happens again.

(0011477)
king doom   
2010-08-04 05:34   
Right, I managed to reproduce the bug in a new fort, Info is in the file listing but I'll C/P it here:

As requested, a file with a setup demonstrating how pathfinding will send a dwarf fleeing not away from, but directly into hostile creatures if the right circumstances are met.

The problem area is on z level -29, the area with the room where the cage traps are being constructed. The mechanic will spot a nearby crundle, and rather than run left, to the stairwell and safety, will run right, over the approaching crundle and into the caverns. The mechanic is already running around in the middle of a nearby pack of crundles, having done just this seconds before I saved the game.

Only change made to the raws was removing the EXOTIC tag, since the dungeon master is bugged and never arrives.


http://dffd.wimbli.com/file.php?id=2895 [^]
(0014054)
king doom   
2010-11-20 07:14   
(edited on: 2010-11-20 07:18)
Just to confirm this still exists in the lates version, 31-18, I had a mechanic run to his death in a cavern rather than flee to safety up a nearby staircase HE JUST WALKED DOWN.

(0022978)
Telarin   
2012-06-13 07:26   
Fix suggestion: Instead of running in a random, but not really random direction, have a startled dwarf attempt to head to a meeting area, but use weighted pathing. The closer the tile being pathed is to a visible hostile creature, the greater the tile cost. This would use a little more work to calculate, but since fleeing isn't that common of an activity, it shouldn't be too noticable. This would give dwarves running away a bit more intelligence in escaping to safety.
(0022984)
krenshala   
2012-06-13 17:07   
I ran into this a few minutes ago. Dwarf crossing a 1x4 bridge encountered a kobold ( ++kd ). It paused with the usual "Thief!" warning, and since I was curious if the kobold would attack, I stepped through things a bit (20 or so ticks). The kobold immediately turned back to flee from the dwarf ( +k+d ), then the dwarf, having displayed a "Herbalist: interrupted by kobold thief" message, fled as well -- toward the kobold ( +kd+ ). Stepping further, the kobold again moved west, and the dwarf did so as well, until both were on the west bank of the stream.

A few minutes later a second thief showed up, and a different dwarf, this time in the woods, also ran west to escape the kobold that was to the west of him.

Perhaps the "run for your life!" function has the directions reversed?
(0026710)
indigofenix   
2014-07-16 21:53   
There is a similar bug with adventurers on the surface, but usually, creatures will flee northwest, toward the map's (0,0) position (upper-left corner), which is to be expected if they are trying to reach a point that is not set. A lot of the reports here don't confirm this theory, but many of them are underground, where pathing could be more complex.

Check the entire map layout to see if they look like they're trying to reach the map's upper-left corner.
(0035229)
Toady One   
2016-05-18 13:31   
I believe this was fixed 0000055:0000040.10, since they'll check where the opponent is now and run away from that instead of going NW. Feel free to re-open if they are still running north.