From 7ce8342ac5c0e0a302559d3ef561ffd9dc74ff2c Mon Sep 17 00:00:00 2001 From: Rémi Verschelde Date: Mon, 1 May 2017 17:44:52 +0200 Subject: Rename project file to "project.godot" Slimmed down variant from the reverted #8375. The rationale behind the name change is to give Godot's project file a unique extension (".godot") that can be registered on the OS to be associated with the Godot binary (OS registration not implemented here). This PR also adds the possibility to start the game or editor if launched with the project.godot passed as argument, which paves the way for allowing a similar behaviour on a double-click in the OS file manager (code originally by @Hinsbart). Closes #6915. --- editor/editor_file_system.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'editor/editor_file_system.cpp') diff --git a/editor/editor_file_system.cpp b/editor/editor_file_system.cpp index 2612a2af1..b7070ab5f 100644 --- a/editor/editor_file_system.cpp +++ b/editor/editor_file_system.cpp @@ -509,7 +509,7 @@ void EditorFileSystem::_scan_new_dir(EditorFileSystemDirectory *p_dir, DirAccess if (f.begins_with(".")) //ignore hidden and . / .. continue; - if (FileAccess::exists(cd.plus_file(f).plus_file("godot.cfg"))) // skip if another project inside this + if (FileAccess::exists(cd.plus_file(f).plus_file("project.godot"))) // skip if another project inside this continue; dirs.push_back(f); @@ -688,7 +688,7 @@ void EditorFileSystem::_scan_fs_changes(EditorFileSystemDirectory *p_dir, const int idx = p_dir->find_dir_index(f); if (idx == -1) { - if (FileAccess::exists(cd.plus_file(f).plus_file("godot.cfg"))) // skip if another project inside this + if (FileAccess::exists(cd.plus_file(f).plus_file("project.godot"))) // skip if another project inside this continue; EditorFileSystemDirectory *efd = memnew(EditorFileSystemDirectory); -- cgit v1.2.3-70-g09d2