Esempio n. 1
0
 public override void OnEnable()
 {
     base.OnEnable();
     mobMask     = LayerMask.GetMask("NPC");
     coneOfSight = GetComponent <ConeOfSight>();
     mobAttack   = GetComponent <MobMeleeAttack>();
 }
Esempio n. 2
0
 protected override void Awake()
 {
     mobMask     = LayerMask.GetMask("NPC");
     coneOfSight = GetComponent <ConeOfSight>();
     mobAttack   = GetComponent <MobMeleeAttack>();
     base.Awake();
     ResetBehaviours();
 }
 public override void OnEnable()
 {
     base.OnEnable();
     hitMask        = LayerMask.GetMask("Players");
     playersLayer   = LayerMask.NameToLayer("Players");
     mobMeleeAttack = GetComponent <MobMeleeAttack>();
     coneOfSight    = GetComponent <ConeOfSight>();
     simpleAnimal   = GetComponent <SimpleAnimal>();
     PlayRandomSound();
 }