Пример #1
0
 private void Awake()
 {
     _anim         = GetComponent <Animator>();
     _knifePool    = GameObject.FindGameObjectWithTag(_Data._tagKnifePool).GetComponent <LeanGameObjectPool>();
     _AIPawn       = GetComponents <BehaviorTree>();
     _target       = GameObject.FindGameObjectWithTag(_Data._tagPlayer).transform;
     _playerAtkDmg = _target.GetComponent <PlayerAtkDmg>();
 }
Пример #2
0
 void Awake()
 {
     _initialPos   = new Vector3(0, 0, 5f);
     _startPoint   = new Vector3(0, 0, 2.5f);
     _target       = GameObject.FindGameObjectWithTag(_Data._tagPlayer).transform;
     _playerAtkDmg = _target.GetComponent <PlayerAtkDmg>();
     _knifePool    = GameObject.FindGameObjectWithTag(_Data._tagKnifePool).GetComponent <LeanGameObjectPool>();
     _anim         = GetComponent <Animator>();
     _bossTree     = GetComponent <BehaviorTree>();
     _FWPoints     = new Vector3[] { new Vector3(-0.7f, 1, 1.6f), new Vector3(0.5f, 1, 1.6f) };
     _FWRotation   = new Vector3[] { new Vector3(0, -120, 0), new Vector3(0, 120, 0) };
     _knifePoints  = new Vector3[] { new Vector3(1.3f, 1, 4), new Vector3(0, 1, 4), new Vector3(-1.3f, 1, 4) };
 }