同跪在这里,怒复制以警示。
老师的重点&&逻辑真是一点也不清楚。。。不管怎样,老师您辛苦了
搞了半天,解决漂浮直线和海葵不透明,在gameloop里面用cxt2画背景图片才能盖住上一帧:
function gameloop(){
cxt2.drawImage(bg,0,0);
ane.draw();
fruit.draw();
}
老师的重点&&逻辑真是一点也不清楚。。。不管怎样,老师您辛苦了
搞了半天,解决漂浮直线和海葵不透明,在gameloop里面用cxt2画背景图片才能盖住上一帧:
function gameloop(){
cxt2.drawImage(bg,0,0);
ane.draw();
fruit.draw();
}
2016-10-21
果实没出来的同学改一下born函数里面的this.y[i]的值,将this.y[i]改大一点就能看见果实了;fruitObj.prototype.born = function(i){
var aneID = Math.floor(Math.random()*ane.num);
this.x[i] = ane.rootx[aneID];
this.y[i] = ane.heady[aneID];
console.log(ane.heady[aneID]);
}
var aneID = Math.floor(Math.random()*ane.num);
this.x[i] = ane.rootx[aneID];
this.y[i] = ane.heady[aneID];
console.log(ane.heady[aneID]);
}
2016-10-19
搞了半天,解决漂浮直线和海葵不透明,在gameloop里面用cxt2画背景图片才能盖住上一帧:
function gameloop(){
cxt2.drawImage(bg,0,0);
ane.draw();
fruit.draw();
}
function gameloop(){
cxt2.drawImage(bg,0,0);
ane.draw();
fruit.draw();
}
2016-10-14
我敲出来的代码 一点没有错 鱼妈妈 就是不要跟着鼠标动 但是可以在原地转圈 查源码搞了好久 之后不明觉厉的可以跟着鼠标动了 过几分钟后又不能了 不知道为什么 到最后试着把相应代码删除再打一边然后保存运行 才可以稳定完全运行了 希望有和我类似的问题的同学 能帮到你。。。 熬夜解决这个搞得熬得好困 。。。不过蛮有意思的啊啊啊啊啊!!!!!谁能懂我。。。。。