Esempio n. 1
0
 protected override void Awake()
 {
     base.Awake();
     _defaultMaterial = _mesh.material;
     _animator        = GetComponent <Animator>();
     _aiming          = GetComponent <CharacterAiming>();
 }
 protected override void OnStart()
 {
     ragdoll        = GetComponent <Ragdoll>();
     weapons        = GetComponent <ActiveWeapon>();
     aiming         = GetComponent <CharacterAiming>();
     postProcessing = FindObjectOfType <PostProcessVolume>().profile;
     camManagaer    = FindObjectOfType <CameraManager>();
 }
 // Start is called before the first frame update
 void Start()
 {
     animator        = GetComponent <Animator>();
     cc              = GetComponent <CharacterController>();
     activeWeapon    = GetComponent <ActiveWeapon>();
     reloadWeapon    = GetComponent <ReloadWeapon>();
     characterAiming = GetComponent <CharacterAiming>();
 }
Esempio n. 4
0
 protected override void OnStart()
 {
     _weapon   = GetComponent <ActiveWeapon>();
     _aiming   = GetComponent <CharacterAiming>();
     _animator = GetComponent <Animator>();
     _healthEffectController = GetComponent <PlayerHealthEffectController>();
     _equipment = GetComponent <Equipment>();
     _player    = GetComponent <PlayerController>();
 }
    // Start is called before the first frame update
    void Start()
    {
        animator        = GetComponent <Animator>();
        cc              = GetComponent <CharacterController>();
        activeWeapon    = GetComponent <ActiveWeapon>();
        reloadWeapon    = GetComponent <ReloadWeapon>();
        characterAiming = GetComponent <CharacterAiming>();

        #region  Movement with Joystick

        Leftjoystick = FindObjectOfType <FixedJoystick>();


        #endregion
        btnScriptTapCounterHelper = GameObject.FindGameObjectWithTag("ScriptHolder").GetComponent <UiButtonFuctionsScript>();
        desktopControlls          = GameObject.FindGameObjectWithTag("ScriptHolder").GetComponent <DekstopControlls>();
    }
Esempio n. 6
0
    void Start()
    {
        characterAnimation = GetComponent <CharacterAnimation>();
        characterAiming    = GetComponent <CharacterAiming>();

        RaycastWeapon existingWeapon = GetComponentInChildren <RaycastWeapon>();

        if (existingWeapon)
        {
            Equip(existingWeapon);
            AlignCamerasToWeapon(existingWeapon);
            hasWeapon = true;
        }
        else
        {
            hasWeapon = false;
        }
    }