// Use this for initialization void Start() { _playerMovement = FindObjectOfType <Player_Movement>(); _transform = GetComponent <Transform>(); _enemyController = GetComponent <Fenrir_Controller>(); _animator = GetComponent <Animator>(); _wallCheck = GetComponentInChildren <Fenrir_WallCheck>(); _rigidBody2D = GetComponent <Rigidbody2D>(); _enemyAttack = GetComponentInChildren <Fenrir_Attack>(); _player = _playerMovement.GetComponent <Transform>(); }
// Use this for initialization void Start() { _lineCastObject = GameObject.Find("LineCastEndingPoint"); _animator = GetComponent <Animator>(); _transform = GetComponent <Transform>(); _enemyController = GetComponent <Fenrir_Controller>(); _turnToPassiveTimer = _timeBeforeTurningPassive; _lineCastEndingPoint = _lineCastObject.GetComponent <Transform>(); _enemyAttack = GetComponentInChildren <Fenrir_Attack>(); }
private void Start() { _instance = this; _hp = GetComponent <Fenrir_HP>(); _movement = GetComponent <Fenrir_Movement>(); _searchForPlayer = GetComponent <Fenrir_Search>(); _wallCheck = GetComponentInChildren <Fenrir_WallCheck>(); _attack = GetComponentInChildren <Fenrir_Attack>(); _attackTrigger = GetComponentInChildren <Fenrir_AttackTrigger>(); _audioSource = GetComponent <AudioSource>(); _audioSource2 = _attack.GetComponent <AudioSource>(); }
// Use this for initialization void Start() { _enemyController = GetComponent <Fenrir_Controller>(); _attack = GetComponentInChildren <Fenrir_Attack>(); _animator = GetComponent <Animator>(); _transform = GetComponent <Transform>(); _audioSource = GetComponent <AudioSource>(); _originalHP = hitPoints; if (thisIsABoss) { _BossHP = FindObjectOfType <BossHPBarController>(); } }
// Use this for initialization void Start() { _transform = GetComponent <Transform>(); _attackHitBox = GetComponentInChildren <BoxCollider2D>(); _attackHitBox.enabled = false; _player = FindObjectOfType <Player_HP>(); _enemyController = GetComponentInParent <Fenrir_Controller>(); _animator = GetComponentInParent <Animator>(); _rigidBody = GetComponentInParent <Rigidbody2D>(); _movement = GetComponentInParent <Fenrir_Movement>(); _hp = GetComponentInParent <Fenrir_HP>(); _coolDownTimer = _attackCoolDown; _attackTimer = _attackTime; _delayTimer = _attackDelay; _specialPointL = GameObject.Find("SpecialPointL"); _specialPointR = GameObject.Find("SpecialPointR"); _specialEffect = GetComponentInChildren <ParticleSystem>(); //_bodyTransform = GetComponentInParent<Transform>(); }
private void Start() { _enemyMovement = GetComponentInParent <Fenrir_Movement>(); _transform = GetComponent <Transform>(); _controller = GetComponentInParent <Fenrir_Controller>(); }