- Home /
Question by
DragonSaige · Aug 26, 2012 at 03:16 PM ·
gameobjectparentchildfind
how do I get reference to a parent or a child?
What I want to do is basically access a Parent or a child object.
Comment
Best Answer
Answer by ScroodgeM · Aug 26, 2012 at 04:21 PM
Thanks for the answer but here I'm a little confused if I use transform.parent the return type will be transform or GameObject?
return is transform. use
transform.parent.gameObjectto get parent GameObject
Answer by f1rd1n · Nov 09, 2018 at 10:40 PM
how do I get parent object of parent object from a script?
Your answer
Follow this Question
Related Questions
Make a simple tree 1 Answer
Can I limit a .Find to the Parents and Child and not the Scene? 3 Answers
Finding Children question 3 Answers
change pivot of parent game object 1 Answer
How can I find a specific child gameObject with multiple instances? 2 Answers