h2048-0.4.0.0: README.md
# h2048
[](https://travis-ci.org/Javran/h2048)
A haskell implementation of Game 2048. Including:
* a library for experimenting game strategies for Game 2048.
* a simple program that provides the basic interaction with the game.
* a CUI implemented using [brick](http://hackage.haskell.org/package/brick).
Based on [2048](https://github.com/gabrielecirulli/2048)
# Screenshots
## Simple version

## brick-based version

## Build and run
### With stack
h2048 comes with [stack](https://docs.haskellstack.org/en/stable/README/) configuration,
if you are building from source code, change directory to the project root and run:
```bash
stack build
# to run the brick version
stack exec -- h2048-brick
# to run the simple version
stack exec -- h2048-simple
```
### With cabal
`h2048` is now available on [hackage](http://hackage.haskell.org/package/h2048).
If you have [Cabal](http://www.haskell.org/cabal/) installed,
you can use the following command to install this project:
```bash
cabal update
cabal install h2048
```
The binaries are `h2048-simple` for simple CUI version, `h2048-brick` for CUI version
implemented using `brick`.
## How to play
keys:
* `q`: quit
* `i`: up
* `k`: down
* `j`: left
* `l`: right
If you are using `h2048-brick`, you can also use arrow keys.