Cargo Distribution

Forum for technical discussions regarding development. If you have a general suggestion, problem or comment, please use one of the other forums.

Moderator: OpenTTD Developers

User avatar
John
Tycoon
Tycoon
Posts: 3402
Joined: 05 May 2003 18:44
Location: Cotswolds, UK
Contact:

Re: Cargo Distribution

Post by John »

chickenbc wrote:It is impossible to load previous save file which is saved cargo ditribution r16284 in the latest build(r16422_2)?
And?

It is stated numerous times in this topic that backwards compatibility is not being maintained with save games.
I made quite complex train network and I want to test with latest version.
Then your only option is to start again!
User avatar
fonso
President
President
Posts: 948
Joined: 13 Oct 2007 08:28

Re: Cargo Distribution

Post by fonso »

Wasila wrote:Aah OK. So I have to put non-stop on all my routes, including with two-stop bus routes? This could take a while :P
There is a setting for new orders to be non-stop by default.
The guy on the picture is not me, it's Alonso.
Wasila
Tycoon
Tycoon
Posts: 1498
Joined: 15 Mar 2008 07:02

Re: Cargo Distribution

Post by Wasila »

Thanks. One more thing, in the 'Link Graph' settings it mentions Demand function for the EXPRESS/ARMOURED cargo class. What are these?
User avatar
fonso
President
President
Posts: 948
Joined: 13 Oct 2007 08:28

Re: Cargo Distribution

Post by fonso »

Armoured is valuables and gold. I don't know what express is, but somewhere it was stated that this can be used for mail or passengers by newgrfs.

I just discovered that ships and aircraft have useless nonstop flags in their orders which makes cargodist believe all their orders are nondeterministic. Fix is on the way.
The guy on the picture is not me, it's Alonso.
as
Transport Coordinator
Transport Coordinator
Posts: 281
Joined: 07 Mar 2007 20:13

Re: Cargo Distribution

Post by as »

Food, goods and sweets(from toyland) are in express cargo class.
Yuo can find for cargo classes for default ttd cargoes as well as ECS cargoes here.
fabca2
Transport Coordinator
Transport Coordinator
Posts: 312
Joined: 14 Apr 2004 15:18
Location: Fr

Re: Cargo Distribution

Post by fabca2 »

fonso wrote:Answers:

[*] fabca2: "unknown station" means that for some reason there is no planned flow for them. This can happen when you forcibly transfer things where they don't want to be transferred, when links disappear or when stations appear that don't have links so far. Give me a savegame and I'll tell you.
so fast answer !
here is a savegame,
you will see it's very simple : I do not "transfert" anything, it's just a simple passenger network, with 4 stations : A,B,X,Y. They are all accepting passengers, 3 busses :
- two busses with Orders : A and B
- one busse with Order : A, X and Y
I don't see any "forcing transfer" here.
if you open the samegame, open the station A, you will see :
Waiting : 232 passengers (32 to X, 183 to B, 17 to unknown)

Thank you.
Attachments
cargo test.sav
the savegame
(348.55 KiB) Downloaded 51 times
Pirate87
Engineer
Engineer
Posts: 4
Joined: 25 May 2009 14:53
Location: Poland

Re: Cargo Distribution

Post by Pirate87 »

Hi everyone !
I discovered cargodist a few days ago, and I have to say that I love it. Great work fonso ! Thanks a lot :)
Enough good stuff.
While playing today I run into some problems (some may come from my lack of expirience with cargodist):

While transporting mail I always have 'unknown station'. No matter how i transport it.
Same with valuables. But here it creates a problem with transfers, cause I can't establish a route between two banks
Bank1 near Airport 1 --- Airport 2 with Lorry station 1 --- Lorry station 2 near Bank 2).
It just works the same as without cargodist. Do I have to use some specific orders on a route like this ? I didn't try using transfer or unload orders, cause I read somewhere that in cargodist cargoes transfer automaticly. (btw i've noticed that for passengers it works fine)

Also at the begining of the game some plane routes (pretty long ones) where dissapearing. I think it was because of the low frequency the planes arrived at the airports. Does a change of link graph recalculation interval help in this case ?

I've attached a savegame in case I wasn't clear enough about something. I'm playing the binary that fonso posted yesterday.
Attachments
Filip Transport, 19th Mar 1975.sav
My savegame
(456.63 KiB) Downloaded 65 times
User avatar
fonso
President
President
Posts: 948
Joined: 13 Oct 2007 08:28

Re: Cargo Distribution

Post by fonso »

fabca2: I can't open your game. With which versions of trunk and cargodist did you create it?
The guy on the picture is not me, it's Alonso.
User avatar
fonso
President
President
Posts: 948
Joined: 13 Oct 2007 08:28

Re: Cargo Distribution

Post by fonso »

Pirate87: This is partly due to aircraft having useless nonstop flags and partly because your links are served so infrequently that they are timing out before cargodist can calculate a route. Wait for the next update and then set the moving average length to at least 256 if you have links like that.
The guy on the picture is not me, it's Alonso.
fabca2
Transport Coordinator
Transport Coordinator
Posts: 312
Joined: 14 Apr 2004 15:18
Location: Fr

Re: Cargo Distribution

Post by fabca2 »

fonso wrote:fabca2: I can't open your game. With which versions of trunk and cargodist did you create it?
Hello,
I used the version you gave a link on sat 23rd May (trunk r16407 )
http://fickzoo.com/fonsinchen/openttd-c ... -win32.zip
on ottd screen version is : "gOddaddf5 (no branch)"
I use only tram 0.4 grf.
Wasila
Tycoon
Tycoon
Posts: 1498
Joined: 15 Mar 2008 07:02

Re: Cargo Distribution

Post by Wasila »

That fix should be good...but non-stop orders have halved my train profits :(

Here's another one for you, fonso. Sometimes when my vehicles arrive at the station, especially buses, instead of 'Profit' I get 'Cost'. How can I spend money by delivering the goods? Thanks again.
User avatar
jklamo
Engineer
Engineer
Posts: 66
Joined: 30 May 2004 00:10
Contact:

Re: Cargo Distribution

Post by jklamo »

Nice patch :bow: It takes me some time (and patch revisions) to build a decent network. I am using precompiled r16284M version dowloaded from this thread. Now i have problem with strange crashes. They are just windows program crashes (so no crash log, dump or sav from openttd). If i load last autosave before crash, game works OK for years and than crash again. So i suspect some kind of buffer overflow. Sorry if that error was already fixed in current patch revision or is not patch related.
Attachments
crop.png
crop.png (2.42 KiB) Viewed 2635 times
autosave9.sav
(563.06 KiB) Downloaded 54 times
Pirate87
Engineer
Engineer
Posts: 4
Joined: 25 May 2009 14:53
Location: Poland

Re: Cargo Distribution

Post by Pirate87 »

fonso wrote:Pirate87: This is partly due to aircraft having useless nonstop flags and partly because your links are served so infrequently that they are timing out before cargodist can calculate a route. Wait for the next update and then set the moving average length to at least 256 if you have links like that.
Changing moving average lenght fixed the mail destinations problem.
With valuables I had to force unload on the transfer airport both for trucks and planes. But besides that it works fine.
Thanks.
Wasila wrote:... Sometimes when my vehicles arrive at the station, especially buses, instead of 'Profit' I get 'Cost'. How can I spend money by delivering the goods? Thanks again.
It's a flaw in OpenTTD transfer system. Not in the Cargodist itself. It's because of the way transfer credits and final delivery payments are calculated. You don't actually lose money. You just get more money from the transfers, than you would get for delivering the cargo all the way with one vehicle.
There were quite a few topics about it here.
http://www.tt-forums.net/viewtopic.php? ... nsfer+cost
User avatar
fonso
President
President
Posts: 948
Joined: 13 Oct 2007 08:28

Re: Cargo Distribution

Post by fonso »

New version in first post and git:
  • Fix: correctly load aircraft and ships.
  • Fix: crash when saving the linkgraph.
  • print "unrouted" instead of "unknown station" in the station GUI.
  • Raise the default moving average length again.
jklamo: This bug is solved in newer versions. Please upgrade.

fabca2: You have infrequently serviced links of low capacity. If you want them to be included in the cargo distribution you have to raise the moving average length. As multiple people seem to have issues with that I doubled the default value to 128. This won't work out in your case. You need about 512 to keep the links stable. Mind that a normal link will take about one and a half game years to time out with a moving average length that high.
The guy on the picture is not me, it's Alonso.
Wasila
Tycoon
Tycoon
Posts: 1498
Joined: 15 Mar 2008 07:02

Re: Cargo Distribution

Post by Wasila »

As all my patching attempts have failed - could we have a binary?

Also I take it it's compatible with older save games?

Thanks again fonso and Pirate.
User avatar
Pizen
Engineer
Engineer
Posts: 4
Joined: 26 May 2009 05:48

Re: Cargo Distribution

Post by Pizen »

Odds are you're using the windows "version" of patch, and since that doesn't handle unix linefeeds (missing CR) very well - or at all - you'll need to change all LF (UNIX) to CRLF (DOS), by using something like unix2dos.

Or you could use the file I've attached, where this has already been done.
Attachments
cargodist_r16451_dos.diff
(188.02 KiB) Downloaded 65 times
Wasila
Tycoon
Tycoon
Posts: 1498
Joined: 15 Mar 2008 07:02

Re: Cargo Distribution

Post by Wasila »

Was that directed at me?
dbkblk
Traffic Manager
Traffic Manager
Posts: 154
Joined: 29 Mar 2008 18:38

Re: Cargo Distribution

Post by dbkblk »

Hi !
I use the same build as fabca2 with some GRF (around 10), the game is extremely instable while it haven't been a long one.
I've taken a screenshot of a non-fatal error i've got but it also crash randomly (Mainly Windows close the program without to tell anything else than "it crashed" or some memory errors) and when buying some vehicles (like the newest coal one of eGVTRS or the westwaggon from the german set):
Image

You can grab the exact build i'm playin with here: (The game is "autosave1" in the autosave directory / I have deleted the original TTD files to stay in the legality).
http://rapidshare.com/files/238169310/o ... rgodist.7z

Maybe theses crashs aren't linked with your build but i'm not enough skilled to find them !
Thanks you for your work !
H.
User avatar
fonso
President
President
Posts: 948
Joined: 13 Oct 2007 08:28

Re: Cargo Distribution

Post by fonso »

dbkblk: Both problems are unrelated to cargodist. The problem with building the coal vehicle has been solved in trunk by now. The other crash is due to an invalid sound produced by the "Großer Hecht" tram. This shouldn't crash openttd, though. The devs have been informed about the problem.
The guy on the picture is not me, it's Alonso.
User avatar
fonso
President
President
Posts: 948
Joined: 13 Oct 2007 08:28

Re: Cargo Distribution

Post by fonso »

Windows binary of latest version: http://fickzoo.com/fonsinchen/openttd-c ... -win32.zip

Don't use the german road vehicle set if you don't want to get dbkblk's problem. There is already an update in trunk fixing this, but I haven't gotten around to updating cargodist accordingly.
The guy on the picture is not me, it's Alonso.
Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: No registered users and 22 guests