Crates.io | pagurus |
lib.rs | pagurus |
version | 0.7.4 |
source | src |
created_at | 2022-07-14 12:01:29.654993 |
updated_at | 2023-12-10 10:02:23.422086 |
description | Ultra-portable game engine suited for offline 2D games powered by WebAssembly |
homepage | https://github.com/sile/pagurus |
repository | https://github.com/sile/pagurus |
max_upload_size | |
id | 625657 |
size | 89,777 |
🐚+🦞 Ultra-portable Rust game engine suited for offline 2D games powered by WebAssembly.
Traditional snake game: examples/snake_game
Build the game:
$ 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:
$ cargo run --release -p snake_game --features tui
Run the game on a Web Browser:
$ cd web/
$ npm install
$ npm run build
// A HTTP server listening on 8000 port will start
$ cd ../
$ python3 -m http.server
$ open http://localhost:8000/examples/snake_game/web/