Scroll
Anyone know how to make an Animate CC HTML5 animation become a scrolling site rather than a movie that plays?
Like this (or the hundreds of other sites that advance when you scroll)?
Anyone know how to make an Animate CC HTML5 animation become a scrolling site rather than a movie that plays?
Like this (or the hundreds of other sites that advance when you scroll)?
use something like,
this.stop();
canvas.addEventListener("mousewheel", MouseWheelHandler.bind(this));
canvas.addEventListener("DOMMouseScroll", MouseWheelHandler.bind(this));
function MouseWheelHandler(e) {
if(e.wheelDelta>0){
this.gotoAndStop(this.currentFrame+1);
} else {
this.gotoAndStop(this.currentFrame-1);
}
}
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.