View Issue Details

IDProjectCategoryView StatusLast Update
0002335Dwarf FortressDwarf Mode -- Militarypublic2010-08-11 23:43
ReporterCreidieki Assigned ToToady One  
PrioritynormalSeveritymajorReproducibilityalways
Status resolvedResolutionfixed 
Product Version0.31.06 
Fixed in Version0.31.11 
Summary0002335: Squad equipment permanently unusable after disbanding squad (with save)
DescriptionI've developed a minimal-test-case for getting one of the equipment bugs shortly after embarking. The resulting fortress has seven dwarfs, one military dwarf and one weapon; the dwarf refuses to equip the weapon. A save after the problems is included.

The short version seems to be "without closing the military screen, remove all dwarfs from a squad, then disband the squad. Their equipment will never be used again, even if you make a new squad with the same dwarfs".

Steps To Reproduce1) Start game with a (copper spear) and no other weapons.
2) Create a weapon stockpile; wait for the dwarfs to move the spear into it. (might not be necessary).
3) Create a squad with the "metal armor" uniform. Put one dwarf in it. (From the main game screen, press m, c, down, enter, right, right, enter, escape.
4) Wait for the dwarf to pick up the (copper spear).
5) Go to the military screen, and without closing it, remove the dwarf from his squad and disband the squad. (From the main game screen, press m, right, enter, left, d, escape).
6) Wait for the dwarf to put the (copper spear) back in the stockpile.
7) Create a new squad; the old militia commander will automatically be in it. (m, c, down, enter, escape).
8) The dwarf refuses to pick up the copper spear.


I've seen this bug in a lot of mature fortresses that have (otherwise functional) arsenal dwarfs. There are =steel breastplates= in the armor stockpiles, and the dwarfs end up wearing leather armor because they can't find anything metal. I haven't found a workaround (forbidding/reclaiming the items doesn't work, for example).
Additional InformationA save is at:
http://dffd.wimbli.com/file.php?id=2514

(This save actually includes two different weapons, a (copper spear) and a =copper spear=. The first time I created the squad, my dwarf equipped the =copper spear=. The second time, he ignored the good spear and took the (copper spear). I created the squad a third time, and now he won't equip either.
TagsSave Included

Relationships

child of 0000535 acknowledgedToady One Equipping weapons/armor on military is erratic 

Activities

Kyle_Solo

2010-06-15 05:50

reporter   ~0008496

Main equipment bug page: http://bay12games.com/dwarves/mantisbt/view.php?id=535

user6

2010-07-03 12:13

  ~0009584

Does this save still cause the problem in 31.08?

Creidieki

2010-07-06 16:18

reporter   ~0009699

Yup. The bug still reproduces with the given instructions in a new 31.08 fortress, and the save file still exhibits the bug when loaded in 31.08.

Toady One

2010-07-13 06:05

administrator   ~0010126

Yeah, it was skipping the equipment freeing code for empty positions on squad disband. It bailed on the whole loop pass when it failed to find a dwarf instead of just the unit cleaning stuff. This one should be fixed for 0.31.11.

Issue History

Date Modified Username Field Change
2010-06-15 03:21 Creidieki New Issue
2010-06-15 05:48 Kyle_Solo Tag Attached: Save Included
2010-06-15 05:50 Kyle_Solo Note Added: 0008496
2010-06-15 06:01 user6 Relationship added child of 0000535
2010-07-03 12:13 user6 Tag Attached: Save Needs Testing
2010-07-03 12:13 user6 Note Added: 0009584
2010-07-03 12:14 user6 Summary Reproducible equipment-bug save file => Squad equipment permanently unusable after disbanding squad (with save)
2010-07-06 16:18 Creidieki Note Added: 0009699
2010-07-13 06:05 Toady One Note Added: 0010126
2010-07-13 06:05 Toady One Status new => resolved
2010-07-13 06:05 Toady One Fixed in Version => 0.31.11
2010-07-13 06:05 Toady One Resolution open => fixed
2010-07-13 06:05 Toady One Assigned To => Toady One
2010-08-11 23:43 user11 Tag Detached: Save Needs Testing