0.0.4 • Published 3 years ago

@hhogg/snake v0.0.4

Weekly downloads
4
License
MIT
Repository
github
Last release
3 years ago

Snake Heuristics is a game for developers to code the behaviour of the snake in the classic point finding game.

The goal is to write a heuristic function that returns a single number. The function is run on every cell on the board (but only the cells around the head of the snake are important). The snake will move to the cell with the lowest number, and will continue to do this while collecting points, until it either crashes or there are no cell left to move to.

The solution is scored in 3 areas: accuracy, speed and efficiency. Basically, the fewer moves the snake takes to reach the point the better. The score grows exponentially with the more points collected and the efficiency has a greater weight at the beginning of the game.

Technology

Setup

Prerequisites

• Node - Either use nvm use or checkout the tested version inside the .nvmrc file.

Setup

Clone the repository

git clone git@github.com:HHogg/circles.git

Install the dependencies with your favourite package manager

yarn install
Running

Spin up the Parcel development server

yarn start
Building

Build the static files using Parcel

yarn build
Deploying

Deploy to Firebase hosting (... after authenticating)

yarn deploy