- Home /
 
 
               Question by 
               Red Sentinel · Apr 20, 2013 at 07:31 AM · 
                rotationmovement  
              
 
              Rotation and movement applied to other objects
Hi everyone. Is there a way to have an object "mirror" another object using scripting? Thanks.
               Comment
              
 
               
               
               Best Answer 
              
 
              Answer by Eric5h5 · Apr 20, 2013 at 07:57 PM
 var otherObject : Transform;
 
 function LateUpdate () {
     transform.position = otherObject.position;
     transform.rotation = otherObject.rotation;
     transform.localScale = otherObject.localScale;
 }
 
              Answer by dendens2 · Apr 20, 2013 at 02:30 PM
Add it as a child of the first object in the inspector or through code.
 transform.parent =
 
                  add that to the object you are going to have mirror and then just add the object you are mirroring on the right side.
Your answer