diff --git a/snake_arduino/snake_arduino.ino b/snake_arduino/snake_arduino.ino index 652a0c2..c0d0653 100644 --- a/snake_arduino/snake_arduino.ino +++ b/snake_arduino/snake_arduino.ino @@ -63,11 +63,7 @@ void setup() { randomSeed(analogRead(0)); } -void game_over() { - // show gameover frame - matrix.loadFrame(frame_game_over); - delay(1000); - +void show_points_inside_matrix() { // show points inside the matrix // clear the old frame for (int i=0; i < 12; i++) { @@ -87,6 +83,13 @@ void game_over() { running= false; } +void game_over() { + // show gameover frame + matrix.loadFrame(frame_game_over); + delay(1000); + show_points_inside_matrix(); +} + void add_tail_block() { snake_len++;