Center to Stage

Now, I was just playing a little around with some Stage scripting, when I decided it could be fun to make an AS, that, when the window (e.g. the internet explorer window) is resized by the user, then the content - dynamically loaded content - is sliding to the center of the screen.

I got the function to work, almost. The content is loaded into a movieClip, with the instance name: “mc” (very original;)). And the “mc” is moving to some center point, but not the center of the screen.

My AS:
[AS]loadMovie(“test.swf”, mc);
onEnterFrame = function () {
mc.xMove = (Stage.width)/2;
mc.yMove = (Stage.height)/2;
};[/AS]And then I added a little easing to the move, I just wrote the code on the “mc”, here it is:
[AS]onClipEvent (load) {
xMove = _x;
yMove = _y;
easeSpeed = 10;
}
onClipEvent (enterFrame) {
_x += Math.round((xMove-_x)/easeSpeed);
_y += Math.round((yMove-_y)/easeSpeed);
}[/AS]The test.swf is 400px X 400px, can anyone help me out on this?