void Start() { //Set up depot bar bar = GetComponent <Image> (); RectTransform barRect = GetComponent <RectTransform> (); //Grab depot depotBehaviour = depotObject.GetComponent <depotAbsorb> (); }
// Use this for initialization void Start() { depotABehaviour = depotA.GetComponent <depotAbsorb> (); stats = this.GetComponent <Text> (); }