forked from mirror/OpenTTD
Fix #8833: don't reload NewGRFs when we are shutting down
Otherwise that might cause calls to the video-driver, which are already shut down by now. This causes, depending on the video-driver crashes or weird effects.
This commit is contained in:
committed by
Patric Stout
parent
afadae6d50
commit
14b61bfa6f
@@ -663,7 +663,7 @@ struct NewGRFWindow : public Window, NewGRFScanCallback {
|
|||||||
DeleteWindowByClass(WC_TEXTFILE);
|
DeleteWindowByClass(WC_TEXTFILE);
|
||||||
DeleteWindowByClass(WC_SAVE_PRESET);
|
DeleteWindowByClass(WC_SAVE_PRESET);
|
||||||
|
|
||||||
if (this->editable && !this->execute) {
|
if (this->editable && !this->execute && !_exit_game) {
|
||||||
CopyGRFConfigList(this->orig_list, this->actives, true);
|
CopyGRFConfigList(this->orig_list, this->actives, true);
|
||||||
ResetGRFConfig(false);
|
ResetGRFConfig(false);
|
||||||
ReloadNewGRFData();
|
ReloadNewGRFData();
|
||||||
|
Reference in New Issue
Block a user