News:

Simutrans Wiki Manual
The official on-line manual for Simutrans. Read and contribute.

When do new factories spawn ?

Started by missingpiece, December 29, 2011, 09:54:43 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

missingpiece

Hello again, helpful community !

I have started a map, unknowingly, with few industries. Now, I was wondering when new factories spawn. Incidentally, I found this parameter in my simuconf.tab, as you can see, it is switched off by default.

# when a city reaches 2^n times of this number
# then a factory is extended, or a new factory chain is spawned
# industry_increase_every = 2000

Is this parameter overwritten by my pak ? I am currently running the default pak(64) in game version 111. If so, do you know, at which sizes a new factory will be spawned ?

With all allowed newbness I need to ask : what does that parameter mean ? Because I do not understand the description. If the number was the exponent, and with that prewritten number 2000 there, as I understand it, then any of my cities would have to reach the size of the currently known universe and six parallel dimensions before I get a new factory....  ;D

And finally, does it make sense that I switch it on now ? Will it influence my existing game ? My cities have grown already, after all. So what will be the base for the spawn trigger calculation ?

Anyone able to elaborate ?

Combuijs

QuoteIs this parameter overwritten by my pak ?

The parameter has an in-build default value for new games and is overwritten by the general simuconf.tab, the pak specific simuconf.tab and the user-specified simuconf.tab. It is then stored in the savegame, and to my knowledge that's the only one that counts for that game from then on. You can change all in-game parameters, but that's not standard in pak64. You have to tweak your menuconf.tab to get access to that.

Quotewhat does that parameter mean ?

It used to mean that when the number of inhabitants on your map had grown with 2000 a new (part of a) factory chain was created in a random town. To be more exact: The last built end-factory (consumer only) was inspected and if one of the goods it consumed was not under contract from a producing factory it tried to complete a chain for that good by linking existing factories or building (and linking) new ones. If all goods were available under contract a new end-factory was built and a chain was built for its first consuming good.

However in 111.0 something has changed in this mechanism. I'm not sure why or how, but I am under the impression that extension now takes place at 2000, 4000, 8000, 16000, 32000 etc instead of 2000, 4000, 6000, 8000, 10000. That is what is meant with 2^n. The comment might be a bit confusing, but is actually right. Still don't know why this was done to be honest.

QuoteAnd finally, does it make sense that I switch it on now ? Will it influence my existing game ?

It does make sense for a new game, not for an existing game, to my knowledge.

missingpiece

Thanks for that. You know the code !  :police:

VS

The comment is "a bit misleading", as it states a mathematical formula with words instead of math... In fact, it's accurate.

Old way was,
industry_increase_every * n

Now it's
2^n * industry_increase_every

In other words, industry growth slows down, since cities have to reach exponential values, not linear.