Example #1
0
 void Start()
 {
     agent         = GetComponent <NavMeshAgent>();
     childNavAgent = GetComponent <ChildNavAgent>();
     childNavAgent.OnStartNavigation += StartNavigation;
     childNavAgent.OnEndNavigation   += StopNavigation;
 }
Example #2
0
 private void Start()
 {
     agent         = GetComponent <NavMeshAgent>();
     childNavAgent = GetComponent <ChildNavAgent>();
     childNavAgent.OnStartNavigation += StartNavigation;
     childNavAgent.OnEndNavigation   += StopNavigation;
     StartCoroutine(GoToRandomPoint());
 }
Example #3
0
 private void Start()
 {
     agent          = GetComponent <NavMeshAgent>();
     childNavAgent  = GetComponent <ChildNavAgent>();
     turret         = GetComponent <Turret>();
     turret.enabled = false;
     childNavAgent.OnStartNavigation += StartNavigation;
     childNavAgent.OnEndNavigation   += StopNavigation;
     StartCoroutine(GoToThrowingPoint());
 }