I literally just did this, lol. This is what I did:
rem initialize last/first frame with
rem last/first frame of running animation
firstframe =
lastframe =
if object frame(1) <= lastframe
reverse = 0
set object speed 1,5
play object 1,lastframe,firstframe
reverse = 0
endif
if reverse = 0
reverse = 1
set object speed 1,-5
set object frame 1,210
play object 1
endif
I took out a lot of my code on here, so you may have to alter a couple things, but this worked great for me so hopefully it'll help.
This was also only for one play, you'll have to change a couple things to make it loop
The fastfood zombie killer