Page 1 of 1

Prevent bot upgrades to apply to mod-bots?

Posted: Wed May 17, 2017 10:42 pm
by TheOddler
I've created a simple mod that adds early-game bots. They are to be worse versions of the later bots. The main thing that would make them worse it that they don't enjoy upgrades. However, I couldn't find how to prevent the new bots from getting those upgrades, so they can never carry more than 1 item, and don't get faster. Does anyone know how to do this?

Thanks!

Re: Prevent bot upgrades to apply to mod-bots?

Posted: Thu May 18, 2017 7:47 pm
by kikker450
I've never experimented with that but either a research applies a permanent modifier or permanently changes stats. In either case you have to replace all entities and recipes every time research is done with the old stats to keep them outdated.

And looking at the raw files always helps: (Factorio\data\base\prototypes\technology\technology.lua and Factorio\data\base\prototypes\entity\entities.lua)

Re: Prevent bot upgrades to apply to mod-bots?

Posted: Sun Sep 03, 2017 3:08 pm
by TheOddler
It looks like the upgrades use a modifier, when I look in `Factorio\data\base\prototypes\technology\technology.lua` there are several technoligies with as effect:

Code: Select all

    effects = {
      {
        type = "worker-robot-speed",
        modifier = 0.35
      }
    }
Any idea how to prevent the effect of this on my early-game bots?

Re: Prevent bot upgrades to apply to mod-bots?

Posted: Mon Sep 04, 2017 8:21 am
by bobingabout
The only way to make this not apply, is to make the bot something other than a logistic or construction robot, which will also prevent it from performing the task you want it to do.

Re: Prevent bot upgrades to apply to mod-bots?

Posted: Mon Sep 04, 2017 8:27 am
by TheOddler
bobingabout wrote:The only way to make this not apply, is to make the bot something other than a logistic or construction robot, which will also prevent it from performing the task you want it to do.
Shame :( Ahh well, I now just made them half as fast, which is really slow at the start but good enough for the beginning I guess.