Activating / Deactivating ALL Objects

Hello,

Is there some way to select all the objects we want to hide, for example, clicking the button they all get hidden besides only one?

This is something that really needs to be in Unity… It’s very annoying doing this one by one.

i suggest u to use GameObject array.

declare something like this,

var go:GameObejct[ ]=new GameObject[×];

function OnGUI()
{
if(GUI.Button(“button”))
{
for(var i=0;i<go.length;i++)
{
go.enabled=(go.enabled==true)?false:true;
}
}

}

and in the editor link the objects u want to be controlled…

I didnt test the code on editor thr ma be some typos so bare with it…

And for example to hide and unhide all the mesh renderer in several objects?

EDIT: Just checked the Asset Store and Batch Edit does what I’m asking. I’m going to buy it.

Thanks for the help anyway! :slight_smile: