Kick Animation wont play

I have set up a kick animation to play. I have done almost everything correct, but have isolated the problem to the animBP Event graph. I am not sure if i have connected it correct, but it’s firing constantly in both A/B in the FlipFlop.

Before you ask if I have everything set up in the character BP, the Project settings, the anim montage etc etc, I have.
I just can’t seem to figure out how to set it up in the animBP, As you see I have the punch set up and is firing too, and it works without a problem. But the kick animation doesn’t play, even when I deleted the cast to mycharacter punch setup and had solely the kick setup left.

Ps. the Cast failed node connected to the other cast to mycharacter is just a mistake, so ignore it haha

Kind Regards

Is the slot set correctly?

I’ve found sometimes, it didn’t save the first time when I set it in the AnimMontage. That would be the first thing I looked at if another Montage was playing correctly.

Yes, sadly it is correctly set and it wont work :confused:

Can anyone take a look on the image and try to help me indetify what the issue is? Why isn’t it playing the Anim?

Cheers

did you set up the anim montage slot in the anim grapgh??
on your character animation blueprint

Yes I set it up on both. Am I correct in assuming I can assign the slot whatever name as long as it is assigned in both the AnimBP and in AnimMontage?

Is there anyone who can shed some light on this?

Thanks in advance

I dont use montages much… I think I have one total at the moment to hold a pistol while keeping the legs moving when walking and firing. But I do have a kick animation in my game.

I did it with just the straight animation as a state
If its a single kick you want to loop when the user hits the “kick button”.
In the characterBP, set an input to “kick”
When they press it, set the kick variable
On released, add 0.5 sec delay and then unset kick
In the animBP cast to MyChar get the kick variable and set it as a local animBP variable (as you’re doing)

Then in your state machines, drag the kick animation out and as a rule to enter that state from idle, set it to speed less than or = 0 (for a standing kick, so hes not skating around while kicking) and local kick variable is true.

for exit back to idle, say time remaining on the kick animation ratio is less then 0.1.

you can play with the rules a bit. but that worked for me.

I have redone my entire project so I’ll try this soon as I have fixed some things, but from what I have learned since I first posted this I can see that your answer would work, so I have set this as a correct answer