Skip to content

kevinmm19/snake

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Snake Game

Snake is ​​the​ ​classic​ ​arcade​ ​game​​ ​in​ ​which​ ​a​ ​player​ ​controls​ ​a​ ​snake ​guiding​ ​it​ ​towards food​ ​and​ ​away​ ​from​ ​walls​ or itself.​

Usage

The​ ​game​ ​should​ ​listen​ ​to​ ​the​ ​arrow​ ​keys,​ ​and​ ​the​ ​snake should​ ​grow​ ​as​ ​it​ ​consumes​ ​food.​ Everytime the snake eats food the score on screen increases by 10. ​

When​ ​the​ ​snake​ ​collides​ ​with​ ​itself​ ​or​ ​a​ ​wall,​ ​the​ ​game​ ends. The final score is displayed on screen and a message to refresh the page is given.

Play it live: Snake

Tech Stack

  • HTML5
  • CSS
  • Vanilla JavaScript

Project Structure

  • css
    • style.css
  • js
    • snake.js
  • index.php
  • README.md

Notes

Rename index.php file to index.html to play game on your local computer.

About Me

Kevin Martínez Montero

Senior Front End Engineer