The International Simutrans Forum

 

Author Topic: r7028 Slow flow of goods  (Read 2592 times)

0 Members and 1 Guest are viewing this topic.

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5564
  • Languages: EN, NO
r7028 Slow flow of goods
« on: January 21, 2014, 05:58:15 AM »
I've started a new pak64 game and set up a line transporting grain from a farm to a brewery about 15 tiles apart. But the farm will only release enough grain load up one cart (10t) with grain at a time, despite the fact that the brewery has a free input capacity of 485 and the farm has full output storage. Only when the first cart has reached it's destination does the farm release grain to fill up the second cart. Behind the in-transit value at the brewery, there is an 8 in parenthesis.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9595
  • Languages: De,EN,JP
Re: r7028 Slow flow of goods
« Reply #1 on: January 21, 2014, 10:32:17 AM »
That happens for very little output storage of the farm and low in-transit percentage. What number did you set it to?

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5564
  • Languages: EN, NO
Re: r7028 Slow flow of goods
« Reply #2 on: January 21, 2014, 04:09:51 PM »
The farm has an output storage of 200. Production is 320 per month, which actually doesn't seem to keep up with what little is being delivered, as storage doesn't reach back up to 200 before next cart is loaded.

I haven't set any in-transit percentage, so it is at whatever the default is. The only thing changed in simuconf.tab is allow_buying_obsolete_vehicles.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9595
  • Languages: De,EN,JP
Re: r7028 Slow flow of goods
« Reply #3 on: January 21, 2014, 04:36:33 PM »
But then it seems your in-tranit is limited to 8, while output storage is 200. Hence in_transit percentage is then 4% which is not the default of 500%. Hmm, investigating.

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5564
  • Languages: EN, NO
Re: r7028 Slow flow of goods
« Reply #4 on: January 21, 2014, 05:20:47 PM »
I've checked just to be sure. The main simuconf.tab says 0 and pak64 says 500. I certainly don't have any spikes in demand.

Update:
I wonder if this is caused by some suppliers (not connected) being very far away. The map is 2048x2048. I've not been able to reproduce on any other map, but a random selection of industries all show the same symptom. Factory spacing is something I have tweaked a long time ago. That is perhaps saved in settings.xml?
« Last Edit: January 21, 2014, 08:31:04 PM by Ters »

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9595
  • Languages: De,EN,JP
Re: r7028 Slow flow of goods
« Reply #5 on: January 21, 2014, 11:12:42 PM »
Unless you activated something in your compile, factory distance does not enter. I created some maps and found no issues with in_transit limit (the second number for the in transit goods). There was however an issue with deleting suppliers.

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5564
  • Languages: EN, NO
Re: r7028 Slow flow of goods
« Reply #6 on: January 22, 2014, 06:28:44 AM »
I saw a TRANSIT_DISTANCE macro controlling an #if dealing with code setting max_menge. But I didn't see it in config.default (nor config.template), so I assume it's off.

But I have now noticed that maps are generated just fine. It's after saving and loading them again that the limits are messed up.

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5564
  • Languages: EN, NO
Re: r7028 Slow flow of goods
« Reply #7 on: January 22, 2014, 05:59:17 PM »
I think the revision number in the title is a bit low. I didn't do a complete rebuild, and the file containing the revision number was likely not recompiled, causing the game to display an older revision number. I have now done a clean rebuild (clean didn't delete the exe by the way), and the problem is still there at 7037. Fine before save, wrong after.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9595
  • Languages: De,EN,JP
Re: r7028 Slow flow of goods
« Reply #8 on: January 22, 2014, 09:49:18 PM »
ANyway, next nightly should cure the in_transit limiter when a game is reloaded.

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5564
  • Languages: EN, NO
Re: r7028 Slow flow of goods
« Reply #9 on: January 23, 2014, 05:30:54 AM »
Thanks. Now the flow is more or less back to how I'm used to it being. This wasn't code I was familiar with (which is still true for most of the simulation code). But here's a patch to stop a couple of warnings gcc spits out in relevant code.