netplay: session save to disk (host) [issue-3] #13
Closed
pbwraith
wants to merge 1 commits from
issue-3 into main
pull from: issue-3
merge into: pbwraith:main
pbwraith:main
pbwraith:issue-23
pbwraith:issue-8
pbwraith:issue-20
pbwraith:issue-19
pbwraith:issue-4
pbwraith:issue-16
pbwraith:issue-2
pbwraith:issue-1
pbwraith:issue-7
pbwraith:issue-6
pbwraith:issue-5
1 Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
15fc132cf2 |
netplay: session save to disk (host) [issue-3]
Some checks failed
Rust-lint / lint-linux (pull_request) Failing after 1s
Rust / build-linux (linux-x86_64, X64, ubuntu-24.04, x86_64-unknown-linux-gnu) (pull_request) Failing after 1s
Rust / build-android (29.0.14206865, ubuntu-24.04, 33) (pull_request) Failing after 1s
Rust / build-linux (linux-aarch64, ARM64, ubuntu-24.04-arm, aarch64-unknown-linux-gnu) (pull_request) Has been cancelled
Rust / build-windows (windows-aarch64, woa64, windows-11-arm, aarch64-pc-windows-msvc) (pull_request) Has been cancelled
Rust / build-windows (windows-x86_64, win64, windows-2025, x86_64-pc-windows-msvc) (pull_request) Has been cancelled
Rust / build-macos (macos-aarch64, ARM64, aarch64-apple-darwin) (pull_request) Has been cancelled
Rust / Collect release artifacts (pull_request) Has been cancelled
Add host-side netplay session save:
- storage::paths.netplay_state_file_path next to other state files
- savestates::create_savestate_in_memory + SavestateData::save_to_memory
(in-memory capture, same zip layout as on-disk savestates)
- netplay::save_netplay_session(device, path): postcard-encodes
{state, frame, input_delay, rom_hash, players}, zstd-compresses and
writes atomically (tmp + rename); onscreen 'Session saved — safe to quit'
- only the host (player_number 0) may save; others get an onscreen notice
- configurable hotkey (emulation.netplay_save_key, default F7), edge
triggered in ui::input::get and consumed per-frame in check_callback
- unit tests: encode/decode round-trip + file metadata verification
|