diff options
Diffstat (limited to 'js/magnets.js')
-rw-r--r-- | js/magnets.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/js/magnets.js b/js/magnets.js index 7d82507..c532e74 100644 --- a/js/magnets.js +++ b/js/magnets.js @@ -65,7 +65,7 @@ function draw() safe_zone_radius *= 0.9995; ellipse(mouseX, mouseY, safe_zone_radius, safe_zone_radius); - if ((mouseX > width || mouseY > height) && magnets.length > 0) + if ((mouseX > width || mouseY > height || mouseY < 0) && magnets.length > 0) { gameOver = true; alert("You went out of bounds. Score: " + magnets.length); |