HTML5 canvas looping animation using code
Hi!
I'm new to animate html5! I have some prior experience coding with Action Script but it's been a few years so I'm pretty rusty.
If anyone has any beginner tutorials they could point me toward that would be awesome!
Now to my question: I have a movie clip that I'm bringing onto the stage with 'addChild' and another movie clip in there with a timeline. I'm wondering how to control the nested movie clip and loop it at a certain point? This is the code I've got so far. I just can't seem to get the if statement to work
var Cover = new lib.cover_mc();
createjs.Ticker.on("tick", animLoop);
this.addCover = function () {
this.addChild(Cover);
}
this.addCover();
function animLoop(e) {
if (Cover.bee_mc.currentFrame("endLoop")) {
Cover.bee_mc.gotoAndPlay("startLoop");
}
}
