Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 [2]

Author Topic: Wheelbarrow  (Read 2626 times)

sjaakwortel

  • Bay Watcher
    • View Profile
Re: Wheelbarrow
« Reply #15 on: March 20, 2010, 12:54:45 pm »

or we can make it really simple and give dwarves with a wheelbarrow a 2X speedboost (while hauling stuff)
Logged
Quote
Quote from: Greep on May 08, 2010, 07:55:20 pm
do dwarves move any slower when using the stairs?
Quote
Compared to falling? Yes.

Silverionmox

  • Bay Watcher
    • View Profile
Re: Wheelbarrow
« Reply #16 on: March 21, 2010, 05:12:32 am »

or we can make it really simple and give dwarves with a wheelbarrow a 2X speedboost (while hauling stuff)
That would be... strange. Why wouldn't they always be using a wheelbarrow then? Just increasing their capacity, especially for smaller items, would already be great.

Carried containers like baskets ought to function like a piece of clothing rather than a temporary stockpile: they would increase a dwarf's carrying capacity at the cost of occupying one grasping limb.

Dwarves ought to usurp jobs from other dwarves when filling containers. If Urist is filling his basket, he ought to pick up all similar items in the vicinity, even if they have other dwarves coming to haul them.

This could also be considered for different items with the same job (most notably "move to stockpile". All the clothes and weapons of a few dead goblins would then be chucked in the wheelbarrow, and carted off to the neares relevant stockpile to drop off all the socks, then to the next closest one to drop off all the pants, etc.

Dwarves should use the rooms and zones the player defined as much as possible when determining which items are nearby. That would make more sense and avoid annoyances like a dwarf cleaning all the stone out of a room except a tile or two in the the lower left corner, because he happened to start in the upper right... while still moving through three corridors to pick up a stone in the adjoining room, leaving two rooms that aren't usable because they're still half filled with rubble.
Logged
Dwarf Fortress cured my savescumming.

sjaakwortel

  • Bay Watcher
    • View Profile
Re: Wheelbarrow
« Reply #17 on: March 21, 2010, 09:13:14 am »

let me explain my idea,
Stones are generally really big and at the moment not very realistic dwarf can carry them around like all other items. I think the first thing to do is making a difference between small and big objects (stones, blocks, barrels, bins, statue's......) no matter wat the weigth. Then give dwarfs a -25% speedbonus when carrying big objects without a wheel barrow and a +50% speedbonus with a wheelbarrow.
Small items would fit in a stack on a wheel barrow. but thats a bit hard to implent
Logged
Quote
Quote from: Greep on May 08, 2010, 07:55:20 pm
do dwarves move any slower when using the stairs?
Quote
Compared to falling? Yes.

zwei

  • Bay Watcher
  • [ECHO][MENDING]
    • View Profile
    • Fate of Heroes
Re: Wheelbarrow
« Reply #18 on: March 21, 2010, 10:37:54 am »

let me explain my idea,
Stones are generally really big and at the moment not very realistic dwarf can carry them around like all other items. I think the first thing to do is making a difference between small and big objects (stones, blocks, barrels, bins, statue's......) no matter wat the weigth. Then give dwarfs a -25% speedbonus when carrying big objects without a wheel barrow and a +50% speedbonus with a wheelbarrow.
Small items would fit in a stack on a wheel barrow. but thats a bit hard to implent

I'd make speed based on ratio of weight of carried items and of wheelbarrow.

For example, wheelbarrowing one earring sounds like it should be actually slower than just carrying it in hand as dwarf has to push additional weight around.

Basically, there should  be base weight of item where wheelbarrowing speed is equal to carrying by hand speed. If item weights more, wheelbarrowing speed is faster than carrying it by hand and thus dwarves will wheelbarrow it. And if weight is smaller than that, dwarves would carry it by hand.

---

AI for selecting multiple items is going to be weird, you would basically be solving traveling salesman problem if you want to allow wheelbarrow to move multiple items to multiple locations (i.e. allow wheelbarrower to fetch rocks for stone stockpile and ores for ore stockpile at same time) there is no efficient algorithm to implement it yet and if you deside to implement taking over TSKed items in huge fortress with many items that need to be moved around, well, good-bye, fps.

It does not need to be perfect, some proximity-based hacks are mentioned, but there is one huge issue: tasks for hauling are usually generated sequentially one-by-one. By time you end up having enough tasks to make wheelbarrowing worth it haulers are already on their way to items or ever already back with items. You mostly DO want that because hauling that result from crafting are not really common.

There are several events where several hauling tasks are generated at once:

 * New stockpile is designated or its setting was changed
 * Butcher butchers something, Crafter makes hand or foot wear, Mugs are made.
 * Something that carries stuff dies.
 * Someone puts bin/barrel on stockpile.
 * Player designated several things for dumping during game pause.
 * Trade session has ended/player marked goods to be traded.

Basically, any event where several hauling designations appear instantly (during one tick) These events are perfect for very simple wheelbarrow/carried bin ai because it means that there is either one-tile destination or one-tile source (or both).

Conveniently, these events are also the events where you DO want wheelbarrows.

Each of these events should trigger "wheelbarrow ai" which then uses basic traveling salesman algorithm which is now going to be on very limited source item set (i.e., only clothing of one dead goblin or only 9 stones for new stone stockpile, only those 100 narrow items bound for trade depot.). and destination set. Without any sidetracking issues that needlessly complicate it.
Pages: 1 [2]