Giter VIP home page Giter VIP logo

snoke's Introduction

Snóke, old snake game with new ideas

title

The rules of the game

The game has several levels to complete. The goal is simple: find the snake shed skin, eat the exact amount of fruit to reach the size of that skin, and cover it precisely.

  • You lose if you eat to much, bump into the area border, or into yourself

  • Bananas make you move faster (except when you reach your target size)

  • You get bonus points if you eat the next fruit with an optimal path!

Screenshots

game

(v0.1)

Video

https://youtu.be/h1MC9-xDKFA

(v0.1)

Install

Binaries

If you're lucky, you may just download one of the precompiled binaries of the latest release, or one of the latest automatic builds (ubuntu and macos). You will need to have the SDL2 library installed on your system.

From source

It's also easy to build Snóke from source, and it will take care of all dependencies. This requires ocaml, and the opam package manager.

Just do:

opam pin add https://github.com/sanette/snoke.git
opam install snoke

Or, download or clone this repo, cd into the snoke dir, and

opam install .

Then you should be able to launch the game with

snoke

Alternatively, instead of the install step, you can directly run the game with

cd src
dune exec ./snoke.exe

How did you make such a wonderful and entertaining game?

First of all, it's written is ocaml which makes it fun to code! While ocaml is not particularly known for games, I came across this nice blog article by Florent Monnier and realized it would make a good challenge for testing the GUI library Bogue.

You can read here how it all started.

TODO

  • Joystick support
  • DONE (v0.3) First opam package.
  • DONE (v0.2) The snake should have 3 lives before game over
  • DONE (v0.2-halloween-wink) Eat pumkins!
  • More levels
  • High-scores list
  • More fruit with effects
  • Background music(?)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.