ID:156774
 
As an example. Lets say I have a "Jack in the box". When a user clicks a button, I want it to animate in one direction (pop out). When the user clicks another button, I would like to have it animate back in. I was hoping to reuse the same animation but in reverse. Is that possible?

ts
I don't think so. And if there was a way, it'd most likely be an /icon object function that enables altering animation parameters, in which case you'd still have to use a new icon in the end, which means you're better off caching/pregenerating it anyway, so the altered icon is only created once.
In response to Kaioken
The icon proc can extract a specific frame of an animation. The icon.Insert proc can insert a state to an animation. You should be able to use this to do what you need, but it would probably be easier to manually create the icon state for the reverse animation.

You can also ftp the dynamically created icon to yourself and save it. That way you can use a program to generate it, but you only need to generate it once.
In response to Forum_account
Forum_account wrote:
The icon proc can extract a specific frame of an animation. The icon.Insert proc can insert a state to an animation. [...]

Yeah, you can't simply choose to play the animation in reverse. Animations are one of the things we don't have much control about.

You can also ftp the dynamically created icon to yourself and save it. That way you can use a program to generate it, but you only need to generate it once.

Of course. Or better, when using DM to pregenerate files use fcopy() instead of ftp() to automate it more.
In response to Kaioken
meh... I copied and pasted the animation in reverse.

Thanks,
ts