https://github.com/jsyrjala/jumper
Platformer game with zig and WASM-4. Nitor codecamp.
https://github.com/jsyrjala/jumper
wasm wasm-4 webassembly zig
Last synced: about 2 months ago
JSON representation
Platformer game with zig and WASM-4. Nitor codecamp.
- Host: GitHub
- URL: https://github.com/jsyrjala/jumper
- Owner: jsyrjala
- Created: 2022-05-18T16:35:35.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2022-05-22T06:56:56.000Z (about 4 years ago)
- Last Synced: 2025-03-25T13:47:55.462Z (about 1 year ago)
- Topics: wasm, wasm-4, webassembly, zig
- Language: Zig
- Homepage:
- Size: 110 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# jumper
A game written in [Zig](https://ziglang.org/) for the [WASM-4](https://wasm4.org) fantasy console.
Running in https://jsyrjala.github.io/jumper/

## Development
Install Zig: https://ziglang.org/download/
Install WASM-4:
```shell
npm install wasm4
```
Run development server:
```shell
w4 watch
```
For more info about setting up WASM-4, see the [quickstart guide](https://wasm4.org/docs/getting-started/setup?code-lang=zig#quickstart).
## Building
Build the cart by running:
```shell
zig build -Drelease-small=true
```
Then run it with:
```shell
w4 run zig-out/lib/cart.wasm
```
## Bundling
Bundling creates a single all-in-one HTML file that can be deployed to web server.
```shell
w4 bundle --html zig-out/index.html --title Jumper --description "Simple platformer" zig-out/lib/cart.wasm
```
## Links
- [WASM-4 Documentation](https://wasm4.org/docs): Learn more about WASM-4.
- [Zig documentation](https://ziglang.org/documentation/0.9.1/): Learn more about Zig.