H5-Animation
H5-Animation copied to clipboard
发现小bug
鼠标跟随那个;当箭头在原地时,箭头不停地来回变换方向,这是个bug;解决方案。在arrow.x += vx;这一句之前加上if(Math.abs(dx) < speed && Math.abs(dy) < speed){vx = 0;vy = 0;} 当然这是在speed数值较小时,较大时我也暂时不知道怎么做,希望有高人指点。
不好意思最近有点忙,已经做调整。
在 2016-09-13 15:48:52,"方贤正" [email protected] 写道:
鼠标跟随那个;当箭头在原地时,箭头不停地来回变换方向,这是个bug;解决方案。在arrow.x += vx;这一句之前加上if(Math.abs(dx) < speed && Math.abs(dy) < speed){vx = 0;vy = 0;} 当然这是在speed数值较小时,较大时我也暂时不知道怎么做,希望有高人指点。
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.