Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 2 [3] 4 5 ... 7

Author Topic: Stockpile Hacks: The Undump  (Read 59685 times)

silverskull39

  • Bay Watcher
    • View Profile
Re: Stockpile Hacks: The Undump
« Reply #30 on: August 31, 2011, 11:41:31 am »

Intriguing.... with this trick you could make a "pantry" for a kitchen. I think I'll be using this in my next fort.
Logged
Quote
Quote
Quote
Dwarf fortress threads can sound so.... unethical
it would be unethical if this wasn't the bay12 forums
Bay12: A short, sturdy forum fond of !!science!! and derailment.
Quote
Now back to your regularly scheduled thread derailment.

Musashi

  • Bay Watcher
  • cancels Work: distracted by Dwarf Fortress.
    • View Profile
Re: Stockpile Hacks: The Undump
« Reply #31 on: August 31, 2011, 11:49:30 am »

I'll definitely be using this in my next fortress. Thanks a lot!  :D
Logged
I don't mean to alarm you, but it appears that your Dwarves are all in fact elephants.

Reelyanoob

  • Bay Watcher
    • View Profile
Re: Stockpile Hacks: The Undump
« Reply #32 on: August 31, 2011, 12:10:15 pm »

Nil this design rocks I love stuff like this, watching this thread
Logged

MagmaMcFry

  • Bay Watcher
  • [EXISTS]
    • View Profile
Re: Stockpile Hacks: The Undump
« Reply #33 on: August 31, 2011, 03:26:41 pm »

This is so mindbreakingly beautiful, omg my brain its coming out i have to finish this sentencqsfrfsgdetmvaflgfhzjnhgfvcdbvhlmkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
Logged

Di

  • Bay Watcher
    • View Profile
Re: Stockpile Hacks: The Undump
« Reply #34 on: August 31, 2011, 03:27:55 pm »

I knew the trouble was coming when Nil said that he had done it with superfast dwarves. This setup jams indeed, more often with stone, less often with bones.
There might be a bunch of solutions for that:
1. First, most dwarfy one, is acknowledgement of the fact this setup depends greatly on selection of your haulers. So, go to the nearby thread and use that knowledge to sort out slowpokes from your haulers guild. ;)
2. Make delay device: plate opens a hatch that drops water/invader/animal onto another plate which in turn opens the hatch blocking path to stockpile. Try making a pen over delay hatch and assigning non-grazer animal to it.
3. Might try longer setup and a grate instead of hatch.
4. Jams can be smoothed a bit if you put secondary stockpile next to a plate and set undumper to take items from it.

My fort crashed before I could try out first three so I call upon other scientists to find out which way is better.
Finally, I'd like to admit that this device stabs fps right into a heart every time it is triggered, and all haulers will lag when one of them triggers it, so it's better to have several for one worker than one for ten. Yet still I'd recommend following this advice:
You could possibly encourage better framerate by adding a hatch on the outside of the pressure plate, so that when the dwarf re-paths it will only cover like 2 squares
For 2, fps-saving hatch should be linked to initial plate (the only one in original layout). For 3, you'll need another pair of grate and plate. Make sure that exit path is opened before path to a stockpile so dwarves wouldn't finish the job.
Logged
Quote from: Creamcorn
Dwarf Fortress: Where you meet the limit of your imagination, moral compass, sanity and CPU processor.
http://www.bay12forums.com/smf/index.php?topic=103080.0 Fix sober vampires!
http://www.bay12forums.com/smf/index.php?topic=91442.0 Dwarven Cognitive Science

Nil Eyeglazed

  • Bay Watcher
    • View Profile
Re: Stockpile Hacks: The Undump
« Reply #35 on: August 31, 2011, 03:34:31 pm »

I've changed my testing environment after realizing speed affects this.

When exactly dwarf cancels job? When the hatch opens or when he reaches open hatch? This may need some tuning like building order (I believe plate built after the hatch will take one step longer to close it, but better consult wiki on this matter).
Also this can be solved by second such stockpile.

Unfortunately, hatches always open at 0, regardless of build order ( http://mkv25.net/dfma/movie-2363-timingdetails )

Job cancellation seems to happen at different times.  Sometimes, it happens when the dwarf steps on the plate.  Most of the time, it happens when the dwarf reaches the open space.  I think dwarves probably re-evaluate their pathing at certain intervals, and if they happen to reevaluate it when they step on the plate, then they drop the object there.  (In fact, we could get a good picture of how often they evaluate their pathing just by looking at the ratio of items on the stockpile to the ratio of items on the pressure plate-- interesting potential for science there.)

But yeah, I've doing some testing right now with feeder stockpiles.  It seems to work well.  Hard to be sure though.  At least, hauling hasn't stopped with the odd one dropped on a pressure plate.  It might be a situation where orientation or the order in which you create stockpiles has an effect-- not sure when an object on a pressure plate will be designated for hauling to the feeder stockpile and when it'll be designated for hauling to the undump.

In any case, what I'm seeing is that they're a little too slow to function as raw material feed or anti-clutter.  However, what they should do well is maintain open spaces on existing stockpiles when set to "take-from."  So I think they work best in conjunction with an existing stockpile.  That keeps a constant minimum level of hauling via the undump, and keeps a good backup supply of raw materials, a supply that can be filled quickly.

If you've got your production chain totally ironed out so that your stockpiles always have 1 open space, then the undump won't do anything good for you.

Mine seems to be malfunctioning. I'm not entirely sure what I did wrong, but everything is just getting dumped on the pressure plate, rather than in the stockpile. I even tried changing from a north-south oriented version to a west-east, like the original diagram. Any suggestions?

Everything?  That's interesting-- most of my stuff, even now that I've changed back to default-ish dwarves, is getting dropped on the stockpile.  I don't know why that's happening to you, but if you can figure out why, then we could use that info to design a better version.

Orientation probably does matter, but I'm not sure how.  My original version was actually a south->north version (that is, the dwarf enters at the south and walks north towards the stockpile).  I'm testing 4 now, in all orientations, and now that you mention it, the ones where the dwarf travels from south to north and the one where the dwarf travels east to west have clear pressure plates, but that could just be an artifact.  I'll continue to observe.  In the meantime, maybe you should try making a near-by proxy stockpile and setting the undumps to take-from?  I'm not sure of how good of a solution it is, not yet, but we'll see.

I tried to build one, but its not working. I think that its something to do with how i did the pressure pad, because I linked a lever to the hatch and that worked, so what settings do i need on the pad? (Im fairly new to mechanics)

Pads need to be creatures trigger, citizens trigger, and then I just set the minimum weight to 1000 (the lowest possible: crundles, etc).  It's a lot of key presses for altering the weight, and I work with pressure plates a lot, so I made an autohotkey script for it.

So far, my refuse stockpile is mostly working, though I accidentally set the threshold on the pressure plates too low and let cats wander in to kill vermin, which take up stockpile space on the far side.

Lol, cats!  It's not the weight, it's that cats have trap avoid.  They don't trigger pressure plates.  That's a good point that'll limit the effectiveness of this.

Quote
On the other hand, none of my food stockpiles are generating stockpile requests on either side of the plate.  I've got an "E" shaped config, and all I've got is one empty barrel on the top right part of the "E."  (edit:  Never mind.  I had another food stockpile elsewhere that was taking higher priority despite a "take from" order.  Disabling it seems to have fixed the issue.)

As has been mentioned, be careful of barrels.  I believe that your dwarves will continually try to place a barrel in the unreachable square, leading sometimes to them going to pick up a barrel from the reachable side and getting stuck in a pointless hauling loop.

And later: The feeder stockpile works.  All goods, regardless of orientation, have been laid either on the feeder stockpile or on the undumps, with no goods on pressure plates.  That doesn't mean goods never land on pressure plates-- it means that even if they do, it'll work itself out if you use a feeder stockpile.
« Last Edit: August 31, 2011, 03:36:31 pm by Nil Eyeglazed »
Logged
He he he.  Yeah, it almost looks done...  alas...  those who are in your teens, hold on until your twenties...  those in your twenties, your thirties...  others, cling to life as you are able...<P>It should be pretty fun though.

Sphalerite

  • Bay Watcher
    • View Profile
    • Drew's Robots and stuff
Re: Stockpile Hacks: The Undump
« Reply #36 on: August 31, 2011, 03:41:15 pm »

Lol, cats!  It's not the weight, it's that cats have trap avoid.  They don't trigger pressure plates.  That's a good point that'll limit the effectiveness of this.

Interesting.  Cats don't have trap avoid, at least not though use of the TRAPAVOID tag.  Yet they don't trigger pressure plates.  I suspect that the maximum size of a cat is still below the minimum weight to trigger a pressure plate.  The pressure plate screen claims that you can set them down to 1000, which should be low enough, but I suspect that the actual limit is 10,000 and the weight selection screen is cutting off the last zero, or just outright lying.
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.

Nil Eyeglazed

  • Bay Watcher
    • View Profile
Re: Stockpile Hacks: The Undump
« Reply #37 on: August 31, 2011, 03:54:43 pm »

Lol, cats!  It's not the weight, it's that cats have trap avoid.  They don't trigger pressure plates.  That's a good point that'll limit the effectiveness of this.

Interesting.  Cats don't have trap avoid, at least not though use of the TRAPAVOID tag.  Yet they don't trigger pressure plates.  I suspect that the maximum size of a cat is still below the minimum weight to trigger a pressure plate.  The pressure plate screen claims that you can set them down to 1000, which should be low enough, but I suspect that the actual limit is 10,000 and the weight selection screen is cutting off the last zero, or just outright lying.

Huh.  I always believed that it was through the verminhunter tag, but the wiki doesn't say that.  Wiki's not necessarily correct or complete, of course.  I believe that in olden days, cats had trapavoid-- maybe it was just popular wisdom (more popular than wise).  But based on listed values (crundles are listed at the smallest plate weight, but they're 10k, twice the size of cats) I suspect you're correct.  Cool!  Learn something new every day.
Logged
He he he.  Yeah, it almost looks done...  alas...  those who are in your teens, hold on until your twenties...  those in your twenties, your thirties...  others, cling to life as you are able...<P>It should be pretty fun though.

Nil Eyeglazed

  • Bay Watcher
    • View Profile
Re: Stockpile Hacks: The Undump
« Reply #38 on: August 31, 2011, 05:18:12 pm »

Investigation 1: Throughput and efficiency

Dwarves: Dwarves have default speed (900).  They have no breathe, no eat, no drink tags, maybe a few others like that (shouldn't affect results, but full disclosure).
Population is 86 and 1 child.  Sufficient haulers exist such that there are always idlers to haul.
Military population is 10.  They're poorly trained.  Several dwarves have wounds, and there are no uber-dwarves.

Fortress: Meeting hall, where idlers will mostly congregate, is about 40 tiles from the door to the undump chamber.

Objects: We're using bar/block stockpiles.  My fortress contains 1991 bars or blocks that are unused and unforbidden.

Undump Facility:  Here's a color-coded picture of it.



Beginning state is empty undumps and a full 5x5 bar/block stockpile in the center of it.  At the beginning of summer (seasonal autosave + pause) the central stockpile was destroyed and 8 stockpiles were created: 4 undump stockpiles and 4 feeder stockpiles.  All feeder stockpiles were created after the undump stockpiles, but during the same pause.  It's color coded so you can see position and which stockpile feeds which undump.  I've labelled the north one to avoid confusion-- you can see that dwarves enter the north undump from the south, while they enter the south undump from the north.

Each undump is set to take from the associated feeder stockpile.

At the end of summer, the number of objects hauled and the number of job cancellations were counted.

Perfect hauls:  A perfect haul is a haul that delivers the object to the undump stockpile.

North: 46 perfect hauls
West: 31 perfect hauls
South: 42 perfect hauls
East: 45 perfect hauls

Adequate hauls: An adequate haul is a haul that delivers the object to the pressure plate of the associated undump.  These are adequate for clearing or feeding workshops, but food will rot on these squares, so that's why I distinguish between these two kinds of hauls.  Note that adequate hauls will be brought to the feeder stockpiles, so there may have been more adequate hauls than are documented.  Although feeder stockpiles are probably necessary for labor efficiency, these undocumented adequate hauls would still be valid hauls for certain purposes-- for instance, for feeding raw materials into a active workshop, or for uncluttering an active workshop.

North: 7 adequate hauls
West: 5 adequate hauls
South: 5 adequate hauls
East: 7 adequate hauls

Average perfect hauls per undump: 41
Average adequate hauls per undump: 6
Adequate hauls/Total hauls: 12.8%  This can be seen as potential food wastage.

Expected number of job cancellations due to drop-off inaccessible: 160 This requires a little explanation.  With so many idlers, all 8 of our undump squares will generate hauling labors when we start the clock.  We have 164 perfect hauls, but 4 of those hauling jobs won't create cancellations, because they are to accessible tiles.  We expect this spam only when dwarves successfully bring an object to a stockpile square.


Actual number of job cancellations due to drop-off inaccessible: 188  Dwarf should only get this cancellation when dropping an item on the stockpile square.  Not sure why it's higher than expected number.

Actual number of job cancellations due to path blocked: 144 This is tough to interpret as well.  Sometimes, a dwarf will report this cancellation instead of drop-off inaccessible, even when dropping on to the stockpile square.  I believe this is the spam when dropping onto the plate as well.

Expected cancellations as a percentage of total cancellations: 48.2%  This is a lower-bound estimate of labor efficiency.  It's extraordinarily rough right now, because I don't know where the cancellations are occurring-- if a dwarf cancels at the last minute with every cancellation, we have this number.  If the dwarf cancels the job earlier, we have a higher level of efficiency, potentially up to 100%.

EDIT: Have corrected some numbers and calculations, as well as grammar-- reasoning goes slow for me :)  Peer review (criticism) welcome as always; I make dumb mistakes all the time.

A second investigation (single dwarf, single undump, single feeder stockpile, only 15 bars available) led to 26 cancellations, and no plated bars.  It was using the northern undump only.  Watching the dwarf, he appeared to only cancel either at the end or beginning of his run, meaning that while I can't explain the extra cancellations, they appear to be 0-time cancellations-- immediate upon receiving the job.  That suggests good labor efficiency.

When I dumped one bar on to the pressure plate to test feeder functionality, the dwarf first moved it to the feeder stockpile, and from there back to the undump.

One dwarf tests are probably anecdotal at best.  Still, I feel confident about the use of a enters-from-the-south undump fed by a nearby feeder stockpile (1 tile works) that was built subsequent to the undump stockpile.  That's probably way more specific than I need to be, but just in case :)
« Last Edit: August 31, 2011, 06:42:02 pm by Nil Eyeglazed »
Logged
He he he.  Yeah, it almost looks done...  alas...  those who are in your teens, hold on until your twenties...  those in your twenties, your thirties...  others, cling to life as you are able...<P>It should be pretty fun though.

BigD145

  • Bay Watcher
    • View Profile
Re: Stockpile Hacks: The Undump
« Reply #39 on: August 31, 2011, 05:48:49 pm »

This whole topic is why I try to put a whole level, untouched, between every occupied level. If I don't need plumbing I need something else.
Logged

Nil Eyeglazed

  • Bay Watcher
    • View Profile
Re: Stockpile Hacks: The Undump
« Reply #40 on: August 31, 2011, 07:22:15 pm »

Very close. There's still the problem that multiple dwarves will try to use the same pressure plate/hatch hallway. This is what I'm going to use in my next fortress - my current designs in my current fortress were hard to design and build, but work like a charm once built so I'm not tearing them down.

Acetech, would you be willing to share your design?  It would be nice to see one designed by somebody else.
Logged
He he he.  Yeah, it almost looks done...  alas...  those who are in your teens, hold on until your twenties...  those in your twenties, your thirties...  others, cling to life as you are able...<P>It should be pretty fun though.

Wurgel

  • Bay Watcher
    • View Profile
Re: Stockpile Hacks: The Undump
« Reply #41 on: August 31, 2011, 08:23:52 pm »

if the jamming is a problem, couldnt you just use s slower lock like a door to prevent itemdropping on the presureplate and an increased Stockpilesize? Like:

PSSSSSSDS    P=plate, S=Stockpile, D=Door
Logged

Sphalerite

  • Bay Watcher
    • View Profile
    • Drew's Robots and stuff
Re: Stockpile Hacks: The Undump
« Reply #42 on: August 31, 2011, 08:27:17 pm »

Doors open when the attached pressure plate is stepped on.  A door won't work, because it will be closed by default, the stockpile will be inaccessible, and dwarves won't try to reach it.  Also, doors have the exact same timing as floor hatches.  Open instantly, close with a delay of 100 cycles.
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.

Valdrax

  • Bay Watcher
  • HUGE ELF (bluh bluh)
    • View Profile
Re: Stockpile Hacks: The Undump
« Reply #43 on: September 01, 2011, 09:07:37 am »

Well, I just tried this on a fort before it collapsed to an unrelated tantrum spiral.

In my experience, this creates a very jerky play experience with lots of stops and stutters as jobs get cancelled and dwarves attempt to pathfind.  As other posters have mentioned, many dwarves dump their goods on the pressure plate.  My attempt to build a wood stockpile this way also led to a string of dropped logs all over the path between the pile and outside from frequent use cutting off paths midway.

I had very mixed results with E-shaped stockpiles.  My food stockpile was so overloaded that dwarves managed to occasionally slip in all the way and drop off goods in the central pile.  Vermin corpses were also a problem with the setup, requiring me to play "no diagonal miasma" tricks.  I ended up having to build additional side doors into the Undumps to empty them out in emergencies.  This is not something you want to try with food stockpiles, since you can get food rotting in between shutting off the central food stockpile and clearing it off.  It's a good idea to designate a single-tile food stockpile as a dump zone nearby.

On the other hand, my E-shaped cloth stockpile was so inefficient at playing keep-away that single dwarves would become stuck in an infinite loop of trying hatch 1 (block), hatch 2 (block), hatch (block just as hatch 1 unblocks), etc. until a second dwarf stepped in and made it easy to close all 3 hatches at once.  Using multiple C-shaped stockpiles works better; more than that, and a dwarf won't be made to give up on trying to reach the empty pile.

In my opinion, this is an absolutely brilliant idea for putting certain materials near a workshop (say, for keeping magma-safe stone near your mechanic's shop).  However, for general use and mass storage, I think it works smoother to use normal stockpiles unless you are on an exceptionally wood-starved map and can't afford bins & barrels.
Logged
The history of a good fortress is not written in blood, it's painted on the walls by the hand of a melancholy orphan.

ZeroSumHappiness

  • Bay Watcher
    • View Profile
Re: Stockpile Hacks: The Undump
« Reply #44 on: September 01, 2011, 09:48:14 am »

Nil: How were your dwarves modded when you initially created this and it worked perfectly?  Were they [SPEED:0]?
« Last Edit: September 02, 2011, 09:05:42 pm by ZeroSumHappiness »
Logged
Pages: 1 2 [3] 4 5 ... 7