[Solved] Problem with attack animation being stuck at Frame 0


#1

I know I’ve been kind of a nuisance on this forum, but…

I have a problem with attack animation. I want it to play completely after pressing a button WHILE running.
So if the player is running AND presses B button, then the player sprite shows attack animation.

The problem is that when I try to do it only the first frame plays and only when the button is being pressed.
I want it to just play the full animation once, regardless if the player presses the button for a while or for a minute.

I’d show a screenshot of what I’ve tried, but… it’s such a mess that there’s no point.

Can anyone help?


#2

I have to see the events to help you


#3

image


#4

I think I have to see .Player sprite picture also like this one


#5

The animation seems to be in order (p1_run)
image


#6

Where is the fight animation?


#7

image
here


#8

ed5e037791df84e580cba2dabe61a8bf7ecffae4
Add a command here named Tigger once.


#9

I’ve tried this before. It’s even worse because the first frame of the animation shows up for half a second.


#10

Well give me some time.I need to try this by myself.


#11

You need set the animation (already done), and start playing the animation once.


#12

I think this is what you need https://youtu.be/soavy3n-08w


#13

This is perfect. On top of that, it also helped me figure out a couple of things.
Many thanks!


#14

Well I also have the same issue my players idle animation consist of many sprites so when I press b on my keyboard which is suppose to trigger the attack animation nothing happens please help


#15

I have reviewed the image of the events, you have to read the events and think about the logic that goes with them and it’s normal that it doesn’t work.

If player is on floor, the animation change.
AND if player moving, the animation change.

We have a conflict here.
You need to condition when the player moves on the ground.

Look at the example Platform, it seems to me that the animation system works the way you want to do it.


#16

No not that way I need it to play a Sprite animation when a button is clicked knowing that the idle Sprite is set to loop


#17

Hi i came here looking for help on the same issue. accept its not my main character its an enemy. Has anyone offered any advice to help you solve it yet? I am currently testing out a solution if it works I’ll share my method.