View Single Post

  #1 (permalink)  
Old 09-03-08, 18:26
stradiwatt stradiwatt is offline
Junior Member
 
Join Date: Feb 2008
Posts: 16
Rep Power: 0
stradiwatt is on a distinguished road
Question Galleria immagini

ciao a tutti!!!
vDevo chiedervi un aiuto
Volevo riutilizzare una galleria immagini che avevo usato in precedenza.
Il problema che il codice è scritto con Actionscript 2.0.
Se vi posto il codice sapreste aiutarmi?

//////////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////

var imgNum = 6;
var imgwidth = 420;
var imgSpeed = 0.10000000000000001;
var mty = 0;
var mty2 = -imgwidth * imgNum;
MovieClip.prototype.sMove = function(speed, ty) {
getY = speed * (ty - this._y);
this._y += getY;
};
this.upimg.onEnterFrame = function() {
this.sMove(imgSpeed, mty);
};
this.downimg.onEnterFrame = function() {
this.sMove(imgSpeed, mty2);
};
var i = 0;
while (i < imgNum) {
this[("num" + i)].onRollOver = function() {
nowNum = Number(this._name.slice(3, 4));
mty = -imgwidth * nowNum;
mty2 = -(imgwidth * imgNum - imgwidth * nowNum);
};
i++;
}
/////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////
Reply With Quote