HTML and CSS Reference
In-Depth Information
Code
Explanation
this.moveit = moveball;
this.fillstyle = stylestring;
}
function drawball() {
ctx.fillStyle=this.fillstyle;
ctx.beginPath();
ctx.arc(this.sx,this.sy,this.rad,
0,Math.PI*2,true);
ctx.fill();
}
function moveball(dx,dy) {
this.sx +=dx;
this.sy +=dy;
}
var cball = new Ball(startrockx,startrocky,
ballrad,"rgb(250,0,0)");
function myrectangle(sx,sy,swidth,
sheight,stylestring) {
this.sx = sx;
this.sy = sy;
Search WWH ::




Custom Search