Advertisement
KAB-A-DAB

Untitled

May 5th, 2016
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.23 KB | None | 0 0
  1. {
  2. grounded = Physics2D.Linecast(transform.position, groundCheck.position, 1 << LayerMask.NameToLayer("Ground"));
  3.  
  4. if (Input.GetButtonDown("Jump") && grounded)
  5. {
  6. jump = true;
  7. }
  8. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement