forked from electronicarts/CnC_Generals_Zero_Hour
-
Notifications
You must be signed in to change notification settings - Fork 117
feat(recorder): Implement replay archive feature #1703
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Conversation
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
xezon
reviewed
Oct 18, 2025
xezon
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you plan to make follow up changes to improve file naming and maybe folders?
f966d34 to
935aa5a
Compare
Author
Yes. This is intended as a first pass to limit the scope of changes. |
xezon
reviewed
Oct 22, 2025
xezon
reviewed
Oct 23, 2025
xezon
reviewed
Oct 24, 2025
6d3a168 to
18e94e3
Compare
xezon
approved these changes
Oct 24, 2025
bobtista
added a commit
to bobtista/GeneralsGameCode
that referenced
this pull request
Oct 25, 2025
Reverting unification of these files to avoid conflicts with: - PR TheSuperHackers#654 (tomsons26): Cleans up inconsistencies - PR TheSuperHackers#670 (zzambers): Replacements for rest of asm code - PR TheSuperHackers#688 (tomsons26): Backports various things from ZH - PR TheSuperHackers#1066 (xezon): Prevent AMD/ATI driver crash - PR TheSuperHackers#1703 (Stubbjax): Add replay archive feature - PR TheSuperHackers#1741 (Skyaero42): Remove redundant include guards Files reverted: - BitFlagsIO.h, DataChunk.h, GameType.h, List.h - Money.h, Radar.h, Recorder.h, SpecialPowerMaskType.h, StackDump.h - NameKeyGenerator.cpp, GameCommon.cpp, StackDump.cpp
bobtista
added a commit
to bobtista/GeneralsGameCode
that referenced
this pull request
Oct 26, 2025
Reverting unification of these files to avoid conflicts with: - PR TheSuperHackers#654 (tomsons26): Cleans up inconsistencies - PR TheSuperHackers#670 (zzambers): Replacements for rest of asm code - PR TheSuperHackers#688 (tomsons26): Backports various things from ZH - PR TheSuperHackers#1066 (xezon): Prevent AMD/ATI driver crash - PR TheSuperHackers#1703 (Stubbjax): Add replay archive feature - PR TheSuperHackers#1741 (Skyaero42): Remove redundant include guards Files reverted: - BitFlagsIO.h, DataChunk.h, GameType.h, List.h - Money.h, Radar.h, Recorder.h, SpecialPowerMaskType.h, StackDump.h - NameKeyGenerator.cpp, GameCommon.cpp, StackDump.cpp
bobtista
added a commit
to bobtista/GeneralsGameCode
that referenced
this pull request
Oct 26, 2025
…#1703 merge PR TheSuperHackers#1703 (replay archive feature) added new methods to Recorder.cpp but we kept Recorder.h/cpp in Generals/MD (not unified). Need to sync the header with the implementation.
fbraz3
pushed a commit
to fbraz3/GeneralsX
that referenced
this pull request
Nov 10, 2025
Introduces a feature to automatically archive replays. Can be enabled by adding ArchiveReplays=yes to Options.ini Whenever the Last Replay (or 00000000.rep) is saved, a copy is placed within an archive directory located at Command and Conquer Generals Zero Hour Data\ArchivedReplays. This ensures that replays can never be accidentally lost. Replays are saved in the format YYYYMMDD_HHMMSS.rep for simplicity and to avoid conflicts.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Approved
Pull Request was approved
Enhancement
Is new feature or request
Gen
Relates to Generals
Minor
Severity: Minor < Major < Critical < Blocker
ZH
Relates to Zero Hour
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.
This change introduces a feature to automatically archive replays. Whenever the Last Replay (or 00000000.rep) is saved, a copy is placed within an archive directory located at
Command and Conquer Generals Zero Hour Data\ArchivedReplays. This ensures that replays can never be accidentally lost, and effectively and reliably replicates theSAVE REPfeature of GenTool.Replays are saved in the format
YYYYMMDD_HHMMSS.repfor simplicity and to avoid conflicts (though this time is local to the system and does not consider conflicts with foreign replays or changes from DST). Any conflicts that do occur are simply overridden (as this is only likely with multi-instance, it doesn't really matter). Possible future changes could involve a more complex naming scheme or adding an accompanying meta file in a similar fashion to GenTool. It might also be worth considering a limiter option; i.e. keep the last # amount of replays.The feature can be enabled by adding
ArchiveReplays = yesto theOptions.ini.Options.ini
AntiAliasing = 2 + ArchiveReplays = yes BuildingOcclusion = yes CampaignDifficulty = 2 ...