5c1600926e
* Update dependencies - Closes #270 * Unify controls in Invaders example The fire button on gamepads was allowing trapid fire when holding the button. Keyboard controls required the fire key to be released between each shot fired. This commit fixes the difference by making the gamepad fire button act like the keyboard fire key. |
||
---|---|---|
.. | ||
src | ||
Cargo.toml | ||
index.html | ||
README.md |
Hello Pixels + Web
Minimal example for WebGL2.
Install build dependencies
Install the WASM32 target and a few CLI tools:
rustup target add wasm32-unknown-unknown
cargo install --locked wasm-bindgen-cli just miniserve
Running on the Web
Build the project and start a local server to host it:
just serve minimal-web
Open http://localhost:8080/ in your browser to run the example.
To build the project without serving it:
just build minimal-web
The build files are stored in ./target/minimal-web/
.
Running on native targets
cargo run --release --package minimal-web
About
This example is based on minimal-winit
, demonstrating how to build your app for WebGL2 targets.