- Home /
 
               Question by 
               b889965 · Apr 21, 2015 at 02:28 PM · 
                parentchildparentingchild objectchild-to-gameobject  
              
 
              Why is parenting not working?
Hi, i have 2 cubes Test1 an Test2 and the Script is attached to Test2 but nothing happens. I tried so many things from the Forum but nothing worked for me, hope someone can help me with that.
 using UnityEngine;
 using System.Collections;
 
 public class ExampleClass : MonoBehaviour
 {
     void start()
     {
         GameObject test = GameObject.Find("Test1");
         this.transform.parent = test.transform;
     }
 }
               Comment
              
 
               
              Answer by NoseKills · Apr 22, 2015 at 06:03 AM
Where do you call start() ? If you want it to be called automatically, make the "s" capital - Start()
Your answer
 
 
             Follow this Question
Related Questions
Make a simple tree 1 Answer
How to make multiple gameobjects child of one and the same transform (SCRIPT) 2 Answers
Make child's transform independent of parent 1 Answer
GetComponentInChildren with tag in two variable 3 Answers
" You should never have a parent and child rigidbody together " ? 2 Answers
 koobas.hobune.stream
koobas.hobune.stream 
                       
                
                       
			     
			 
                