Currently Online

Latest Posts

Topic: Multiple Carriers Speed Question

littlekatana
Avatar
Topic Opener
Joined: 2021-10-30, 16:43
Posts: 29
Ranking
Pry about Widelands
Posted at: 2021-10-31, 16:32

Hey everonye. Still learning the game..

I know there is a reason and a calculation in the code, but I can't figure out how having multiple carriers on a road increases the goods transportation speed. The goods have to travel the same distance no matter what, and the slopes / number of segments doesn't change, so I can't see how having more than one person do that carrying changes the speed. Can anyone explain?


Top Quote
Nordfriese
Avatar
Joined: 2017-01-17, 18:07
Posts: 1929
OS: Debian Testing
Version: Latest master
Ranking
One Elder of Players
Location: 0x55555d3a34c0
Posted at: 2021-10-31, 16:41

The carrying speed for each individual ware is the same, but multiple carriers speed up transportation as a whole when many wares are waiting to be carried between two flags.

Let there be two flags A and B connected by a flat 2-tiles road. Two wares are waiting at A to be carried to B.

If there's one carrier, he needs 1.8 s to go to A, 3.6 s to bring the first ware to B, 3.6 s to go back to A, 3.6 s to bring the second ware to B. In total it takes 12.6 seconds until the second ware has been transported.

If there are two carriers, they both go to A in 1.8 s, pick up one ware each, and go to B in 3.6 s each. It takes only 5.4 seconds until both wares are at B because now the two carriers work in parallel.

So the speed increase is gained by reducing the time wares are idly lying around on flags waiting for a carrier to pick them up. This is also why a second carrier is assigned only to roads with a high wares throughput – on roads with low traffic, this waiting time is already minimal, whereas on busy roads a lot of time is wasted waiting for a free carrier.


Top Quote
geokinkladze
Avatar
Joined: 2009-03-23, 14:09
Posts: 3
Ranking
Just found this site
Posted at: 2021-11-02, 20:25

Are you referring to having mules/donkeys/animals as a second carrier between two flags or splitting a road into smaller sections by having more flags?


Top Quote
littlekatana
Avatar
Topic Opener
Joined: 2021-10-30, 16:43
Posts: 29
Ranking
Pry about Widelands
Posted at: 2021-11-03, 23:31

> *geokinkladze wrote:*
>
> Are you referring to having mules/donkeys/animals as a second carrier between two flags or splitting a road into smaller sections by having more flags?

The latter. I believe Nordfriese answered my question. (where can I give rep?). I can then deduce that a single long road, with no arterial roads going out from it to other buildings, would not benefit from adding additional flags and carriers, as the speed of the carried items is not increased, but rather the wait time of the uncarried items is decreased in a given road network.

As a follow up... if I happen to have 1 long road, would it actually be a hindrance to future road developments to pre-divide the long road with flags? I have noticed that, when trying to connect a new road to a pre-existing road in a tight space, the new road wants to connect to the initial road at a flag point. I have found it impossible to connect the road *where I want to*, and only now understanding that that's because there is another flag too close by. Is this part of the game mechanics? I'm assuming a better way to do it would be to have space for flag divisions on longer roads, and when it comes time to connect an arterial road to it, to do so in the most natural/shortest/fastest point, understanding that the connection point will have a flag placed there.


Top Quote
hessenfarmer
Avatar
Joined: 2014-12-11, 23:16
Posts: 2646
Ranking
One Elder of Players
Location: Bavaria
Posted at: 2021-11-04, 09:25

A road is defined in widelands by its start and end flag. A flag can be placed at any field on the map with the limitation, that a minimum distance of 2 fields to any other flag need to be adhered to. The fields on the map are predefined according our coordinate system (see also https://www.widelands.org/documentation/geometry/)
As for one ware the speed might be the same the overall transportation speed of all wares is drastically increased by having as many flags on a road as possible. As the minimum distance is 2 fields all experienced players plan to have a road network of only roads having this length as any 3 field road would be a bottleneck in the transport system producing a major congestion over time.

Edited: 2021-11-04, 09:25

Top Quote
littlekatana
Avatar
Topic Opener
Joined: 2021-10-30, 16:43
Posts: 29
Ranking
Pry about Widelands
Posted at: 2021-11-15, 00:59

A follow up question is about the quickest route. I thought I had read something about this on the forum but I can't recall or find it.

My question is if there is a free route that is longer with carriers available to take the goods now, and a shorter route that has a backlog of items waiting at flags, which ones is preferred for a given item?


Top Quote
mxb2001
Avatar
Joined: 2019-05-20, 18:49
Posts: 243
OS: Linux
Version: 1.1
Ranking
Widelands-Forum-Junkie
Location: The land of the thirsty spider
Posted at: 2021-11-15, 02:15

littlekatana wrote:

A follow up question is about the quickest route. I thought I had read something about this on the forum but I can't recall or find it.

My question is if there is a free route that is longer with carriers available to take the goods now, and a shorter route that has a backlog of items waiting at flags, which ones is preferred for a given item?

I'm no expert (still figuring stuff out too) but I have had success at building bypass roads to get a backlog cleared.


--
To Boldly Go Where No Man Has Gone Before

Top Quote
hessenfarmer
Avatar
Joined: 2014-12-11, 23:16
Posts: 2646
Ranking
One Elder of Players
Location: Bavaria
Posted at: 2021-11-15, 11:02

AFAIK routing is based on a cost function, which takes the wares at a flag into account. So if there are multiple wares waiting at the flags on the shorter route the cost might increase until the longer route becomes "cheaper" then the shorter route.


Top Quote