summaryrefslogtreecommitdiff
path: root/js/magnets.js
diff options
context:
space:
mode:
authorpommicket <leonardomtenenbaum@gmail.com>2016-08-31 14:58:23 -0400
committerpommicket <leonardomtenenbaum@gmail.com>2016-08-31 14:58:23 -0400
commita982632b1cc3218d74acec2b5f6a69ffc5e97ead (patch)
treed7a7761c1a905450c3d57f4ae75048616850c06b /js/magnets.js
parentafff994f985121e89de4b1e3bb509b62eb956e5a (diff)
Cleaned up code and improved website layout.
Diffstat (limited to 'js/magnets.js')
-rw-r--r--js/magnets.js2
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);