i create widget button for character attack , attack animation working good . but when , i clicked again on “attack widget button” it doesn’t work . please see my screenshots , What is problem ?
Have you tried using a Montage instead?
It seems you are never get back to idle, you are still in attack animation after attack which isnt in loop because you cant enter to idle because you not setting attack to false… set timer to blueprint and after timer reset attack boolean to false.
When i use keyboard for exam , Tab key for attack , attack can get back to idle , but with widget button no !
Show please widget bp. Because at first bp pic you are not setting attack to false…
It’s here . I’m a beginner and i don’t understand you mean about " setting attack to false"
[/QUOTE]
When you press button, you cast character to ThirdPersonCharacter - this return you always TRUE unless your pawn does not exist, so after pushing attack button, “attack” boolean is still true, so your animation wont go to idle.
Try this:
- Create function in character BP (for example “attack from widget”),
- Inside function: set attack to true, delay 1 ssecond, set attack to false
- Call that function (cast to third person character -> call “attack from widget”) from widget.
edit: look at your “input action attack”. On pressed -> you setting attack to TRUE, On released, you setting attack to FALSE, this is what i mean what is missing in your widget bp (setting to false).
I create partially this function on my thirdpersoncharacter BP and call that function in widget BP . but delay on function ? i searching about delay in function in google , i didn’t get good results
Ye sorry, create custom event.
Thank you very very much . It works very well .








