private void Start() { starsDisplay = GameObject.FindObjectOfType <StarsDisplay>(); defenderParent = GameObject.Find("Defenders"); if (!defenderParent) { defenderParent = new GameObject("Defenders"); } }
// Use this for initialization void Start() { starsDisplay = GameObject.FindObjectOfType <StarsDisplay>(); parent = GameObject.Find(PARENT_NAME); if (parent == null) { parent = new GameObject(PARENT_NAME); } }
// Use this for initialization void Start() { starsDislay = GameObject.FindObjectOfType <StarsDisplay> (); parent = GameObject.Find("Defenders"); if (!parent) { parent = new GameObject("Defenders"); } }
// Use this for initialization void Start() { DefenderParent = GameObject.Find("Defenders"); StarBalance = GameObject.FindObjectOfType <StarsDisplay> (); if (!DefenderParent) { DefenderParent = new GameObject("Defenders"); } }
// Use this for initialization void Start() { cam = Camera.main; DefenderHierarchy = GameObject.Find("Defenders"); starDisplay = GameObject.FindObjectOfType<StarsDisplay>(); if(!DefenderHierarchy) { DefenderHierarchy = new GameObject("Defenders"); } }
private void attemptToPlaceDefenderAt(Vector2 gridPos) { StarsDisplay starDisplay = FindObjectOfType <StarsDisplay>(); int defenderCost = diffender.cost; if (starDisplay.haveEnoughStars(defenderCost)) { spawnDefender(gridPos); starDisplay.spendingStarts(defenderCost); } }
private void Start() { starsDisplay = FindObjectOfType <StarsDisplay>(); }
void Start() { starsDisplay = GameObject.FindObjectOfType <StarsDisplay> (); }
private void Start() { starsDisplay = FindObjectOfType <StarsDisplay>(); mainCam = Camera.main; }
private void Start() { starsDisplay = FindObjectOfType <StarsDisplay>(); CreateDefendersParent(); }
public void AddStars(int amount) { StarsDisplay starsDisplay = FindObjectOfType <StarsDisplay>(); starsDisplay.AddStars(amount); }