Просмотр исходного кода

Make sure scan happens after all nodes enter scene (including plugins), fixes #9286

Juan Linietsky 8 лет назад
Родитель
Сommit
0130bbfac0
1 измененных файлов с 2 добавлено и 1 удалено
  1. 2 1
      editor/editor_file_system.cpp

+ 2 - 1
editor/editor_file_system.cpp

@@ -913,7 +913,8 @@ void EditorFileSystem::_notification(int p_what) {
 
 
 		case NOTIFICATION_ENTER_TREE: {
 		case NOTIFICATION_ENTER_TREE: {
 
 
-			scan();
+			call_deferred("scan"); //this should happen after every editor node entered the tree
+
 		} break;
 		} break;
 		case NOTIFICATION_EXIT_TREE: {
 		case NOTIFICATION_EXIT_TREE: {
 			if (use_threads && thread) {
 			if (use_threads && thread) {