Better blueprints idea - auto upgrade/downgrade

This is the place to request new mods or give ideas about what could be done.
thelordodin
Fast Inserter
Fast Inserter
Posts: 168
Joined: Fri Jan 06, 2017 1:54 am
Contact:

Better blueprints idea - auto upgrade/downgrade

Post by thelordodin »

Idea on an example:
1. You place some blueprint with fast inserters.
2. This logistic network doesn't have fast inserter, but it has simple yellow ones
3. A special notification asks you if you want to wait or downgrade now? You confirm...
4. The mod replaces fast inserters with yellow ones
5. And after robots have placed yellow- emulate using upgrade planner on them - so they'll become fast once fast is available

Key differences:
- This mod is very different auto upgrading mods that lets you just upgrade all the base to next tier.
-- Because you wouldn't want to store your blueprints in lowest tier, would you?

So this way:
- One wouldn't need to downgrade your blueprints for early game manually.
- Having auto upgrade when ready - is quite a nice feature
- If you have built many self-growing space platforms* you'll might notice it's very needed

Other features good to have in mod:
- Auto downgrade toggle near toolbar that disables that dialog on step 3
- Some option to have custom upgrades defined
- Add all other entity types that include at least:
-- All inserters
-- All pipes - needs to check undeground length before downgrading
-- All belts, splitters, loaders - needs to check undeground length before downgrading
-- Assembly machines - need to check for fluid input before downgrading
-- Electric poles of same size

----------
*Self-growing space platforms - by that I mean you put a platform with just 1-2 rockets on staff with it. And a "Compact processor" (see mods) with kind of AI that can produce almost anything on a single assembler and single electric furnace. Than I just wait/build some other platforms and come back after say an hour to that platform finding that it already have produced lots of scaffolding by itself and at least some basic inserters, asseblers, etc...
User avatar
BraveCaperCat
Filter Inserter
Filter Inserter
Posts: 477
Joined: Mon Jan 15, 2024 10:10 pm
Contact:

Re: Better blueprints idea - auto upgrade/downgrade

Post by BraveCaperCat »

Sadly, there isn't an event that fires when a blueprint is placed, so I don't think this is possible.
Creator of multiple mods, including Quality Assurance - My most popular one.
Go check them out with the first and second links!
I'll probably be wanting or giving help with modding most of the time I spend here on the forum.
thelordodin
Fast Inserter
Fast Inserter
Posts: 168
Joined: Fri Jan 06, 2017 1:54 am
Contact:

Re: Better blueprints idea - auto upgrade/downgrade

Post by thelordodin »

I don't know for details (which is why I don't implement it myself), but there are mods that do trigger on blueprint placement.
Notable example is: https://mods.factorio.com/mod/belt-turner

I've tried to look into it... well... lots of code, but only one event:
script.on_event(defines.events.on_pre_build, on_pre_build)
User avatar
BraveCaperCat
Filter Inserter
Filter Inserter
Posts: 477
Joined: Mon Jan 15, 2024 10:10 pm
Contact:

Re: Better blueprints idea - auto upgrade/downgrade

Post by BraveCaperCat »

thelordodin wrote: Wed Nov 05, 2025 5:44 am I don't know for details (which is why I don't implement it myself), but there are mods that do trigger on blueprint placement.
Notable example is: https://mods.factorio.com/mod/belt-turner

I've tried to look into it... well... lots of code, but only one event:
script.on_event(defines.events.on_pre_build, on_pre_build)
Ah, I didn't notice the on_pre_build event. Probably because it didn't have "blueprint" or even "entity" in the name. I guess it would be possible then.
Creator of multiple mods, including Quality Assurance - My most popular one.
Go check them out with the first and second links!
I'll probably be wanting or giving help with modding most of the time I spend here on the forum.
Natha
Filter Inserter
Filter Inserter
Posts: 300
Joined: Sun Mar 15, 2015 1:48 pm
Contact:

Re: Better blueprints idea - auto upgrade/downgrade

Post by Natha »

I'd be interested in (co-)developing such a mod. My idea is to provide a dialog upon placement, if one of the entities is not available in the logistic network. Then for each of those entities (maybe also include a check if available entities >= amount needed), show possible candidates to replace with - upgrades and downgrades.
What could be a good name of the mod?
Natha
Filter Inserter
Filter Inserter
Posts: 300
Joined: Sun Mar 15, 2015 1:48 pm
Contact:

Re: Better blueprints idea - auto upgrade/downgrade

Post by Natha »

I created the mod. It was not as complex as I initially thought:
https://mods.factorio.com/mod/blueprint-auto-downgrade
User avatar
BraveCaperCat
Filter Inserter
Filter Inserter
Posts: 477
Joined: Mon Jan 15, 2024 10:10 pm
Contact:

Re: Better blueprints idea - auto upgrade/downgrade

Post by BraveCaperCat »

Natha wrote: Tue Dec 30, 2025 1:47 pm I created the mod. It was not as complex as I initially thought:
https://mods.factorio.com/mod/blueprint-auto-downgrade
I think I actually saw the mod before you told us about it. : )
I certainly saw the mod before I read your message, of course.
Creator of multiple mods, including Quality Assurance - My most popular one.
Go check them out with the first and second links!
I'll probably be wanting or giving help with modding most of the time I spend here on the forum.
User avatar
Stargateur
Filter Inserter
Filter Inserter
Posts: 378
Joined: Sat Oct 05, 2019 6:17 am
Contact:

Re: Better blueprints idea - auto upgrade/downgrade

Post by Stargateur »

I thinked of this when doing a mod. The problem is that entity "upgrade" is not always a compatible upgrade, specially underground belt, if you paste a blueprint that do underground belt spaghetti, and downgrade all of them to the same underground tier the blueprint will not work. Also range of underground belt or modded pipe. Or use burner inserter instead of electric inserter, does steam engine work when steam is too hot ? I never tried lol. The more I play the more I think "next_upgrade" is a bait. Also mix it with quality and that even harder, how to judge if an entity tier 2 is better than a legendary tier 1 ? And finally, one or more entities could have the same next_upgrade, how to choice between them ?
Natha wrote: Tue Dec 30, 2025 1:47 pm I created the mod. It was not as complex as I initially thought:
https://mods.factorio.com/mod/blueprint-auto-downgrade
I would suggest to instead of doing it automatically, use a selection tool to let user manually select entities he want to temporally downgrade if there are a ghost that can't be build with current item in network.
Natha
Filter Inserter
Filter Inserter
Posts: 300
Joined: Sun Mar 15, 2015 1:48 pm
Contact:

Re: Better blueprints idea - auto upgrade/downgrade

Post by Natha »

Stargateur wrote: Sat Jan 03, 2026 12:18 am I thinked of this when doing a mod. The problem is that entity "upgrade" is not always a compatible upgrade, specially underground belt, if you paste a blueprint that do underground belt spaghetti, and downgrade all of them to the same underground tier the blueprint will not work. Also range of underground belt or modded pipe.
The underground length thing is implemented (as suggested by the creator of the post). The speghetti thing is indeed one I didn't think of, but shouldn't be hard to avoid.
Or use burner inserter instead of electric inserter, does steam engine work when steam is too hot ? I never tried lol. The more I play the more I think "next_upgrade" is a bait. Also mix it with quality and that even harder, how to judge if an entity tier 2 is better than a legendary tier 1 ? And finally, one or more entities could have the same next_upgrade, how to choice between them ?
Burner inseretr does not have a next_target set in vanilla for exact that reason presumably.
I don't think that multiple entities can have the same next_target, because the upgrade planner can downgrade too.
The quality issue shows what this mod actually is: Not for choosing the best suitable, but available entity, just quick but in some cases dirty approach. But for players using blueprints across different games it can be a good choice.
I would suggest to instead of doing it automatically, use a selection tool to let user manually select entities he want to temporally downgrade if there are a ghost that can't be build with current item in network.
How does that differ from a custom defined upgrade planner? Only do the up/downgrade on entities that can't be delivered?
Post Reply

Return to “Ideas and Requests For Mods”