示例#1
0
 private void Start()
 {
     _notice   = GetComponent <NoticeBehaviour>();
     _bow      = GetComponentInChildren <BowBehaviour>();
     _playerHp = GameObject.FindGameObjectWithTag("Player").GetComponent <HealthBehaviour>();
     _nav      = GetComponent <NavMeshAgent>();
 }
示例#2
0
    private float erro = 0.1f; //Porcentagem de erro da IA, neste caso o padrão é 10%

    private void FixedUpdate()
    {
        if (GameManager.enemyCanShot == true && GameManager.cameraInPosition)
        {
            bow = GameObject.Find("EnemyBow").GetComponent <BowBehaviour>();
            GameManager.enemyCanShot = false;
            StartCoroutine(Aim(Player.transform.position));
        }
    }
 void Start()
 {
     bBehaviour  = GameObject.Find("Bow").GetComponent <BowBehaviour>();
     pController = GameObject.Find("Archer").GetComponent <PlayerController>();
 }
 private void Start()
 {
     bBehaviour = GameObject.Find("Bow").GetComponent <BowBehaviour>();
     pStats     = GameObject.Find("Archer").GetComponent <PlayerStats>();
     damage     = pStats.curDamage;
 }