()
| 96 | } |
| 97 | |
| 98 | function drawBall() { |
| 99 | ctx.beginPath(); |
| 100 | ctx.arc(x, y, ballRadius, 0, Math.PI*2); |
| 101 | ctx.fillStyle = grd; |
| 102 | ctx.fill(); |
| 103 | ctx.closePath(); |
| 104 | } |
| 105 | function drawPaddle() { |
| 106 | ctx.beginPath(); |
| 107 | ctx.rect(paddleX, canvas.height-paddleHeight, paddleWidth, paddleHeight); |