public void Dash() { if (Input.GetKeyDown(KeyCode.LeftShift) && player.CheckST(dashCost)) { dashTime = dashTimeFull; player.stamina -= dashCost; } if (dashTime > 0) { rb.velocity = GetDir() * dashMod * speed; dashTime -= Time.deltaTime; } else { rb.velocity = Vector3.zero; } Debug.Log("Dash" + rb.velocity); }