Repository navigation
Zdxsv: lobby game patches in replays and live streams - #593
Merged
Merged
Conversation
…pply them at playback Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of Changes
BattleLogFile.patches, field 60;GamePatch/GamePatchCodemessages), so both the saved file and the live stream carry them.PlayCommonStart, before key 0 is saved), rewrite the every-frame ones after each played frame (PlayNext), and restore the originals atPlayStop. Same checks as in battle: disc serial and originals.m4z.py: the spectator (LIVE) and the API replay (REPLAY_API) must apply every lobby patch and restore it; withoutPATCHES, none.Rationale behind Changes
A patched battle replayed or watched without its patches would desync. Follow-up to PR 592 (inada-s/zdxsv#284).
Suggested Testing Steps
Verified on windows-mini (private rig, commit c982b92, server zdxsv ai/game-patch):
CLIENTS="1 3" EMU=1 GGPO=7101 NAT=open PATCHES=tests/zdxsv/server_patches.json LIVE=2 UPLOAD=1 REPLAY_API=4 m4z.py: PASS x2. Spectator and API replay: both patches applied and restored, 0 state hashes differ.CLAMP=none rplay.py: PASS, 0 differ, no patch applied.appliedFAIL.Not run: four players,
LIVE_NEXT, a seek or point-of-view switch while patched.Did you use AI to help find, test, or implement this issue or feature?
Yes: written and rig-tested by Claude Code.
🤖 Generated with Claude Code