//舞台上增加一个mc,实例名:jiba
stage.addEventListener(Event.ENTER_FRAME,enter_frameHandler);
stage.addEventListener(MouseEvent.CLICK,clickHandler);
var sx:Number = 0;
var sy:Number = 0;
function clickHandler(evt:MouseEvent):void
{
sx = evt.stageX;
sy = evt.stageY;
trace("click:" + sx + "," + sy);
}
var juliX:Number = 0;
var juliY:Number = 0;
function enter_frameHandler(evt:Event):void
{
juliX = sx - jiba.x;
jiba.x = jiba.x + juliX/3;
juliY = sy - jiba.y;
jiba.y = jiba.y + juliY/3;
}