diff options
author | rubidium <rubidium@openttd.org> | 2008-01-13 01:39:22 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2008-01-13 01:39:22 +0000 |
commit | 079abbd04be8e997a0d09eb89ad03884a4e12d00 (patch) | |
tree | 991113cabdf8f73af8334d2f01990b558f897f8b /src/openttd.cpp | |
parent | d4e6a6bf57216b39745b61971141e088e15e2d0d (diff) | |
download | openttd-079abbd04be8e997a0d09eb89ad03884a4e12d00.tar.xz |
(svn r11829) -Feature: allow reloading openttd.cfg when starting a new game on a dedicated server. Patch by dihedral.
Diffstat (limited to 'src/openttd.cpp')
-rw-r--r-- | src/openttd.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/openttd.cpp b/src/openttd.cpp index c3ee5e035..6df99dba1 100644 --- a/src/openttd.cpp +++ b/src/openttd.cpp @@ -843,6 +843,13 @@ void SwitchMode(int new_mode) if (_is_network_server) { /* But not if we are going to the menu */ if (new_mode != SM_MENU) { + /* check if we should reload the config */ + if (_network_reload_cfg) { + LoadFromConfig(); + _patches = _patches_newgame; + _opt = _opt_newgame; + ResetGRFConfig(false); + } NetworkServerStart(); } else { /* This client no longer wants to be a network-server */ |