Option to Reset mod settings at load fail.

Suggestions that have been added to the game.

Moderator: ickputzdirwech

Post Reply
User avatar
TatsuZZMage
Inserter
Inserter
Posts: 38
Joined: Thu Dec 29, 2016 1:26 am
Contact:

Option to Reset mod settings at load fail.

Post by TatsuZZMage »

So i was messing around with the MOD Quarry, and noticed its mod option allowed ya to set the power usage multiplier to 0 so i did, it gave a failed to load pwr usage can't be 0 msg on restart. Now i couldn't change the mod setting back to a working one, so i tried deleted the entry in the mod-settings.dat, and that crashed it(like i thought it would :lol:) SO idea a Revert to last mod settings or just a reset mod settings & restart button on the load failed screen.

User avatar
bobingabout
Smart Inserter
Smart Inserter
Posts: 7351
Joined: Fri May 09, 2014 1:01 pm
Contact:

Re: Option to Reset mod settings at load fail.

Post by bobingabout »

Well, you have the abillity to disable a mod on startup, I'd say that resetting related settings to defaults should be an option.

though, another way around it is if we had a LAUNCHER that could edit the settings. so not only would you be able to fix it in the launcher, but could also edit the settings without being in game in the first place.
Creator of Bob's mods. Expanding your gameplay since version 0.9.8.
I also have a Patreon.

bobucles
Smart Inserter
Smart Inserter
Posts: 1669
Joined: Wed Jun 10, 2015 10:37 pm
Contact:

Re: Option to Reset mod settings at load fail.

Post by bobucles »

Wait. So the mod LETS you choose a setting that immediately crashes? That sounds like a bug with the mod! If you are text editing at least that makes sense, since there isn't too much reason for a novice modder to sanity check their configs.

It would be nice to have an option to "restore mod defaults". If there are no defaults then at least an option to redownload or disable the mod. Or does that already exist? I haven't looked too heavily into it.

Rseding91
Factorio Staff
Factorio Staff
Posts: 13178
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Option to Reset mod settings at load fail.

Post by Rseding91 »

You can currently reset mod settings by deleting the mod-settings.dat file in the mods folder.
If you want to get ahold of me I'm almost always on Discord.

User avatar
bobingabout
Smart Inserter
Smart Inserter
Posts: 7351
Joined: Fri May 09, 2014 1:01 pm
Contact:

Re: Option to Reset mod settings at load fail.

Post by bobingabout »

Rseding91 wrote:You can currently reset mod settings by deleting the mod-settings.dat file in the mods folder.
Although true, that resets the settings of all mods, would be nice to reset the settings only of mods with an issue.
Creator of Bob's mods. Expanding your gameplay since version 0.9.8.
I also have a Patreon.

Rseding91
Factorio Staff
Factorio Staff
Posts: 13178
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Option to Reset mod settings at load fail.

Post by Rseding91 »

bobingabout wrote:
Rseding91 wrote:You can currently reset mod settings by deleting the mod-settings.dat file in the mods folder.
Although true, that resets the settings of all mods, would be nice to reset the settings only of mods with an issue.
That doesn't actually fix anything. Any mod can use any other mod(s) settings so you really never know what setting is causing what mod to error.
If you want to get ahold of me I'm almost always on Discord.

Jap2.0
Smart Inserter
Smart Inserter
Posts: 2339
Joined: Tue Jun 20, 2017 12:02 am
Contact:

Re: Option to Reset mod settings at load fail.

Post by Jap2.0 »

Rseding91 wrote:
bobingabout wrote:
Rseding91 wrote:You can currently reset mod settings by deleting the mod-settings.dat file in the mods folder.
Although true, that resets the settings of all mods, would be nice to reset the settings only of mods with an issue.
That doesn't actually fix anything. Any mod can use any other mod(s) settings so you really never know what setting is causing what mod to error.
Um, no. TatsuZZMage changed a power usage option in the settings for the quarry mod to 0, then was specifically told that power usage cannot be 0. I think that's pretty clear.
In addition to that, most mods tend to use their own settings, so unless you have a jungle of tightly intertwined dependencies, chances are there is one or a small number of possible mod settings which are causing the issue.
There are 10 types of people: those who get this joke and those who don't.

User avatar
Optera
Smart Inserter
Smart Inserter
Posts: 2915
Joined: Sat Jun 11, 2016 6:41 am
Contact:

Re: Option to Reset mod settings at load fail.

Post by Optera »

Rseding91 wrote:
bobingabout wrote:
Rseding91 wrote:You can currently reset mod settings by deleting the mod-settings.dat file in the mods folder.
Although true, that resets the settings of all mods, would be nice to reset the settings only of mods with an issue.
That doesn't actually fix anything. Any mod can use any other mod(s) settings so you really never know what setting is causing what mod to error.
Being able to reset the settings defined in a crashed mod certainly would help.
If other mods change values for a mod then both use bad practice of shared setting names.

dabalciunas
Inserter
Inserter
Posts: 23
Joined: Sat Apr 11, 2020 10:51 am
Contact:

Re: Option to Reset mod settings at load fail.

Post by dabalciunas »

Ok, this feature is urgently required.

It is so annoying and game-breaking, especially when I play with lots of mods, and 1 of them crashes, but I cannot fix its settings because Factorio won't let the mod load on startup.

So I have just 2 choices, both of them very unpleasant:

- Never load that mod again, because it would crash at startup every time, although it was just a simple wrong parameter given in the mod settings - which could be easily fixed if the modsettings.dat was a standard text file (e.g. JSON / XML)

- Reset the mod settings of over 25 mods

Now I can't simply continue my gameplay, until I adjust mod settings for over 25 mods. Thank you this terrible serialization design.

User avatar
jodokus31
Smart Inserter
Smart Inserter
Posts: 1599
Joined: Sun Feb 26, 2017 4:13 pm
Contact:

Re: Option to Reset mod settings at load fail.

Post by jodokus31 »

+1 to reset settings of a single mod

related:
viewtopic.php?f=34&t=59851

Squelch
Filter Inserter
Filter Inserter
Posts: 346
Joined: Sat Apr 23, 2016 5:31 pm
Contact:

Re: Option to Reset mod settings at load fail.

Post by Squelch »

Would a generic migration script work to set any given mod back to its defaults?

blahfasel2000
Inserter
Inserter
Posts: 49
Joined: Sat Mar 28, 2020 2:10 pm
Contact:

Re: Option to Reset mod settings at load fail.

Post by blahfasel2000 »

dabalciunas wrote:
Thu Sep 24, 2020 3:08 pm
So I have just 2 choices, both of them very unpleasant:
Assuming the crash happens in the data stage there's a third option, although it requires a bit more work (but no deeper understanding of Factorio modding needed):

Make a backup copy of the offending mods zip file, then delete data.lua, data-updates.lua and data-final-fixes.lua from the original zip. Start the game with the mod enabled. It won't crash this time because the data stage of the mod has been removed completely, so you can enter mod settings and change whatever setting causes the crash. Restore the mods zip file from the backup copy and restart. Done.

If the crash happens in the settings stage already, then it becomes more complicated, as you'd have to edit the mods settings stage lua code. This is unlikely though, as usually the settings stage only defines the mod settings available in the menu in a straightforward way and doesn't do anything else.

User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12888
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Re: Option to Reset mod settings at load fail.

Post by ssilk »

Generally I see that kind of requests at the side of the mod author. Because he/she forgot to handle this case.

Factorio or the user cannot guess what’s right in which case, as rseding said. It could be any parameter, not only those of the mod. You need to go deep inside of the mod to handle it correctly.
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...

User avatar
steinio
Smart Inserter
Smart Inserter
Posts: 2632
Joined: Sat Mar 12, 2016 4:19 pm
Contact:

Re: Option to Reset mod settings at load fail.

Post by steinio »

It's just about a new option aside disable listed mods and disable all mods which resets all mod options to default like the button in mod settings or like deleting mod-settings.dat.

I would not go that far that each mod should be resetable individually on an erroneous load.
Image

Transport Belt Repair Man

View unread Posts

dabalciunas
Inserter
Inserter
Posts: 23
Joined: Sat Apr 11, 2020 10:51 am
Contact:

Re: Option to Reset mod settings at load fail.

Post by dabalciunas »

steinio wrote:
Tue Sep 29, 2020 7:12 pm
It's just about a new option aside disable listed mods and disable all mods which resets all mod options to default like the button in mod settings or like deleting mod-settings.dat.

I would not go that far that each mod should be resetable individually on an erroneous load.
Actually, it is even simpler.

The game could simply make a backup of the previous mod settings. If the game fails to load, it restores the previous settings. So simple, so much benefit, almost no implementation cost.

Why encumber Factorio players with such a manual burden, when the solution is so simple ?!?

User avatar
steinio
Smart Inserter
Smart Inserter
Posts: 2632
Joined: Sat Mar 12, 2016 4:19 pm
Contact:

Re: Option to Reset mod settings at load fail.

Post by steinio »

dabalciunas wrote:
Wed Oct 14, 2020 10:51 am
steinio wrote:
Tue Sep 29, 2020 7:12 pm
It's just about a new option aside disable listed mods and disable all mods which resets all mod options to default like the button in mod settings or like deleting mod-settings.dat.

I would not go that far that each mod should be resetable individually on an erroneous load.
Actually, it is even simpler.

The game could simply make a backup of the previous mod settings. If the game fails to load, it restores the previous settings. So simple, so much benefit, almost no implementation cost.

Why encumber Factorio players with such a manual burden, when the solution is so simple ?!?
Hmm actually... Yeah.
Image

Transport Belt Repair Man

View unread Posts

User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12888
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Re: Option to Reset mod settings at load fail.

Post by ssilk »

dabalciunas wrote:
Wed Oct 14, 2020 10:51 am
Actually, it is even simpler.

The game could simply make a backup of the previous mod settings. If the game fails to load, it restores the previous settings. So simple, so much benefit, almost no implementation cost.

Why encumber Factorio players with such a manual burden, when the solution is so simple ?!?
What if the problem comes from a combination of things? Like changed setting of mod and then updated mod.
Or more complex: changed setting of mod A, then changed mod B, then changed mod C, which is not compatible with change of mod A.
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...

User avatar
Optera
Smart Inserter
Smart Inserter
Posts: 2915
Joined: Sat Jun 11, 2016 6:41 am
Contact:

Re: Option to Reset mod settings at load fail.

Post by Optera »

ssilk wrote:
Thu Oct 15, 2020 5:31 am
dabalciunas wrote:
Wed Oct 14, 2020 10:51 am
Actually, it is even simpler.

The game could simply make a backup of the previous mod settings. If the game fails to load, it restores the previous settings. So simple, so much benefit, almost no implementation cost.

Why encumber Factorio players with such a manual burden, when the solution is so simple ?!?
What if the problem comes from a combination of things? Like changed setting of mod and then updated mod.
Or more complex: changed setting of mod A, then changed mod B, then changed mod C, which is not compatible with change of mod A.
Error, circular incompatibility detected.
We already have something very similar if A requires B, B requires C and C requires A.

Hornwitser
Fast Inserter
Fast Inserter
Posts: 204
Joined: Fri Oct 05, 2018 4:34 pm
Contact:

Re: Option to Reset mod settings at load fail.

Post by Hornwitser »

ssilk wrote:
Thu Oct 15, 2020 5:31 am
What if the problem comes from a combination of things? Like changed setting of mod and then updated mod.
Or more complex: changed setting of mod A, then changed mod B, then changed mod C, which is not compatible with change of mod A.
Then include which mods were loaded too in previous configuration. Last working config = the set of mods (and their versions) that were successfully loaded along with their startup settings.

User avatar
jodokus31
Smart Inserter
Smart Inserter
Posts: 1599
Joined: Sun Feb 26, 2017 4:13 pm
Contact:

Re: Option to Reset mod settings at load fail.

Post by jodokus31 »

This is relevant:
viewtopic.php?p=517613#p517613

Probably solves the issue

Post Reply

Return to “Implemented Suggestions”