Hide specific gizmos by folding the component

Hello. I can’t seem to be able to hide specific ALINE gizmos by folding the component. I can only disable all gizmos by pressing the Gimos button in the editor.

Maybe I’m missing a step?

I derive from MonoBehaviourGizmos
Draw inside: public override void DrawGizmos()
With: Draw.SolidBox(…)

Any help is greatly appreciated!

Hi

I’m guessing that you are using a render pipeline?
Unfortunately, the method for determining if an object has its component ui folded and thus if the gizmos should be hidden, is a private method. I can access it using some reflection, so it works most of the time. However, when using a render pipeline calling this method unfortunately seems to crash unity in some cases and I have not found a workaround for this.

1 Like