summaryrefslogtreecommitdiff
path: root/editor/project_manager.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'editor/project_manager.cpp')
-rw-r--r--editor/project_manager.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/editor/project_manager.cpp b/editor/project_manager.cpp
index da283b16dc..9c3b09608b 100644
--- a/editor/project_manager.cpp
+++ b/editor/project_manager.cpp
@@ -304,8 +304,9 @@ private:
ProjectSettings *current = memnew(ProjectSettings);
- if (current->setup(dir, "")) {
- set_message(TTR("Couldn't get project.godot in project path."), MESSAGE_ERROR);
+ int err = current->setup(dir, "");
+ if (err != OK) {
+ set_message(vformat(TTR("Couldn't load project.godot in project path (error %d). It may be missing or corrupted."), err), MESSAGE_ERROR);
} else {
ProjectSettings::CustomMap edited_settings;
edited_settings["application/config/name"] = project_name->get_text();
@@ -530,8 +531,9 @@ public:
ProjectSettings *current = memnew(ProjectSettings);
- if (current->setup(project_path->get_text(), "")) {
- set_message(TTR("Couldn't get project.godot in the project path."), MESSAGE_ERROR);
+ int err = current->setup(project_path->get_text(), "");
+ if (err != OK) {
+ set_message(vformat(TTR("Couldn't load project.godot in project path (error %d). It may be missing or corrupted."), err), MESSAGE_ERROR);
status_rect->show();
msg->show();
get_ok()->set_disabled(true);