Ren'Py supports web builds through its Emscripten-based HTML5 export. The output is a folder of HTML, JS, WASM, and game data that Wavedash hosts directly. Ren'Py 8.6 and later include native Wavedash support for initialization, achievements and stats, player identity, cloud saves, the overlay, and loading progress.
View example project on GitHub Playtest the example projectPrerequisites
- Ren'Py SDK (8.6 or later)
- The Ren'Py web platform package installed into the SDK (download from the same page; it unpacks a
web/folder into the SDK root)
Build for web
From the Ren'Py launcher: select your project → Build Distributions → check Web → build to a destination folder.
From the command line:
"$RENPY_SDK/renpy.sh" launcher web_build ./my-project --destination ./build
The output contains index.html, renpy.wasm, renpy.js, game.zip, and icons. Point upload_dir at that folder.
wavedash.toml
Declare the build as Ren'Py explicitly. Wavedash does not infer the engine by inspecting the exported files.
game_id = "YOUR_GAME_ID_HERE"
upload_dir = "./build"
[renpy]
version = "8.6.0"
executable = "game.zip"
The [renpy] section makes the CLI upload the build with engine=RENPY. Without it, the build is treated as a custom HTML game and the Ren'Py loading integration is not enabled. Set version to the Ren'Py version used to create the export.
Loading progress
You don't have to wire this up. For builds uploaded with the [renpy] section, Wavedash adds ?engine=RENPY to the game frame and installs a progress shim that watches Ren'Py's own boot phases: engine download, game-data download, unpacking, and script loading. Ren'Py signals when the display is ready, and Wavedash then dismisses the loading overlay.
Initialization
Ren'Py initializes Wavedash automatically when its display starts. You do not need to call Wavedash.init(), add a before_main_menu label, or ship a Wavedash-specific .rpy file. Developer mode is forwarded to the SDK's debug setting.
The integration is inactive outside Wavedash. You can use wavedash.is_active when a screen or code path should only appear on Wavedash; the helper functions themselves safely do nothing on other platforms.
Calling Wavedash
Ren'Py exposes the common platform functions through its wavedash namespace. Unlocking an achievement:
$ wavedash.set_achievement("first_chapter_complete")
Reading the current player:
$ user_id = wavedash.get_user_id()
$ username = wavedash.get_username() or "Player"
$ avatar_url = wavedash.get_user_avatar_url(user_id)
The native helpers include:
| Helper | Purpose |
|---|---|
wavedash.set_achievement(identifier) | Unlock an achievement |
wavedash.get_achievement(identifier) | Read an achievement's current state |
wavedash.set_stat(identifier, value) | Set a numeric stat |
wavedash.get_stat(identifier) | Read a numeric stat |
wavedash.get_user_id() | Get the current player's ID |
wavedash.get_username(user_id=None) | Get the current player or another player's username |
wavedash.get_user_avatar_url(user_id, size=128) | Get a player's avatar URL |
wavedash.get_launch_params() | Read this session's launch parameters |
wavedash.toggle_overlay() | Open or close the Wavedash overlay |
The integration also registers Wavedash as a Ren'Py achievement backend, so calls such as achievement.grant(...) are forwarded automatically. Ren'Py's save directory is pulled from cloud storage during startup and uploaded after each save.
For SDK features without a native helper, use the documented renpy.emscripten module to call the injected JavaScript SDK:
$ renpy.emscripten.run_script("window.Wavedash?.someMethod()")
See the SDK function reference for the full JavaScript API.
Fullscreen
Use Ren'Py's normal fullscreen preference:
screen fullscreen_button():
textbutton "Fullscreen":
action Preference("display", "fullscreen")
Wavedash patches the iframe's standard browser fullscreen API and forwards Ren'Py's request to the host page, keeping the Wavedash overlay above the game. The same preference works on Wavedash and other web hosts; no platform-specific fullscreen button is needed.
Notes
- Template screens required: Real Ren'Py games include
game/screens.rpy,game/gui.rpy, andgame/gui/images from the SDK template. If you started from a barescript.rpy, the ESC menu (Save / Load / Preferences) will be missing. - Web build size: Ren'Py web builds can be 50MB+ with audio/image assets. Compress audio to OGG and resize images for web before building.