Transform.localScale Manual     Reference     Scripting  
Scripting > Runtime Classes > Transform
Transform.localScale

var localScale : Vector3

Description

The scale of the transform relative to the parent.

JavaScript
 // Widen the object by 0.1
transform.localScale += Vector3(0.1,0,0);

using UnityEngine;
using System.Collections;

public class example : MonoBehaviour {
void Example() {
transform.localScale += new Vector3(0.1F, 0, 0);
}
}

import UnityEngine
import System.Collections

class example(MonoBehaviour):

def Example():
transform.localScale += Vector3(0.1F, 0, 0)