Skip to content

PeTcHeNkA/TestSnakeGame

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TestSnakeGame v1.1

TestSnakeGame is a simple and fun game where you control a snake and try to eat as many carrots as possible without hitting the walls or your own tail.

TestSnakeGame

How to play

  • Use the WASD keys or the arrows on the screen to move the snake around the screen.
  • Eat the orange carrots to grow longer and increase your score.
  • Avoid collisions with the walls or your own tail, or the game will end.
  • To restart the game: Press R.

Installation

  1. Clone the GitHub repository.
git clone https://github.com/PeTcHeNkA/TestSnakeGame
  1. Install the dependencies.
npm i
  1. Review the settings in the start.js file.
var params = {
 // The server port and address
 port: 8000,
 host: "localhost",

 // The root directory
 root: path.resolve("./"),
 file: "index.html",

 // Other options
 open: false,
 ignore: 'scss,my/templates',
 wait: 1000,
 mount: [['/components', './node_modules']],
 logLevel: 0,
 middleware: [function(req, res, next) { next(); }]
};
  1. Start the game.
npm start

About

SnakeGame on JS

Resources

License

Stars

Watchers

Forks

Packages

No packages published