public void GetStarShotRef() { // Reference the newly spawned prefab, which is a child object to us. starShotRef = gameObject.GetComponentInChildren <StarShot>(); Debug.Log(starShotRef.name); }
void Awake() { ability1Ref = GetComponentInParent <StarShot>(); }