Make sure the scene warning of changes may be lost is only for scenes, fixes #13970

This commit is contained in:
Juan Linietsky 2017-12-05 13:25:52 -03:00
parent 03c1b6be23
commit 1587f45c25

View file

@ -1495,7 +1495,7 @@ void EditorNode::_edit_current() {
if (FileAccess::exists(base_path + ".import")) {
editable_warning = TTR("This resource belongs to a scene that was imported, so it's not editable.\nPlease read the documentation relevant to importing scenes to better understand this workflow.");
} else {
if (!get_edited_scene() || get_edited_scene()->get_filename() != base_path) {
if ((!get_edited_scene() || get_edited_scene()->get_filename() != base_path) && ResourceLoader::get_resource_type(base_path) == "PackedScene") {
editable_warning = TTR("This resource belongs to a scene that was instanced or inherited.\nChanges to it will not be kept when saving the current scene.");
}
}