Help seeing flaw in jumping logic

I have a double jump script (and jump longer as button held) but it doesn’t work consistently.

I’d jump fine first three times but it’ll randomly it won’t run. I can’t consistently duplicate this bug.

I’ve noticed if I stream on discord or something it works even less (weird as hell). Can someone have a quick look to see where my logic is flawed??

I would really appreciate any help.

For help, you’ll need to post more details. What does your code look like? How is your character’s GameObject set up, with what components?

1 Like

Hi @CheMBurN
“I’d jump fine first three times but it’ll randomly it won’t run”

This sounds like you could be doing something input related in FixedUpdate. Or maybe you are detecting ground contact so that it doesn’t register in every case on uneven terrain…

“Can someone have a quick look to see where my logic is flawed??”

You should share your code here in code tags, otherwise everyone will be guessing what you have done.

1 Like

Sorry! I didn’t see the replies! Yeah it was definitely a problem with update/fixed update. The stream was causing my fps to drop the inputs kept missing frames. Thanks for the assist both!

1 Like