大鱼不是头朝鼠标,是尾巴跟着鼠标
momObj.prototype.draw=function()
{
this.x=lerpDistance(mx,this.x,0.99);//运动速度
this.y=lerpDistance(my,this.y,0.99);
var deltaY=my-this.y;//角度差
var deltaX=mx-this.x;
var beta = Math.atan2(deltaY,deltaX);
this.angel=lerpAngle(beta,this.angel,-0.6);
ctx1.save();//表示仅限于适用大鱼
ctx1.translate(this.x,this.y);//移动原点
ctx1.rotate(this.angel);
ctx1.drawImage(this.bigEye,-this.bigEye.width*0.5,-this.bigEye.height*0.5);
ctx1.drawImage(this.bigBody,-this.bigBody.width*0.5,-this.bigBody.height*0.5);
ctx1.drawImage(this.bigTail,-this.bigTail.width*0.5+30,-this.bigTail.height*0.5);
ctx1.restore();
}