My character's jump animation play's when it's not suppose to?

Hey, so I’ve been noticing a problem that I can’t really figure out how to fix.So whenever my character jumps it registers that my character is falling, so it plays the jump animation. However, when my character walks off of a ledge or after using the air boost, it plays the jump animation again. I want it to go straight back into the falling animation. Is there a way to fix this?

In the images below, I have my jump animation set up basically to play whenever it registers that my character is falling, so right when I jump it plays the jump animation. I only have it set up like this because this was the only way I could find to make my character play the jump animation whenever it jumps that worked properly; all the other ways I tried didn’t work at all or had certain mistakes. So I was wondering if anyone knew how to keep it from playing the jump animation whenever my character just walks off an edge and after he does the forward air boost thing.

Hi Josh, try this:

  1. Change the name of your “Is Jumping” bool to “Is Falling” (to avoid confusion)
  2. Create a new bool called “Is Jumping” (you’ll need to use both of these variables)
  3. When you jump (ex: press space bar, or whatever your jump button is) set “Is Jumping” to true
  4. Set “Is Jumping” to false after the jumping animation is finished

You will also need to edit your Animation Blueprint and the transitions in-between each animation, that may end up looking something similar to this:

272528-animblueprint.png

Try it out! If you still can’t get it to work then post a screenshot of your Animation Blueprint. Good luck!

Another alternate solution could be to simply store the Z Velocity of your character, and test to see if it is positive (jumping) or negative (falling). Sorry to give multiple answers, but there’s almost always more than one way to do these types of things.

Sorry for not replying for so long! And alright, sounds good! But if I make it to where the jump animation plays as long as the character is falling and the space bar is pressed, won’t the jump animation keep playing if I press space in the air, even if my character doesn’t have any more jumps left? Is there a way to fix that and keep that from happening? I only want it to play for that one jump.

That’s a good point. Make changes to your event graph so that it only changes “Is Jumping” from false to true when the player presses space bar AND when “Is Falling” is false.