void Start() { rb = this.gameObject.GetComponent <Rigidbody2D>(); rbPlayer = player.GetComponent <Rigidbody2D>(); target = GameObject.FindGameObjectWithTag("Player").GetComponent <Transform>(); movimento = true; movimentBehaviour = GameObject.FindGameObjectWithTag("Player").GetComponent <MovimentBehaviour>(); }
void Start() { this.moving = false; this.attack = false; this.isAttackAgain = true; this.anim = GetComponent<AnimatorControler>(); this.enemyMoviment = GetComponent<MovimentBehaviour>(); this.enemyAttackController = GetComponent<AttackControler>(); }
void Start() { this.move = GetComponent<MovimentBehaviour>(); Destroy(this.gameObject, 4f); }