I trying to make a gallery thumbnail panel to auto scroll vertical, I did see the great video on the site gotoandlearn called “Scrolling Thumbnail Panel” and base most of my code on it. But this one scroll horizontal on mouse over and is base on Root X of the mouse position.
My scroll movieclip is deep into a other one and I am trying to make it scroll vertical so far its not really scrolling well see the include fla file. :S
This is the code I am trying to use:
stop();
hiddengalbuttons_mc.onRollOver = panelOver;
function panelOver() {
this.onEnterFrame = scrollPanel;
this._parent.gall_but.gotoAndPlay("s1");
delete this.onRollOver;
}
var b = stroke.getBounds(this);
function scrollPanel() {
if (_xmouse<b.xMin || _xmouse>b.xMax || _ymouse<b.yMin || _ymouse>b.yMax) {
this.onRollOver = panelOver;
this._parent.gall_but.gotoAndPlay("s2");
delete this.onEnterFrame;
}
if (this._parent.gall_but.butt_gall.photo._y<=0) {
this._parent.gall_but.butt_gall.photo._y = 0;
}
if (this._parent.gall_but.butt_gall.photo._y>=-411.0) {
this._parent.gall_but.butt_gall.photo._y = -411.0;
}
var ydist = _ymouse-5;
this._parent.gall_but.butt_gall.photo._y += Math.round(-ydist/7);
}
hiddengalbuttons_mc is use to make the thumbnail panel slide in and out on mouse over that all is working so far.
But like I only just learn this mouse related actionscript I am kind of clueless what I am doing wrong
Please please help!
Also is there a way to make this more dynamic?