https://github.com/almarklein/rocket_rust_py
The Rocket game, implemented in Rust, running in Python, via WASM
https://github.com/almarklein/rocket_rust_py
Last synced: about 1 year ago
JSON representation
The Rocket game, implemented in Rust, running in Python, via WASM
- Host: GitHub
- URL: https://github.com/almarklein/rocket_rust_py
- Owner: almarklein
- License: bsd-2-clause
- Created: 2018-05-14T22:17:04.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2023-02-26T15:25:32.000Z (about 3 years ago)
- Last Synced: 2024-07-29T00:52:27.299Z (almost 2 years ago)
- Language: WebAssembly
- Size: 8.12 MB
- Stars: 23
- Watchers: 5
- Forks: 6
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# The Rocket game, implemented in Rust, running in Python, via WASM
A [Rocket game implemented in Rust](https://github.com/aochagavia/rocket_wasm)
is compiled to WebAssembly (WASM). We take the resulting `.wasm` file, and run
it in Python using [PPCI](https://bitbucket.org/windel/ppci/).
* `rocket.wasm`: the wasm module compiled from Rust (by Adolfo).
* `rocket.py`: the Python code to wrap the above in an app.
* `info.py`: print some info about the wasm module.
* `rocket.html`: for reference, the (nearly) original html/js to run the wasm module in the browser (standalone HTML).
In this exercise, we take a wasm module as-is, inspect its imports and exports
(WASM clearly defines these), and use this API to run the module in a Python app.