Opinionated template for buiding games in Rust with Macroquad, specfically focused on targeting the web and PC.
🚨 work in progress, scripts best on Linux & macOS currently 🚨
- gamepad support for desktop and web
- scripts for generating cross-platform builds
- game settings
- easy save data (supports web too!)
- draws to a 1280x720 render target by default
- generate list of open source licenses for used crates
- helpful utility functions
- shell scripts for doing pretty much everything, they don't work on Windows
- easily push your game to itch.io
Use the template feature on GitHub or just download the zip
In debug builds, Shift + Esc quits quickly.
- Run
./serve_wasm.sh
to boot a web server (run./deps.sh
first) and then./build_wasm.sh
to update the WASM build - the JS shims in web are explicitly checked in in case the hosted versions disappear & to have versions match
WASM builds can be built and pushed by running:
./release_wasm.sh
Ideally in the future this would push builds for desktop operating systems, create tags, etc., but this works for development.
macOS uses cargo bundle:
- Install cargo bundle:
cargo install cargo-bundle
- Build the bundle:
cargo bundle --release
There's a release_macos.sh
script to build and upload a Universal app for macOS (works on both Intel and Apple Silicon Macs).
Not ideal but functioning
cargo run --release
mkdir win
cp .\target\release\sokoworld.exe .\win\
- copy the assets folder into the
win
dir - zip it up
- upload it to itch.io manually
Run the script:
./release_linux.sh
The Macroquad Quickstart template code and assets are released into the Public Domain.