From a23ffb82bbb62b38b6511063fd54e0408b2590c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Verschelde?= Date: Wed, 11 Jan 2017 22:38:00 +0100 Subject: [PATCH] Dehardcode version major in editor settings Follow-up on 7474fc133a268eae12b7b89307cb0482e3781820. --- ISSUE_TEMPLATE.md | 2 +- tools/editor/editor_settings.cpp | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ISSUE_TEMPLATE.md b/ISSUE_TEMPLATE.md index fcaaca627851..294acd5baeff 100644 --- a/ISSUE_TEMPLATE.md +++ b/ISSUE_TEMPLATE.md @@ -1,6 +1,6 @@ vvv Remove me vvv -*NOTE:* If you using the current master branch / 3.0-alpha version, do not that +*NOTE:* If you using the current master branch / 3.0-alpha version, do note that breakage is *expected*. Projects from Godot 2.x are expected not to work. Please wait for the upcoming stabilisation period to report bugs regarding recent changes. diff --git a/tools/editor/editor_settings.cpp b/tools/editor/editor_settings.cpp index e396ac1679cb..6b4b34fcacba 100644 --- a/tools/editor/editor_settings.cpp +++ b/tools/editor/editor_settings.cpp @@ -328,12 +328,12 @@ void EditorSettings::create() { // path at least is validated, so validate config file - - config_file_path = config_path+"/"+config_dir+"/editor_settings-3.tres"; + String config_file_name = "editor_settings-" + String(_MKSTR(VERSION_MAJOR)) + ".tres"; + config_file_path = config_path + "/" + config_dir + "/" + config_file_name; String open_path = config_file_path; - if (!dir->file_exists("editor_settings-3.tres")) { + if (!dir->file_exists(config_file_name)) { goto fail; }