- Home /
 
               Question by 
               alexander11 · Sep 16, 2016 at 11:20 PM · 
                c#unity 5gameobject3dlocalscale  
              
 
              How do i get the LocalSize of an object?
How do i get the Local Size of an object?
               Comment
              
 
               
               
               Best Answer 
              
 
              Answer by toddisarockstar · Sep 16, 2016 at 11:54 PM
     public Vector3 mysize;
     void Start () {
         mysize=transform.localScale;
         mysize.y = mysize.y * 2;
         mysize.x = mysize.x * 2;
 
         transform.localScale=mysize;
 
 
         print ("I am taller now and my hight is" + transform.localScale.y);
 
         print ("I am taller now and my width is" + transform.localScale.x);
         
 }
Your answer
 
 
             Follow this Question
Related Questions
transform.SetParent(null); Not Working 1 Answer
How do i Instantiate gameObjects in between multiple points? 2 Answers
How to set to game objects's position from 2 different game objects arrays equal to each other? 0 Answers
Script on multiple objects not working properly! 1 Answer
Need help in the stone throwing mechanic with aiming for mobile in Unity3d 1 Answer
 koobas.hobune.stream
koobas.hobune.stream 
                       
                
                       
			     
			 
                