mirror of
https://github.com/godotengine/godot.git
synced 2024-11-27 09:16:35 +08:00
Merge pull request #26150 from akien-mga/export-error-message
Improve error message on project export failure
This commit is contained in:
commit
2985eabc7f
@ -972,10 +972,15 @@ void ProjectExportDialog::_export_project_to_path(const String &p_path) {
|
||||
|
||||
Error err = platform->export_project(current, export_debug->is_pressed(), p_path, 0);
|
||||
if (err != OK) {
|
||||
error_dialog->set_text(TTR("Export templates for this platform are missing/corrupted:") + " " + platform->get_name());
|
||||
if (err == ERR_FILE_NOT_FOUND) {
|
||||
error_dialog->set_text(vformat(TTR("Failed to export the project for platform '%s'.\nExport templates seem to be missing or invalid."), platform->get_name()));
|
||||
} else { // Assume misconfiguration. FIXME: Improve error handling and preset config validation.
|
||||
error_dialog->set_text(vformat(TTR("Failed to export the project for platform '%s'.\nThis might be due to a configuration issue in the export preset or your export settings."), platform->get_name()));
|
||||
}
|
||||
|
||||
ERR_PRINTS(vformat("Failed to export the project for platform '%s'.", platform->get_name()));
|
||||
error_dialog->show();
|
||||
error_dialog->popup_centered_minsize(Size2(300, 80));
|
||||
ERR_PRINT("Failed to export project");
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user