Scroll dynamic image based on xmouse and ymouse

Hi,

I’m trying to change kirupa’s xml gallery to scroll the foto on rollover based on xmouse and ymouse .

here is what im trying to do:
http://www.soromenho.net/thumbnail/thumbnail_final2.swf

of course something is wrong… :blush:

can anyone please help me?

here are the files: http://www.soromenho.net/thumbnail/thumbnail2.zip

thank you so much

Nevermind :slight_smile:

in the “picture” movie clip just used


onClipEvent (load) {
	destX = _x;
	destY = _y;
}



onClipEvent (enterFrame) {
	picW = this._width;
	picH = this._height;
	if (picW>300) {
		posH = picW-320;
		posV = picH-220;
		destX = -_parent._xmouse*posH/300;
		destY = -_parent._ymouse*posV/220;
		if (destX>0) {
			destX = 0;
		}
		if (destX<-posH) {
			destX = -posH;
		}
		if (destY>0) {
			destY = 0;
		}
		if (destY<-posV) {
			destY = -posV;
		}
	
	_x = _x+(destX-_x)*0.100000;
	_y = _y+(destY-_y)*0.100000;
}
}

and its all working fine :slight_smile: