Calling a function on enter frame frame (HTML5 canvas)
Hi,
I have a newbie question.
I want to define and execute a function and apply that code it to a frame in the timeline.
Previously, I've used the same function on a button click event:
this.button_name.on('click', function ()
{
var randomframe = Math.floor(Math.random() * _this.movieclip.totalFrames);
_this.movieclip.gotoAndStop(randomframe);
});
How do I modify the above so that it executes upon entering a frame instead of a click event?
