@Ninjadoodle not exactly, but you can set stop actions to specific frames, which will execute Event.COMPLETE, in which callback you can do what you want and decide to run animation further or go to other animation, etc.
could you provide an example where you would want to use it?
for example, if you would use it in enterframe, there is no guarantee that you would event catch the specific frame you need, it might be skipped due to low fps, etc.
Basically it would be unreliable in such way to use it.
I'm thinking more along the lines of using a movieclip to store images. Let's say I have 10 diff aliens in a scene. All the same movie clip, just different frames. Now I want to check whether the alien you clicked is frame 2, 3 or so on.
Another example is a lightswitch. I know I can set a on / off property to true or false, but I could also check the current mc frame.
I used Flash a lot, so I'm it's to this kind of workflow. To sum it up ... I'm using this more in an onTouch / mouse down situation.
I looked at using MovieClip in my game but decided against it because I need my animation frames to be able to be offset on their x and y axis, and MovieClip doesn't seem to support that.
Because I mainly use it to store store several variations of images, for example (a lever in up , middle and down positions), all I do is just increment a variable each time the movie clip is pressed.
This way I can check the variable instead of the mc frame.
I haven't tried with a timer or checking for frames while the animation is running.
Having the frame property would be really useful I think
Comments
Thank you for the help It's not a big issue, as I'm using a workaround which is petty simple.
Is there any chance of something like this being added in the future?
I think it would be really useful to have a .currentFrame property.
for example, if you would use it in enterframe, there is no guarantee that you would event catch the specific frame you need, it might be skipped due to low fps, etc.
Basically it would be unreliable in such way to use it.
Another example is a lightswitch. I know I can set a on / off property to true or false, but I could also check the current mc frame.
I used Flash a lot, so I'm it's to this kind of workflow. To sum it up ... I'm using this more in an onTouch / mouse down situation.
Thank you again!
Likes: antix
Because I mainly use it to store store several variations of images, for example (a lever in up , middle and down positions), all I do is just increment a variable each time the movie clip is pressed.
This way I can check the variable instead of the mc frame.
I haven't tried with a timer or checking for frames while the animation is running.
Having the frame property would be really useful I think
Likes: totebo