pagurus
========
[](https://crates.io/crates/pagurus)
[](https://docs.rs/pagurus)
[](https://github.com/sile/pagurus/actions)

🐚+🦞 Ultra-portable Rust game engine suited for offline 2D games powered by WebAssembly.
Examples
--------
### Snake
Traditional snake game: [examples/snake_game](examples/snake_game)
#### How to build and run locally
Build the game:
```console
$ cargo build --release -p snake_game --target wasm32-unknown-unknown
$ ls target/wasm32-unknown-unknown/release/snake_game.wasm
```
Run the game on the terminal:
```console
$ cargo run --release -p snake_game --features tui
```
Run the game on a Web Browser:
```console
$ cd web/
$ npm install
$ npm run build
$ npm run example // A HTTP server listening on 8888 port will start
$ open http://localhost:8888/examples/snake_game/web/
```
Projects that use Pagurus
-------------------------
- [sile/pixcil](https://github.com/sile/pixcil): Pixel Art Editor
- [sile/ffmml](https://github.com/sile/ffmml): An MML(Music Macro Language) Implementation
- [sile/mineplacer](https://github.com/sile/mineplacer): A variant of Minesweeper game