How to wait until end of an animation?

Im new to ue4, and Im currently working on making a simple survival game. In the game, I want the player to click/hold the mouse button, and the character will punch/attack until they let go of the mouse button. Ive created a blueprint script to do this, but the character stops punching as soon as I let go, instead of finishing the punch animations. This ends up looking glitchy and unprofessional. Ive tried using a delay the length of the animatiom, but the problem there is that if I let go of LMB halfway through the animation, the animation finishes, and then the character freezes at the end of the animation for the remainder of the delay. So my question is how do I create a delay that only lasts until the punch animation ends?

Anyone know?

even if you aren’t 100% i would appreciate any tips or insight as its kinda holding up this part of my project.

Did you try using animation blueprint and control your animation with parameters?

Why not using animatiom BPs and Montages for all that? Check the BP 3rd person tutorial:
https://www.youtube.com/watch?v=hRO82u1phyw

For anyone looking at this wondering how I got it working, I did it using the Time Remaining node in the animbp state machine.

https://docs.unrealengine.com/en-us/Gameplay/HowTo/CharacterMovement/Blueprints/AnimBlueprint_Jump

After that I ditched the Play Animation functions in my event graph and instead made a couple variables to trigger the state change. Hope this helps somebody

1 Like

hey, what happened with the play animation node in Unreal Engine 4.21?