- Home /
Is there a way to collapse all Components?
I have GameObject that holds all AudioSource components. I think I will have 20~30 AudioSources on this object by the end. The problem is, even if I collapse them manually, after I build and run, they all open up again.
Is there a way to collapse all components with just couple clicks?
I believe the only way possible of doing this would be to use a custom editor.
http://docs.unity3d.com/$$anonymous$$anual/editor-CustomEditors.html
How? I don't know, but this might help :P
Answer by Wuzseen · May 30, 2014 at 06:41 PM
20-30 AudioSources on one game object is, 9 times out of 10, the wrong way to do it.
You should probably be swapping audio clips in your audio source and playing those. That will "solve" your problem here, though to answer your question--there is no "collapse all", it is a feature that would be awesome though...
Answer by JayFiraja · Apr 17, 2020 at 03:07 PM
Right Mouse click on the Inspector Tab, this makes the context menu show up and there is "Expand ALL Components" and "Collapse All components"
Not really sure when this was added though. XD
Answer by Bryan-Legend · Feb 23, 2016 at 10:29 PM
Alt+LMB on the arrow in the hierarchy or project views will expand all or collapse all.
This will collapse GameObjects in hierarchy. But how to collapse components on one gameobject?
By right-clicking on the inspector tab, you will see the option