void Update() { if (model == null) { return; } float currentHorizontal = Input.GetAxisRaw(horizontalAxis); model.TryMove(currentHorizontal); if (Input.GetButton(attackButton)) { model.TryShoot(); } if (Input.GetButtonDown(aimButton)) { model.StartAim(); } if (Input.GetButtonUp(aimButton)) { model.StopAim(); } if (Input.GetButtonDown(jumpButton)) { model.TryJump(); } }
void Update() { if (model == null) { return; } float currentHorizontal = UnityEngine.Input.GetAxisRaw(horizontalAxis); model.TryMove(currentHorizontal); if (UnityEngine.Input.GetButton(attackButton)) { model.TryShoot(); } if (UnityEngine.Input.GetButtonDown(jumpButton)) { model.TryJump(); } }