The faster my character goes the longer he jumps.

Hi I’m making a endless runner/Temple run type game. My only problem so far is that the faster he’s going, The longer he jumps(The character speeds up as he gets farther).
What can I do about this? Im using rigidbody for Jumping.

Are you using the AddForce method? If so, what parameters are you sending to it?

Could you give me an example please @Huacanacha

It would be great if you could include some of your code with the question, so we can see exactly what needs to be done.

Just get the velocity of your player by rigidbody.velocity.magnitude and calculate your desired speed at a point and make a if statement. If velocity is greater than your desired speed add a drag to your player or add a counter force. Hope this helps

Firstly, have you tried other forcemodes for jumpvelocity and gravity? Also, you have AddForce calls in Update(). This is probably not a good idea.

1 Answer

1

Can I see your script for this, I cant get much information from this.