Jump to content
This site uses cookies! Learn More

This site uses cookies!

armedunity.com uses cookies to improve user experience.

By continuing to use this site, you agree to allow us to store cookies on your computer.

  • 0
Sign in to follow this  
enkantar

help with jump script

Question

Hi there, i made a personal character motor based on rigidbody, but i've a problem.

I made a boolean variable "isJumping" and I set it as true OnCollisionExit, and I set it as false OnCollisionEnter.

The problem is that if the player also collide with a gameObject like a building, it start to make something similiar to climbing and he don't stop jumping.

How could I solve it?

Thank you very much.

Share this post


Link to post
Share on other sites

4 answers to this question

Recommended Posts

  • 0
Please login or register to see this quote.

you can use raycast to check if you are grounded or not.

Share this post


Link to post
Share on other sites

  • 0
Please login or register to see this quote.

Please login or register to see this code.

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

×
×
  • Create New...