// Use this for initialization
 private void Start()
 {
     _characterController = GetComponent<CharacterController>();
     _camera = Camera.main;
     _originalCameraPosition = _camera.transform.localPosition;
     _mouseLook.Init(transform, _camera.transform);
     _fovKick.Setup(_camera);
     _headBob.Setup(_camera, _stepInterval);
     _stepCycle = 0f;
     _nextStep = _stepCycle / 2f;
     _stamina = GetComponent<Stamina>();
     _jumping = false;
     _audioSource = GetComponent<AudioSource>();
     _underWater = FindObjectOfType<UnderWater>();
     _mana = FindObjectOfType<Mana>();
 }
Esempio n. 2
0
 void Start()
 {
     _mana = FindObjectOfType<Mana>();
 }