├── .gitattributes
├── .github
└── ISSUE_TEMPLATE
│ ├── bug_report.md
│ └── feature_request.md
├── .gitignore
├── CONTRIBUTING.md
├── CONTRIBUTING.md.meta
├── Editor.meta
├── Editor
├── FolderEditor.cs
├── FolderEditor.cs.meta
├── FolderEditorUtils.cs
├── FolderEditorUtils.cs.meta
├── Icon Handling.meta
├── Icon Handling
│ ├── HierarchyFolderIcon.cs
│ ├── HierarchyFolderIcon.cs.meta
│ ├── ReplaceColor Shader.shader
│ ├── ReplaceColor Shader.shader.meta
│ ├── TextureHelper.cs
│ └── TextureHelper.cs.meta
├── Prefab Handling.meta
├── Prefab Handling
│ ├── AssetImportGrouper.cs
│ ├── AssetImportGrouper.cs.meta
│ ├── ChangedPrefabs.cs
│ ├── ChangedPrefabs.cs.meta
│ ├── LabelHandler.cs
│ ├── LabelHandler.cs.meta
│ ├── PrefabFolderStripper.cs
│ └── PrefabFolderStripper.cs.meta
├── Settings.meta
├── Settings
│ ├── SettingsDrawer.cs
│ ├── SettingsDrawer.cs.meta
│ ├── StripSettings.cs
│ └── StripSettings.cs.meta
├── UnityHierarchyFolders.Editor.asmdef
└── UnityHierarchyFolders.Editor.asmdef.meta
├── LICENSE
├── LICENSE.meta
├── README.md
├── README.md.meta
├── Runtime.meta
├── Runtime
├── Folder.cs
├── Folder.cs.meta
├── StrippingMode.cs
├── StrippingMode.cs.meta
├── UnityHierarchyFolders.Runtime.asmdef
└── UnityHierarchyFolders.Runtime.asmdef.meta
├── Tests.meta
├── Tests
├── Example.unity
└── Example.unity.meta
├── package.json
└── package.json.meta
/.gitattributes:
--------------------------------------------------------------------------------
1 | # Apply native OS line-endings on checkout of these files...
2 | *.boo text
3 | *.c text
4 | *.cginc text
5 | *.config text
6 | *.contentproj text
7 | *.cpp text
8 | *.dae text
9 | *.DAE text
10 | *.dtd text
11 | *.fx text
12 | *.glsl text
13 | *.h text
14 | *.inc text
15 | *.ini text
16 | *.js text
17 | *.JSFL text
18 | *.jsfl text
19 | *.json text
20 | *.log text
21 | *.md text
22 | *.mel text
23 | *.php text
24 | *.shader text
25 | *.txt text
26 | *.TXT text
27 | *.xaml text
28 | *.xml text
29 | *.xsd text
30 | .gitattributes text
31 | .gitignore text
32 | COPYING text
33 | INSTALL* text
34 | KEYS* text
35 | LICENSE* text
36 | NEWS* text
37 | NOTICE* text
38 | README* text
39 | TODO* text
40 | WHATSNEW* text
41 |
42 | # Apply Unix-style LF line-endings on checkout of these files...
43 | *.meta text eol=lf
44 | *.sh text eol=lf
45 | *.vspscc text eol=lf
46 | .htaccess text eol=lf
47 |
48 | # Previous "binary"
49 | *.unity text eol=lf
50 | # having asset as text eol=lf caused terrain data not to be saved correctly
51 | *.asset binary
52 | *.prefab text eol=lf
53 |
54 | # Apply Windows/DOS-style CR-LF line-endings on checkout of these files...
55 | *.bat text eol=crlf
56 | *.cmd text eol=crlf
57 | *.csproj text eol=crlf
58 | *.sln text eol=crlf
59 | *.user text eol=crlf
60 | *.vcproj text eol=crlf
61 | *.cs text eol=crlf
62 | *.css text eol=crlf
63 | *.htm text eol=crlf
64 | *.html text eol=crlf
65 |
66 | # No end-of-line conversions are applied (i.e., "-text -diff") to these files...
67 | *.7z binary
68 | *.ai binary
69 | *.anim binary
70 | *.apk binary
71 | *.bin binary
72 | *.bmp binary
73 | *.BMP binary
74 | *.com binary
75 | *.COM binary
76 | *.controller binary
77 | *.cubemap binary
78 | *.dex binary
79 | *.dll binary
80 | *.DLL binary
81 | *.dylib binary
82 | *.eps binary
83 | *.exe binary
84 | *.EXE binary
85 | *.exr binary
86 | *.fbx binary
87 | *.FBX binary
88 | *.fla binary
89 | *.flare binary
90 | *.flv binary
91 | *.gif binary
92 | *.guiskin binary
93 | *.gz binary
94 | *.ht binary
95 | *.ico binary
96 | *.jpeg binary
97 | *.jpg binary
98 | *.keystore binary
99 | *.mask binary
100 | *.mat binary
101 | *.mb binary
102 | *.mp3 binary
103 | *.mp4 binary
104 | *.mpg binary
105 | *.ogg binary
106 | *.PCX binary
107 | *.pcx binary
108 | *.pdb binary
109 | *.pdf binary
110 | *.physicMaterial binary
111 | *.physicmaterial binary
112 | *.png binary
113 | *.ps binary
114 | *.psd binary
115 | *.qt binary
116 | *.so binary
117 | *.swf binary
118 | *.tga binary
119 | *.tif binary
120 | *.tiff binary
121 | *.ttf binary
122 | *.TTF binary
123 | *.unitypackage binary
124 | *.unityPackage binary
125 | *.wav binary
126 | *.wmv binary
127 | *.zip binary
128 | *.ZIP binary
129 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/bug_report.md:
--------------------------------------------------------------------------------
1 | ---
2 | name: Bug report
3 | about: Anything that goes wrong, or usability stuff we missed
4 | title: "(bug) "
5 | labels: bug
6 | assignees: ''
7 |
8 | ---
9 |
10 | ## Description
11 |
12 | **What exactly is going wrong? Please be as precise as possible, but you don't have to be too detailed if the bug is easily reproducible.**
13 |
14 | ## Environment
15 | - **Unity version (e.g. 2019.3f11):**
16 | - **Any settings that you think may be applicable:**
17 | - **OS version if you know this is an OS specific issue. Include as much detail as you need (e.g. Windows 10 Home Edition, macOS 10.15 Catalina):**
18 |
19 | ## Steps to Reproduce
20 | - **Do you remember what activity you were in when the issue happened?**
21 | - **What steps did you take?**
22 | - **What happens when you take those steps?**
23 | - **Can you reproduce it consistently, or does it only happen sometimes? If it is inconsistent, do you recognize any patterns of when it occurs? (you don't have to be the expert though -- casual observations will suffice)**
24 | - **Are there any other known errors that aren't related to this one, but might look the same?**
25 |
26 | ## Expected Behavior
27 | **If it isn't immediately obvious, what do you expect to happen? Is it clearly an error, or does it work as intended, but behave in such a way that makes the component awkward or complicated to used?**
28 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/feature_request.md:
--------------------------------------------------------------------------------
1 | ---
2 | name: Feature request
3 | about: Suggest an idea for this project
4 | title: "(feature)"
5 | labels: ''
6 | assignees: ''
7 |
8 | ---
9 |
10 | ## Description
11 |
12 | **What exactly would you like to see? Be precise, but you don't have to work out the details here.**
13 |
14 | ## Use Cases
15 |
16 | **If it isn't super obvious why someone would want this feature, please explain where you would use it. If there is more than one use case, then please list them here.**
17 |
18 | **Would any of these changes conflict with other features? If so, how would you propose to resolve them?**
19 |
20 | ## Mockups
21 |
22 | **Do you have any visualizations, or flow charts? They would be appreciated, but not strictly required.**
23 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | /[Ll]ibrary/
2 | /[Tt]emp/
3 | /[Oo]bj/
4 | /[Bb]uild/
5 | /[Bb]uilds/
6 | /Assets/AssetStoreTools*
7 |
8 | # Visual Studio 2015 cache directory
9 | /.vs/
10 |
11 | # Autogenerated VS/MD/Consulo solution and project files
12 | ExportedObj/
13 | .consulo/
14 | *.csproj
15 | *.unityproj
16 | *.sln
17 | *.suo
18 | *.tmp
19 | *.user
20 | *.userprefs
21 | *.pidb
22 | *.booproj
23 | *.svd
24 | *.pdb
25 |
26 | # Unity3D generated meta files
27 | *.pidb.meta
28 |
29 | # Unity3D Generated File On Crash Reports
30 | sysinfo.txt
31 |
32 | # Builds
33 | *.apk
34 | *.unitypackage
35 |
--------------------------------------------------------------------------------
/CONTRIBUTING.md:
--------------------------------------------------------------------------------
1 | # Contributing
2 |
3 | I'll just keep it nice and short, since this is such a small project.
4 |
5 | - Keep brackets on the same line, use spaces instead of tabs, and be smart about comments and variable names.
6 | - Good commit messages (doesn't matter which style).
7 | - Be nice please.
8 |
--------------------------------------------------------------------------------
/CONTRIBUTING.md.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 2bdf3a7b3f45f40a5bcf99cf3dda41b3
3 | TextScriptImporter:
4 | externalObjects: {}
5 | userData:
6 | assetBundleName:
7 | assetBundleVariant:
8 |
--------------------------------------------------------------------------------
/Editor.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 8370f994d28094d389909b3ac0a84aef
3 | folderAsset: yes
4 | DefaultImporter:
5 | externalObjects: {}
6 | userData:
7 | assetBundleName:
8 | assetBundleVariant:
9 |
--------------------------------------------------------------------------------
/Editor/FolderEditor.cs:
--------------------------------------------------------------------------------
1 | #if UNITY_2019_1_OR_NEWER
2 | using UnityEditor;
3 | using UnityEngine;
4 | using UnityHierarchyFolders.Runtime;
5 |
6 | namespace UnityHierarchyFolders.Editor
7 | {
8 | [CustomEditor(typeof(Folder))]
9 | public class FolderEditor : UnityEditor.Editor
10 | {
11 | private bool _expanded = false;
12 |
13 | public override bool RequiresConstantRepaint() => true;
14 | public override void OnInspectorGUI()
15 | {
16 | this._expanded = EditorGUILayout.Foldout(this._expanded, "Icon Color", true);
17 | if (this._expanded) { this.RenderColorPicker(); }
18 | }
19 |
20 | private void RenderColorPicker()
21 | {
22 | var colorIndexProperty = this.serializedObject.FindProperty("_colorIndex");
23 |
24 | EditorGUILayout.BeginHorizontal();
25 | GUILayout.FlexibleSpace();
26 |
27 | float buttonSize = 25f;
28 |
29 | var gridRect = EditorGUILayout.GetControlRect(false, buttonSize * HierarchyFolderIcon.IconRowCount,
30 | GUILayout.Width(buttonSize * HierarchyFolderIcon.IconColumnCount));
31 |
32 | int currentIndex = colorIndexProperty.intValue;
33 | for (int row = 0; row < HierarchyFolderIcon.IconRowCount; row++)
34 | {
35 | for (int column = 0; column < HierarchyFolderIcon.IconColumnCount; column++)
36 | {
37 | int index = 1 + column + row * HierarchyFolderIcon.IconColumnCount;
38 | float width = gridRect.width / HierarchyFolderIcon.IconColumnCount;
39 | float height = gridRect.height / HierarchyFolderIcon.IconRowCount;
40 | var rect = new Rect(gridRect.x + width * column, gridRect.y + height * row, width, height);
41 | (var openIcon, var closeIcon) = HierarchyFolderIcon.ColoredFolderIcons(index);
42 |
43 | if (Event.current.type == EventType.Repaint)
44 | {
45 | if (index == currentIndex)
46 | {
47 | GUIStyle hover = "TV Selection";
48 | hover.Draw(rect, false, false, false, false);
49 | }
50 | else if (rect.Contains(Event.current.mousePosition))
51 | {
52 | GUI.backgroundColor = new Color(.7f, .7f, .7f, 1f);
53 | GUIStyle white = "WhiteBackground";
54 | white.Draw(rect, false, false, true, false);
55 | GUI.backgroundColor = Color.white;
56 | }
57 | }
58 |
59 | if (GUI.Button(rect, currentIndex == index ? openIcon : closeIcon, EditorStyles.label))
60 | {
61 | Undo.RecordObject(this.target, "Set Folder Color");
62 | colorIndexProperty.intValue = currentIndex == index ? 0 : index;
63 | this.serializedObject.ApplyModifiedProperties();
64 | EditorApplication.RepaintHierarchyWindow();
65 | GUIUtility.ExitGUI();
66 | }
67 | }
68 | }
69 |
70 | GUILayout.FlexibleSpace();
71 | EditorGUILayout.EndHorizontal();
72 |
73 | GUILayout.Space(10f);
74 | }
75 | }
76 | }
77 | #endif
--------------------------------------------------------------------------------
/Editor/FolderEditor.cs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: c336a8f369270f74e895d8dbed4b3f5d
3 | MonoImporter:
4 | externalObjects: {}
5 | serializedVersion: 2
6 | defaultReferences: []
7 | executionOrder: 0
8 | icon: {instanceID: 0}
9 | userData:
10 | assetBundleName:
11 | assetBundleVariant:
12 |
--------------------------------------------------------------------------------
/Editor/FolderEditorUtils.cs:
--------------------------------------------------------------------------------
1 | using UnityEditor;
2 | using UnityEditor.Build;
3 | using UnityEditor.Build.Reporting;
4 | using UnityEngine;
5 | using UnityEngine.SceneManagement;
6 | using UnityHierarchyFolders.Runtime;
7 |
8 | namespace UnityHierarchyFolders.Editor
9 | {
10 | public static class FolderEditorUtils
11 | {
12 | private const string _actionName = "Create Hierarchy Folder %#&N";
13 |
14 | /// Add new folder "prefab".
15 | /// Menu command information.
16 | [MenuItem("GameObject/" + _actionName, isValidateFunction: false, priority: 0)]
17 | public static void AddFolderPrefab(MenuCommand command)
18 | {
19 | var obj = new GameObject { name = "Folder" };
20 | obj.AddComponent();
21 |
22 | GameObjectUtility.SetParentAndAlign(obj, (GameObject)command.context);
23 | Undo.RegisterCreatedObjectUndo(obj, _actionName);
24 | Selection.activeObject = obj;
25 | }
26 | }
27 |
28 | public class FolderOnBuild : IProcessSceneWithReport
29 | {
30 | public int callbackOrder => 0;
31 |
32 | public void OnProcessScene(Scene scene, BuildReport report)
33 | {
34 | var strippingMode = report == null ? StripSettings.PlayMode : StripSettings.Build;
35 |
36 | foreach (var folder in Object.FindObjectsOfType())
37 | {
38 | folder.Flatten(strippingMode, StripSettings.CapitalizeName);
39 | }
40 | }
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/Editor/FolderEditorUtils.cs.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 6810d6ae38b004696bfe74282dce3d48
3 | MonoImporter:
4 | externalObjects: {}
5 | serializedVersion: 2
6 | defaultReferences: []
7 | executionOrder: 0
8 | icon: {instanceID: 0}
9 | userData:
10 | assetBundleName:
11 | assetBundleVariant:
12 |
--------------------------------------------------------------------------------
/Editor/Icon Handling.meta:
--------------------------------------------------------------------------------
1 | fileFormatVersion: 2
2 | guid: 9b9b359874c54b8e9968bce99b84b1cd
3 | timeCreated: 1613920209
--------------------------------------------------------------------------------
/Editor/Icon Handling/HierarchyFolderIcon.cs:
--------------------------------------------------------------------------------
1 | #if UNITY_2019_1_OR_NEWER
2 | using System;
3 | using System.Collections;
4 | using System.Collections.Generic;
5 | using System.Linq;
6 | using System.Reflection;
7 | using UnityEditor;
8 | using UnityEditor.IMGUI.Controls;
9 | using UnityEngine;
10 | using UnityHierarchyFolders.Runtime;
11 | using Object = UnityEngine.Object;
12 |
13 | namespace UnityHierarchyFolders.Editor
14 | {
15 | public static class HierarchyFolderIcon
16 | {
17 | #if UNITY_2020_1_OR_NEWER
18 | private const string _openedFolderPrefix = "FolderOpened";
19 | #else
20 | private const string _openedFolderPrefix = "OpenedFolder";
21 | #endif
22 | private const string _closedFolderPrefix = "Folder";
23 |
24 | private static Texture2D _openFolderTexture;
25 | private static Texture2D _closedFolderTexture;
26 | private static Texture2D _openFolderSelectedTexture;
27 | private static Texture2D _closedFolderSelectedTexture;
28 |
29 | private static bool _isInitialized;
30 | private static bool _hasProcessedFrame = true;
31 |
32 | // Reflected members
33 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Style", "IDE1006:Naming Styles", Justification = "Special naming scheme")]
34 | private static PropertyInfo prop_sceneHierarchy;
35 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Style", "IDE1006:Naming Styles", Justification = "Special naming scheme")]
36 | private static PropertyInfo prop_treeView;
37 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Style", "IDE1006:Naming Styles", Justification = "Special naming scheme")]
38 | private static PropertyInfo prop_data;
39 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Style", "IDE1006:Naming Styles", Justification = "Special naming scheme")]
40 | private static PropertyInfo prop_selectedIcon;
41 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Style", "IDE1006:Naming Styles", Justification = "Special naming scheme")]
42 | private static PropertyInfo prop_objectPPTR;
43 |
44 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Style", "IDE1006:Naming Styles", Justification = "Special naming scheme")]
45 | private static MethodInfo meth_getRows;
46 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Style", "IDE1006:Naming Styles", Justification = "Special naming scheme")]
47 | private static MethodInfo meth_isExpanded;
48 | [System.Diagnostics.CodeAnalysis.SuppressMessage("Style", "IDE1006:Naming Styles", Justification = "Special naming scheme")]
49 | private static MethodInfo meth_getAllSceneHierarchyWindows;
50 |
51 | private static (Texture2D open, Texture2D closed)[] _coloredFolderIcons;
52 | public static (Texture2D open, Texture2D closed) ColoredFolderIcons(int i) => _coloredFolderIcons[i];
53 |
54 | public static int IconColumnCount => IconColors.GetLength(0);
55 | public static int IconRowCount => IconColors.GetLength(1);
56 |
57 | private static readonly Color[,] IconColors = {
58 | {new Color(0.09f, 0.57f, 0.82f), new Color(0.05f, 0.34f, 0.48f),},
59 | {new Color(0.09f, 0.67f, 0.67f), new Color(0.05f, 0.42f, 0.42f),},
60 | {new Color(0.23f, 0.73f, 0.36f), new Color(0.15f, 0.41f, 0.22f),},
61 | {new Color(0.55f, 0.35f, 0.71f), new Color(0.35f, 0.24f, 0.44f),},
62 | {new Color(0.78f, 0.27f, 0.55f), new Color(0.52f, 0.15f, 0.35f),},
63 | {new Color(0.80f, 0.66f, 0.10f), new Color(0.56f, 0.46f, 0.02f),},
64 | {new Color(0.91f, 0.49f, 0.13f), new Color(0.62f, 0.33f, 0.07f),},
65 | {new Color(0.91f, 0.30f, 0.24f), new Color(0.77f, 0.15f, 0.09f),},
66 | {new Color(0.35f, 0.49f, 0.63f), new Color(0.24f, 0.33f, 0.42f),},
67 | };
68 |
69 | [InitializeOnLoadMethod]
70 | private static void Startup()
71 | {
72 | EditorApplication.update += ResetFolderIcons;
73 | EditorApplication.hierarchyWindowItemOnGUI += RefreshFolderIcons;
74 | }
75 |
76 | private static void InitIfNeeded()
77 | {
78 | if (_isInitialized) { return; }
79 |
80 | _openFolderTexture = (Texture2D)EditorGUIUtility.IconContent($"{_openedFolderPrefix} Icon").image;
81 | _closedFolderTexture = (Texture2D)EditorGUIUtility.IconContent($"{_closedFolderPrefix} Icon").image;
82 |
83 | // We could use the actual white folder icons but I prefer the look of the tinted white folder icon
84 | // To use the actual white version:
85 | // texture = (Texture2D) EditorGUIUtility.IconContent($"{OpenedFolderPrefix | ClosedFolderPrefix} On Icon").image;
86 | _openFolderSelectedTexture = TextureHelper.GetWhiteTexture(_openFolderTexture, $"{_openedFolderPrefix} Icon White");
87 | _closedFolderSelectedTexture = TextureHelper.GetWhiteTexture(_closedFolderTexture, $"{_closedFolderPrefix} Icon White");
88 |
89 | _coloredFolderIcons = new (Texture2D, Texture2D)[] { (_openFolderTexture, _closedFolderTexture) };
90 |
91 | for (int row = 0; row < IconRowCount; row++)
92 | {
93 | for (int column = 0; column < IconColumnCount; column++)
94 | {
95 | int index = 1 + column + row * IconColumnCount;
96 | var color = IconColors[column, row];
97 |
98 | var openFolderIcon = TextureHelper.GetTintedTexture(_openFolderSelectedTexture,
99 | color, $"{_openFolderSelectedTexture.name} {index}");
100 | var closedFolderIcon = TextureHelper.GetTintedTexture(_closedFolderSelectedTexture,
101 | color, $"{_closedFolderSelectedTexture.name} {index}");
102 |
103 | ArrayUtility.Add(ref _coloredFolderIcons, (openFolderIcon, closedFolderIcon));
104 | }
105 | }
106 |
107 | // reflection
108 |
109 | const BindingFlags BindingAll = BindingFlags.Public
110 | | BindingFlags.NonPublic | BindingFlags.Static | BindingFlags.Instance;
111 |
112 | var assembly = typeof(SceneView).Assembly;
113 |
114 | var type_sceneHierarchyWindow = assembly.GetType("UnityEditor.SceneHierarchyWindow");
115 | meth_getAllSceneHierarchyWindows = type_sceneHierarchyWindow.GetMethod("GetAllSceneHierarchyWindows", BindingAll);
116 | prop_sceneHierarchy = type_sceneHierarchyWindow.GetProperty("sceneHierarchy");
117 |
118 | var type_sceneHierarchy = assembly.GetType("UnityEditor.SceneHierarchy");
119 | prop_treeView = type_sceneHierarchy.GetProperty("treeView", BindingAll);
120 |
121 | var type_treeViewController = assembly.GetType("UnityEditor.IMGUI.Controls.TreeViewController");
122 | prop_data = type_treeViewController.GetProperty("data", BindingAll);
123 |
124 | var type_iTreeViewDataSource = assembly.GetType("UnityEditor.IMGUI.Controls.ITreeViewDataSource");
125 | meth_getRows = type_iTreeViewDataSource.GetMethod("GetRows");
126 | meth_isExpanded = type_iTreeViewDataSource.GetMethod("IsExpanded", new Type[] { typeof(TreeViewItem) });
127 |
128 | var type_gameObjectTreeViewItem = assembly.GetType("UnityEditor.GameObjectTreeViewItem");
129 | prop_selectedIcon = type_gameObjectTreeViewItem.GetProperty("selectedIcon", BindingAll);
130 | prop_objectPPTR = type_gameObjectTreeViewItem.GetProperty("objectPPTR", BindingAll);
131 |
132 | _isInitialized = true;
133 | }
134 |
135 | private static void ResetFolderIcons()
136 | {
137 | InitIfNeeded();
138 | _hasProcessedFrame = false;
139 | }
140 |
141 | private static void RefreshFolderIcons(int instanceid, Rect selectionrect)
142 | {
143 | if (_hasProcessedFrame) { return; }
144 |
145 | _hasProcessedFrame = true;
146 |
147 | var windows = ((IEnumerable)meth_getAllSceneHierarchyWindows.Invoke(null, Array.Empty