public void Initialize() { playerManager = GetComponentInParent <PlayerManager>(); anim = GetComponent <Animator>(); inputHandler = GetComponentInParent <InputHandler>(); playerLocomotion = GetComponentInParent <PlayerLocomotion>(); vertical = Animator.StringToHash("Vertical"); horizontal = Animator.StringToHash("Horizontal"); }
// Start is called before the first frame update void Start() { inputHandler = GetComponent <InputHandler>(); anim = GetComponentInChildren <Animator>(); playerLocomotion = GetComponent <PlayerLocomotion>(); }