|
How do you disable the render or inactivity of the child object of another object?
(comments are locked)
|
|
You can set the active state of any GameObject and all of its children with SetActiveRecursively You can also find individual children by name like this and disable their renderer individually with Beat me to it by 5 seconds, good job. You should also add that because it only searches in the GO's children it also has the benefit of not slowing everything down to a crawl like Find usually does.
Dec 27 '10 at 10:22 AM
azzogat
... unless the game object has LOTS of children!
Dec 27 '10 at 06:15 PM
ina
does setting an object to be inactive also removes its render?
Dec 27 '10 at 06:16 PM
ina
The renderer itself is never removed unless you specifically remove the component. Deactivating a game object will result in the object not being rendered anymore.
Dec 28 '10 at 12:59 PM
Sebas
(comments are locked)
|
