summaryrefslogtreecommitdiff
path: root/src/openttd.h
diff options
context:
space:
mode:
authorPatric Stout <truebrain@openttd.org>2020-12-13 16:28:06 +0100
committerGitHub <noreply@github.com>2020-12-13 16:28:06 +0100
commitc66bd18a1087d4b34d79faf68afb9ff8fea89be4 (patch)
tree8a6127387ff47514e586867238bfb3156140786a /src/openttd.h
parent40edc2863ccec78eac80ee2918188f1e1d605ce0 (diff)
downloadopenttd-c66bd18a1087d4b34d79faf68afb9ff8fea89be4.tar.xz
Add: save openttd.cfg immediately on changing a setting (#8358)
Formally it was only done on exit. This means that if it crashes changes in settings were not stored. This is often rather frustrating. Additionally, targets (like emscripten) where people are unlike to use "Exit Game", will never see their configuration stored. The drawback is that on every setting change there is some minor I/O of writing the ini file to disk again.
Diffstat (limited to 'src/openttd.h')
-rw-r--r--src/openttd.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/openttd.h b/src/openttd.h
index 664963a5d..61cff2456 100644
--- a/src/openttd.h
+++ b/src/openttd.h
@@ -51,6 +51,7 @@ enum DisplayOptions {
extern GameMode _game_mode;
extern SwitchMode _switch_mode;
extern bool _exit_game;
+extern bool _save_config;
/** Modes of pausing we've got */
enum PauseMode : byte {