Page 1 of 1

Increase assembling machine productivity with infinite technology

Posted: Tue Dec 29, 2020 9:05 pm
by solmyr
Is it possible to increment the base productivity of assembling machines with an infinite technology?

My current understanding is that this is not possible because it can only be changed through read-only prototypes.

Thank you

Re: Increase assembling machine productivity with infinite technology

Posted: Wed Dec 30, 2020 8:16 am
by ickputzdirwech
solmyr wrote:
Tue Dec 29, 2020 9:05 pm
Is it possible to increment the base productivity of assembling machines with an infinite technology?
It is, as you said, not possible, because the prototype definitions are read only. You could try the following workaround however:

Create several copies of the assembling machine prototypes with increasing base_productivity in the data stage. Also create matching technologies. Then you can create a script in control lua, that on_research_finished replaces every assembling machine with the next tier. This doesn’t work infinitely of course, but depending on the research cost it pretty much will be.

Re: Increase assembling machine productivity with infinite technology

Posted: Fri Jan 01, 2021 3:03 pm
by solmyr
Could you provide an example or reference for how I would "replaces every assembling machine with the next tier"?

Thank you

Re: Increase assembling machine productivity with infinite technology

Posted: Fri Jan 01, 2021 4:48 pm
by solmyr
ickputzdirwech wrote:
Wed Dec 30, 2020 8:16 am
Then you can create a script in control lua, that on_research_finished replaces every assembling machine with the next tier.
Could you provide an example or reference for how I would "replaces every assembling machine with the next tier"?

Thank you

Re: Increase assembling machine productivity with infinite technology

Posted: Fri Jan 01, 2021 4:59 pm
by ptx0
solmyr wrote:
Fri Jan 01, 2021 3:03 pm
Could you provide an example or reference for how I would "replaces every assembling machine with the next tier"?

Thank you
see the code for Alien Loot Economy mod that does this with hypermodules.