// private void OnEnable()
    // {
    //   m_CustomCrosshair.EnableCrosshair();
    // }

    // Start is called before the first frame update
    private void Awake()
    {
        m_Camera = Camera.main;
        m_CharacterController = GameObject.FindGameObjectWithTag("Player").GetComponentInChildren <CharacterController>();
        m_PlayerController    = GameObject.FindGameObjectWithTag("Player").GetComponentInChildren <PlayerController>();
        m_Animator            = GameObject.FindGameObjectWithTag("Player").GetComponentInChildren <Animator>();
        m_BaseHitBox          = gameObject.GetComponent <BaseHitBox>();
        m_CustomCrosshair     = GetComponent <CustomCrosshair>();
    }
Example #2
0
    private void Awake()
    {
        m_PlayerController = GameObject.FindGameObjectWithTag("Player").GetComponentInChildren <PlayerController>();
        m_Animator         = GameObject.FindGameObjectWithTag("Player").GetComponentInChildren <Animator>();
        m_CustomCrosshair  = GetComponent <CustomCrosshair>();
        m_ShotsLeft        = m_ShotsPerRound;

        // SetCrosshair();
    }