// Use this for initialization void Start() { selector = GameObject.FindWithTag("Selector"); swordLeftObject = GameObject.FindWithTag("SwordLeft"); swordRightObject = GameObject.FindWithTag("SwordRight"); shieldObject = GameObject.FindWithTag("Shield"); shieldCollider = GameObject.FindWithTag ("ShieldCollider"); player = GameObject.FindWithTag("Player"); radar = GameObject.FindWithTag("Radar").GetComponent<ObjectScan>(); hc = player.GetComponent<HealthController>(); tempVect = shieldObject.transform.position - transform.position; tempVectSwordRight = swordRightObject.transform.position - transform.position; //shieldObject.transform.position = randomPosition; }
// Use this for initialization void Start() { selector = GameObject.FindWithTag("Selector"); swordLeftObject = GameObject.FindWithTag("SwordLeft"); swordRightObject = GameObject.FindWithTag("SwordRight"); shieldObject = GameObject.FindWithTag("Shield"); shieldCollider = GameObject.FindWithTag("ShieldCollider"); player = GameObject.FindWithTag("Player"); radar = GameObject.FindWithTag("Radar").GetComponent <ObjectScan>(); hc = player.GetComponent <HealthController>(); tempVect = shieldObject.transform.position - transform.position; tempVectSwordRight = swordRightObject.transform.position - transform.position; //shieldObject.transform.position = randomPosition; }