Allow disabling player online autosaves (#971)

This commit is contained in:
Floze authored and GitHub committed 2026-08-14 10:24:15 +01:00
1 parent 03f2616f30
commit 0be4fd77e5
3 files changed
+11 -1

No files matched your search

+1 -1
View File
@@ -575,7 +575,7 @@ export class InstanceConfig extends classes.Config<InstanceConfigFields> {
validator: function(value, config) {
const factorioSettings = config.get("factorio.settings");
const autosaveSlots = factorioSettings.autosave_slots;
if (typeof autosaveSlots === "number" && value < autosaveSlots) {
if (value !== 0 && typeof autosaveSlots === "number" && value < autosaveSlots) {
throw new Error("Value cannot be less than the number of autosave slots");
}
},