Beispiel #1
0
        private void Awake()
        {
            _fixedJoystick = FindObjectOfType <FixedJoystick>();

            _playerAnimator  = GetComponent <PlayerAnimator>();
            _playerFighter   = GetComponent <PlayerFighter>();
            _playerMover     = GetComponent <PlayerMover>();
            _playerInventory = GetComponent <PlayerInventory>();
        }
Beispiel #2
0
        private void LoadComponents()
        {
            _attack = GetComponent <Combat.Attack>();
            Debug.Assert(null != _attack, $"Attack component missing on {name}.");

            _playerAnimator = GetComponent <PlayerAnimator>();
            Debug.Assert(null != _playerAnimator, $"PlayerAnimator component missing on {name}.");

            _rb = GetComponent <Rigidbody>();
            Debug.Assert(null != _rb, $"RigidBody component missing on {name}.");
        }
Beispiel #3
0
        private void LoadComponents()
        {
            _playerAnimator = GetComponent <PlayerAnimator>();
            Debug.Assert(null != _playerAnimator, $"PlayerAnimator component missing on {name}.");

            _movement = GetComponent <PlayerMovement>();
            Debug.Assert(null != _movement, $"PlayerMovement component missing on {name}.");

            _jump = GetComponent <PlayerJump>();
            Debug.Assert(null != _jump, $"PlayerJump component not present on {name}.");

            _attack = GetComponent <PlayerAttack>();
            Debug.Assert(null != _attack, $"PlayerAttack component not present on {name}.");
        }
 private void Awake()
 {
     _playerAnimator = GetComponent <PlayerAnimator>();
     _playerFighter  = GetComponent <PlayerFighter>();
 }