Переглянути джерело

[scene] Re-enabled fx filtering

Clément Espeute 6 місяців тому
батько
коміт
8d5a5f9b53
1 змінених файлів з 9 додано та 0 видалено
  1. 9 0
      hide/comp/SceneEditor.hx

+ 9 - 0
hide/comp/SceneEditor.hx

@@ -4490,6 +4490,15 @@ class SceneEditor {
 		for( p in prefab.flatten(null, null) ) {
 		for( p in prefab.flatten(null, null) ) {
 			makeInteractive(p);
 			makeInteractive(p);
 			applySceneStyle(p);
 			applySceneStyle(p);
+
+			var ref = Std.downcast(p, hrt.prefab.Reference);
+			if (ref != null && !ref.editMode && ref.refInstance != null) {
+
+				// only call applySceneStyle and not makeInteractive on the childs of non edit references
+				for (pp in ref.refInstance.flatten(null, null, true)) {
+					applySceneStyle(ref.refInstance);
+				}
+			}
 		}
 		}
 
 
 		if (prefab == sceneData) {
 		if (prefab == sceneData) {