Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if ((Input.GetKey (KeyCode.W)||Input.GetKey (KeyCode.UpArrow)) && (jumpTimer > 0)) {
- rigidbody2D.AddForce (new Vector2(0f,jumpForce));
- }
- if (grounded == false) {
- jumpTimer -= Time.deltaTime;
- } else
- {
- jumpTimer = per;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement