Problem: If you take e.g. the Barbarians->Big-Inn you will find that this site can produce 3 kinds of products: ration, snack and meal. You will further find that producing a ration in a Tavern costs about 45 sec in time. Running the same cycle in a Big-Inn costs about 117 sec, which means a "penalty" of 77 sec for using the Big-Inn instead of the Tavern. I was bold enough to assume this is a bug and submitted a correction in my branch topple-sounds-4. With this correction in place, the penalty to use the Big-Inn is only 10 sec against the Tavern and 5 sec against the Inn.
If we look closer to what causes this problem, we find that the following script element the Snack
"return=skipped unless economy needs snack", "sleep=35000", "consume=barbarians_bread fish,meat beer", "produce=snack"
contains an unconditional sleep phase of 35 sec before evaluation takes place whether a complex production can take place resource-wise. This is the culprit!
- "return=skipped unless economy needs snack" returns immediately when there is no need for the product.
- "consume=barbarians_bread fish,meat beer" also returns immediately when there is not enough resources.
- the "sleep=35000" runs as a penalty
If the script is modified in the following way, the problem disappears, leaving only that amount of "misfit production site" penalty which was planned for, in this case 5 seconds.
"return=skipped unless economy needs snack", "sleep=5000", "consume=barbarians_bread fish,meat beer", "sleep=30000", "produce=snack"
If "consume" returns it breaks the entire procedure, hence the longer sleep time is omitted.
== Activity ==
I have supplied amendments for the Taverns, Inns and Big-Inns in my branch topple-sounds-4. Similar enhancements can - and I think: should - be applied to the Smelting-Works and various Weapon-Smithies (if they are multi-production-sites). I can prepare a branch for this in short time since I actually tested this in a private "data" version already. It works good! The question for the penalty, if there should be one and if yes, how high, is left to lead. ;) So when I get a "Go" from you here, I can do more about it!
What is left-over is the statistics for the production sites. E.g. if a smelting-works is running full charge with only producing Iron, it still will display only 65 % productivity or so, because of the "false" return from the Gold production cycle. This is bearable, maybe, but in the future one may think of relating productivity values more to time consumption than to production events. Cheers!