Como fazer referência função na unidade
public GameObject myObject; //make ref. in inspector window
myObject.GetComponent<MyScript>().MyFunction();
Comfortable Caterpillar
public GameObject myObject; //make ref. in inspector window
myObject.GetComponent<MyScript>().MyFunction();