Multidirectionnal Pan scrolling

Hello,

I found a tutorial on your website "**Interactive **Image Panning" with a very nice panning effect. I’m working on panoramic video and I’m trying to do a flash player with a scrolling on the X axis and also the Y. I began to do each variable another time with Y but it don’t works.
Does anyone knows why it doesn’t work?
Here is the code:

[COLOR=#000080]this.onMouseMove = function() {
constrainedMove(bg_mc, 4, 1);
};
function constrainedMove(target:MovieClip, speed:Number, dir:Number) {
var nSpeed_x :Number = 0;
var nSpeed_y :Number = 0;
var nMousePercent_x :Number = this._xmouse/Stage.width;
var nMousePercent_y :Number = this._ymouse/Stage.height;
if (dir == 1) {
nSpeed_x = 1-nMousePercent_x;
nSpeed_y = 1-nMousePercent_y;
} else {
nSpeed_x = nMousePercent_x;
nSpeed_y = nMousePercent_y;
}
target.destX = Math.round(-((target._width-Stage.width)nSpeed_x));
target.destY = Math.round(-((target._height-Stage.height)nSpeed_y));
target.onEnterFrame = function() {
if (target._x == target.destX) {
delete target.onEnterFrame;
} else {
target._x += Math.ceil((target.destX-target._x)
(speed/100));
}
if (target._y == target.destY) {
delete target.onEnterFrame;
} else {
target._y += Math.ceil((target.destY-target._y)
(speed/100));
}
}
}[/COLOR]

Thanks,

Very best