Exemplo n.º 1
0
    public void StartChasing()
    {
        this.state = MeleeEnemyState.CHASING;

        // Start a new path to the targetPosition, call the the OnPathComplete function
        // when the path has been calculated (which may take a few frames depending on the complexity)
        path = null;
        seeker.StartPath(transform.position, player.transform.position, OnPathComplete);
    }
Exemplo n.º 2
0
 public void StartAttacking()
 {
     this.state = MeleeEnemyState.ATTACKING;
 }
Exemplo n.º 3
0
 public void StartIdle()
 {
     this.state = MeleeEnemyState.IDLE;
 }