Fix issue causing the project manager to crash because of missing path argument
In the process, the initialization logic is updated to show an error message and gracefully close the engine when setup errors occur.
This commit is contained in:
parent
337e4d185a
commit
cd544fd86b
8 changed files with 54 additions and 23 deletions
|
|
@ -3256,8 +3256,12 @@ void EditorNode::_discard_changes(const String &p_str) {
|
|||
for (const String &a : Main::get_forwardable_cli_arguments(Main::CLI_SCOPE_TOOL)) {
|
||||
args.push_back(a);
|
||||
}
|
||||
args.push_back("--path");
|
||||
args.push_back(exec.get_base_dir());
|
||||
|
||||
String exec_base_dir = exec.get_base_dir();
|
||||
if (!exec_base_dir.is_empty()) {
|
||||
args.push_back("--path");
|
||||
args.push_back(exec_base_dir);
|
||||
}
|
||||
args.push_back("--project-manager");
|
||||
|
||||
Error err = OS::get_singleton()->create_instance(args);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue