Here’s my code:
Vector3 posGirlBody = new Vector3 (0, 0, 0);
GameObject girlBody = Instantiate (girlPrefabs [Random.Range (0, girlPrefabs.Length)], posGirlBody, Quaternion.identity) as GameObject;
var crtScale = girlBody.transform.localScale;
Debug.Log ("Current Scale is: "+crtScale);
girlBody.transform.parent = transform;
The Debug shows: Current Scale is: (1.0, 1.0, 1.0), but in my Inspector, when I click on the prefab (clone), the Scale shows (0, 0, 0), and I can’t see the prefab in my game view, so it was in deed reset to 0 at runtime. How to solve the problem? Please help!