You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-08 12:40:44 +00:00
Fix main scene not being saved when set via Play button
Fixes #1134 for real. Also tweaked the engine.cfg template and the preference order when browsing for the main scene.
This commit is contained in:
@@ -1429,7 +1429,7 @@ Globals::Globals() {
|
|||||||
|
|
||||||
set("application/name","" );
|
set("application/name","" );
|
||||||
set("application/main_scene","");
|
set("application/main_scene","");
|
||||||
custom_prop_info["application/main_scene"]=PropertyInfo(Variant::STRING,"application/main_scene",PROPERTY_HINT_FILE,"scn,res,xscn,xml,tscn");
|
custom_prop_info["application/main_scene"]=PropertyInfo(Variant::STRING,"application/main_scene",PROPERTY_HINT_FILE,"tscn,scn,xscn,xml,res");
|
||||||
set("application/disable_stdout",false);
|
set("application/disable_stdout",false);
|
||||||
set("application/use_shared_user_dir",true);
|
set("application/use_shared_user_dir",true);
|
||||||
|
|
||||||
|
|||||||
@@ -1175,6 +1175,8 @@ void EditorNode::_dialog_action(String p_file) {
|
|||||||
case SETTINGS_PICK_MAIN_SCENE: {
|
case SETTINGS_PICK_MAIN_SCENE: {
|
||||||
|
|
||||||
Globals::get_singleton()->set("application/main_scene",p_file);
|
Globals::get_singleton()->set("application/main_scene",p_file);
|
||||||
|
Globals::get_singleton()->set_persisting("application/main_scene",true);
|
||||||
|
Globals::get_singleton()->save();
|
||||||
//would be nice to show the project manager opened with the hilighted field..
|
//would be nice to show the project manager opened with the hilighted field..
|
||||||
} break;
|
} break;
|
||||||
case FILE_SAVE_OPTIMIZED: {
|
case FILE_SAVE_OPTIMIZED: {
|
||||||
|
|||||||
@@ -203,14 +203,15 @@ private:
|
|||||||
} else {
|
} else {
|
||||||
|
|
||||||
f->store_line("; Engine configuration file.");
|
f->store_line("; Engine configuration file.");
|
||||||
f->store_line("; It's best to edit using the editor UI, not directly,");
|
f->store_line("; It's best edited using the editor UI and not directly,");
|
||||||
f->store_line("; becausethe parameters that go here are not obvious.");
|
f->store_line("; since the parameters that go here are not all obvious.");
|
||||||
f->store_line("; ");
|
f->store_line("; ");
|
||||||
f->store_line("; Format: ");
|
f->store_line("; Format: ");
|
||||||
f->store_line("; [section] ; section goes between []");
|
f->store_line("; [section] ; section goes between []");
|
||||||
f->store_line("; param=value ; assign values to parameters");
|
f->store_line("; param=value ; assign values to parameters");
|
||||||
f->store_line("\n");
|
f->store_line("\n");
|
||||||
f->store_line("[application]");
|
f->store_line("[application]");
|
||||||
|
f->store_line("\n");
|
||||||
f->store_line("name=\""+project_name->get_text()+"\"");
|
f->store_line("name=\""+project_name->get_text()+"\"");
|
||||||
f->store_line("icon=\"res://icon.png\"");
|
f->store_line("icon=\"res://icon.png\"");
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user