I use this code for some animations. What it does is receive a button constant(Ex: #LEFT) and restore animation values for that. Then, it store the animation on an array and run it if the array isn't empty.
Finally I store the button on the anim% to knew what is the current animation.
The part that is missing on the function are labels and end:
@UP
DATA 10,11,-1
...
END

プレイ済み