Exemple #1
0
 private void Awake()
 {
     anim = GetComponent <Animator>();
     if (transform.parent)
     {
         team = transform.parent.GetComponent <AiTeam>();
     }
     state = State.WANDER;
 }
 private void Awake()
 {
     maxXVec = new Vector3(maxX * 2, 0, 0);
     maxZVec = new Vector3(0, 0, maxZ * 2);
     if (!TestScene)
     {
         text   = FindObjectOfType <TextMeshProUGUI>();
         aiTeam = GameObject.Find(tag + "Team").GetComponent <AiTeam>();
     }
 }