- Home /
How to Activate Children While Parent is Deactivated?
Hi, my problem is that I have the main camera attache to a cahracter in the game, obviously when I deactivate the character the camera turns off, how can I make it so that the camera is still active but the rest of the character is deactivated?
Up to Unity 3, disabling a parent had no effect on the children - we had to use SetActiveRecursively in order to control the whole "family" at once. Unity 4 changed this, and now disabling a parent also deactivates its children.
Answer by Jamora · Jul 29, 2013 at 12:16 AM
There is no way to have an active child gameobject with an inactive parent. You must unparent the camera and have it follow the player some other way. You could create a script that has the camera follow the player. You could also try to just disable the character's mesh renderer.
Your answer