Dependencies:   mbed

Revision:
9:f0213e632379
Parent:
7:c67a5c6a874f
Child:
10:3958fb08696d
--- a/SnakeHead/SnakeHead.cpp	Thu May 21 14:16:51 2020 +0000
+++ b/SnakeHead/SnakeHead.cpp	Fri May 22 11:08:40 2020 +0000
@@ -18,7 +18,7 @@
     _y = HEIGHT/2 - _size/2;
     
     srand(time(NULL));
-    /*int direction = rand() %4;
+    int direction = rand() %4;
     
     if (direction == 0) { //snake moves north
         _velocity.x = -_speed;
@@ -35,7 +35,7 @@
     else { //snake moves west
         _velocity.x = 0;
         _velocity.y = -_speed;
-        }*/
+        }
 }
 
 void SnakeHead::draw(N5110 &lcd) {