We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 51e63f0 commit 5f782b2Copy full SHA for 5f782b2
annotated.js
@@ -23,9 +23,9 @@ setInterval(function() {
23
297 < x ? ( // if ball hits bottom border ...
24
1 % (
25
x - 299 - k // calculate distance to paddle center
26
- ) ? // if distance is 0, 1, -1
27
- p : // ... reflect up
28
- -1 // otherwise break the game
+ ) ? // if distance is not 0, 1, -1
+ p : // ... break the game
+ -1 // otherwise reflect up
29
) : Y,
30
31
x += Y * (W + X * Y); // update ball position based on direction
0 commit comments