[Rseding91] [1.0.0] mod crash not recoverable
Posted: Wed Oct 21, 2020 9:14 pm
If a mod crashes on startup currently the only option is to disable that mod or disable all mods. If the crash only happens sometimes based on start up settings then you get locked out of that mod, you cannot enable the mod because of the crash and you cannot change the settings and stop the crash because you cannot get past the startup prosses to the settings menu. the end result is that is if you enter the wrong settings you get softlocked out of the mod unless you delete ALL your mod settings
minimal example:
a mod with a startup setting: crash-game
in data.lua
if crash-game == true
a = 1 + nil -- I think this crashes but not 100% sure
end
real examples:
Randtorio (https://mods.factorio.com/mod/randotorio) will crash on some seeds but not others
Custom Terrain Generation (https://mods.factorio.com/mod/ctg) allows lua code as input, invalid code will break it
Inproper error catching for some string settings with format other then what the mod expects
posable fix?
add an option for 'change settings' or 'open without gameplay option' or something like that. It would allow you to open the game with the Continue, single player, and multiplayer buttons grayed out so you could change settings even with invalid prototypes
minimal example:
a mod with a startup setting: crash-game
in data.lua
if crash-game == true
a = 1 + nil -- I think this crashes but not 100% sure
end
real examples:
Randtorio (https://mods.factorio.com/mod/randotorio) will crash on some seeds but not others
Custom Terrain Generation (https://mods.factorio.com/mod/ctg) allows lua code as input, invalid code will break it
Inproper error catching for some string settings with format other then what the mod expects
posable fix?
add an option for 'change settings' or 'open without gameplay option' or something like that. It would allow you to open the game with the Continue, single player, and multiplayer buttons grayed out so you could change settings even with invalid prototypes