TheSnake Game

The classic game

Bootstrap Logo
snake game

This is a responsive version of the classic snake game created using only HTML, CSS, and Javascript. The game was challenging but fun to make at the same time. It shows off the use of a game loop to update the page. The rate of expansion and snake speed can be adjusted by simply changing either the snakeSpeed or expansionRate constants in the game.js file. The score is implemented on the page using DOM manipulation. I used AlertifyJS for the postgame confirmation box, and added sound effects when food is eaten and when the game ends. My high score is 280... can you beat it?

Visit Site View Code