Sync run and runshooting animation

Hi mates for my new game I have a run animation and runshoot animation so when the character is running and z is pressed I want to synchronize the two animations for instance in Conartruct2/3 there is an specific action to do this (play from current frame)

If I’m running and press one time the (z) then is good, but if I press (z)(z)… repeatedly then only the first frame of the runshoot animation plays
See here

Here the events involved:

Shoot logic

Floor logic

As you can see I’m trying to save the current frame and pass that current frame to the next animation but it doesn’t work as I expect to.

Thanks for your help.

The problem is the “Set animation of Player to …” also resets the frame to 0.

I’d look at adding a trigger once on the PlayerHitbox is moving (and the inverted event), and move the “Change the animation frame of Player…” straight after the “Set the animation of Player…”.

Here’s a Mega Man-style example:


Attach two sprite sets to the hitbox: One for the non-shooting sprites and another for the shooting sprites.