Example #1
0
 public void Awake()
 {
     anim      = GetComponentInParent <Animator>();
     hash      = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent <HaszIDs>();
     ShotAudio = GetComponent <AudioSource>();
     shoot     = false;
 }
    void Awake()
    {
        anim = GetComponent <Animator>();
        hash = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent <HaszIDs>();


        anim.SetLayerWeight(2, 1f);
        anim.SetLayerWeight(3, 1f);
    }
    void Awake()
    {
        nav       = GetComponent <NavMeshAgent>();
        anim      = GetComponent <Animator>();
        sCollider = GetComponent <SphereCollider>();
        health    = GetComponent <Health>();
        cColider  = GetComponent <CapsuleCollider>();

        player          = GameObject.FindGameObjectWithTag(Tags.Player);
        hash            = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent <HaszIDs>();
        enemyAnimIsDead = true;
    }
Example #4
0
    void Awake()
    {
        groundMask = LayerMask.GetMask(Layers.ground);

        anim = GetComponent <Animator>();
        rb   = GetComponent <Rigidbody>();

        hash = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent <HaszIDs>();

        anim.SetLayerWeight(1, 1f);
        playerHealth     = GetComponent <Health>();
        PlayerAnimIsDead = true;
    }
 public EnemyAnimatorHelper(Animator animator, HaszIDs hashID)
 {
     anim = animator;
     hash = hashID;
 }
 void Awake()
 {
     anim = GetComponent <Animator>();
     hash = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent <HaszIDs>();
 }