vertical line for pong javascript

Solutions on MaxInterview for vertical line for pong javascript by the best coders in the world

showing results for - "vertical line for pong javascript"
Lena
26 Feb 2017
1// define initial player score
2var playerLeft = playerRight = 0
3
4// create text for the score, set font properties
5var scoreLeft = draw.text(playerLeft+'').font({
6  size: 32,
7  family: 'Menlo, sans-serif',
8  anchor: 'end',
9  fill: '#fff'
10}).move(width/2-10, 10)
11
12// cloning rocks!
13var scoreRight = scoreLeft.clone()
14  .text(playerRight+'')
15  .font('anchor', 'start')
16  .x(width/2+10)