summaryrefslogtreecommitdiff
path: root/editor
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2021-11-24 13:54:20 +0100
committerGitHub <noreply@github.com>2021-11-24 13:54:20 +0100
commitda25843b402e7da87dea935945bbd4a8fc10a1fc (patch)
tree2e5e0e35c3b4766d97f06964284cf3a8bf0eefd9 /editor
parentefd0db85f6fef4414aa6eb839a72ca75c2feb54b (diff)
parent512e260af485aae5bdabfbaca11d9997c040fa00 (diff)
Merge pull request #55286 from KoBeWi/scene_prophet
Diffstat (limited to 'editor')
-rw-r--r--editor/plugins/script_editor_plugin.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/editor/plugins/script_editor_plugin.cpp b/editor/plugins/script_editor_plugin.cpp
index ace8ee53e6..aeb6ba13d5 100644
--- a/editor/plugins/script_editor_plugin.cpp
+++ b/editor/plugins/script_editor_plugin.cpp
@@ -1415,8 +1415,12 @@ void ScriptEditor::_menu_option(int p_option) {
} break;
case SHOW_IN_FILE_SYSTEM: {
const RES script = current->get_edited_resource();
- const String path = script->get_path();
+ String path = script->get_path();
if (!path.is_empty()) {
+ if (script->is_built_in()) {
+ path = path.get_slice("::", 0); // Show the scene instead.
+ }
+
FileSystemDock *file_system_dock = EditorNode::get_singleton()->get_filesystem_dock();
file_system_dock->navigate_to_path(path);
// Ensure that the FileSystem dock is visible.