The International Simutrans Forum

 

Author Topic: [r4771] Industry with several consumers always uses just in time  (Read 2609 times)

0 Members and 1 Guest are viewing this topic.

Offline mjhn

  • *
  • Posts: 39
Simple problem. If Just in time is turned off, and an industry has more than one consumer for the same product, then it behaves as if just in time is on.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 10828
  • Languages: De,EN,JP
Re: [r4771] Industry with several consumers always uses just in time
« Reply #1 on: August 13, 2011, 07:57:47 PM »
What do you mean? It will not distribute, if the halt in question is overcrowded, but it will distribute to overcrowded factories.

Offline mjhn

  • *
  • Posts: 39
Re: [r4771] Industry with several consumers always uses just in time
« Reply #2 on: August 14, 2011, 04:01:59 PM »
Under some circumstances the factory will not distribute to overcrowded factories in recent nightly builds where they will in 110.0.1.
Situations in which the factory does distribute:
Only one consumer for each product
All consumers are connected
At least on consumer is not an overcrowded factory (although the industry will only distribute to that consumer - this is the behvaiour of earlier versions, and I assume not a bug)

Requirements for situation where factory does not distribute (all of these need to be true for the bug to be seen)
Factory has multiple consumers for one product.
At least one consumer is connected to the factory.
At least one consumer is not connected to the factory.
All consumers that are connected to the factory have overcrowded inputs
At least one consumer that is not connected to the factory does not have an overcrowded input.

The only change in the options from the simuconf.tab that comes with the nightly build is that just in time is turned off

Offline Dwachs

  • DevTeam, Coder/patcher
  • Administrator
  • *
  • Posts: 4899
  • Languages: EN, DE, AT
Re: [r4771] Industry with several consumers always uses just in time
« Reply #3 on: August 14, 2011, 04:08:57 PM »
can you upload a savegame that shows this behavior?

Offline mjhn

  • *
  • Posts: 39
Re: [r4771] Industry with several consumers always uses just in time
« Reply #4 on: August 15, 2011, 08:26:18 PM »
Here you are
http://simutrans-germany.com/files/upload/test.sve
The coal mine near Appingville coal mine yard is not sending goods to the power station near  Baringby branch station when the power station is full, even though just in time is turned off.

I did a fresh download of the nightly build and the nightly pak64 to make sure that the problem was not due to my heavily modified simuconf.tab, so this is with build r4778 and pak64 build 521. The only modification from the standard simuconf.tab is that the copy inside the 'pak' folder has 'just_in_time = 1' replaced by 'just_in_time = 0'
I am running the linux/gcc4 build of simutrans.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 10828
  • Languages: De,EN,JP
Re: [r4771] Industry with several consumers always uses just in time
« Reply #5 on: August 15, 2011, 09:05:44 PM »
The logic was indeed broken. Now it will distribute to the lowest overcroding factory with a connection if just_in_time.