0ad/source/ps
vyordan 3808ca0965 Replay: name replay folders after matchID instead of a per-machine index
Replay folders were named YYYY-MM-DD_NNNN, a per-machine sequence
counter. The same multiplayer match got a different folder name per
participant, and unrelated matches could share a name, making it hard
to correlate replays across players (rating aggregation, replay
sharing, bug reports) without parsing commands.txt first.

The engine already generates a matchID once per match, synced to all
participants before the match starts. Replay folders are now named
YYYY-MM-DD_<matchID>, so the same match produces the same folder name
everywhere.

The date comes from a new "startTime" attribute, set once by the host
(StartTime.js, alongside MatchID.js) and synced like matchID, instead
of each machine reading its own local clock. createDateIndexSubdirectory
is untouched (still used by OOS logs and serialization tests); a new
createReplaySubdirectory is added for replays only, following the same
collision-handling pattern (incrementing suffix) as the existing
function. This also means resuming a match (network rejoin, or a
singleplayer game reloaded via StartSavedGame, both of which reuse the
same matchID) saves an additional replay instead of overwriting the
original.

Fixes #8922
2026-08-14 06:57:33 -06:00
..
containers Remove custom span and use std::span 2025-08-24 11:09:57 +02:00
GameSetup Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
memory Removes unused pointer from the allocate function 2025-10-12 00:53:10 +02:00
scripting Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
strings Reduces string allocations in GUI and maths. 2025-10-11 19:44:22 +02:00
tests Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
XMB Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
XML Fix includes in source/ps 2025-08-03 15:57:56 +02:00
algorithm.h Fix includes in source/ps 2025-08-05 07:21:22 +02:00
ArchiveBuilder.cpp Reduces boost usage for strings 2025-10-16 09:17:05 +02:00
ArchiveBuilder.h Fix includes in source/ps 2025-08-05 07:21:22 +02:00
CacheLoader.cpp Reduces string allocations in paths. 2025-10-05 01:31:27 +02:00
CacheLoader.h Fix includes in source/ps 2025-08-05 07:21:22 +02:00
CConsole.cpp Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
CConsole.h Move the console input handler to CConsole 2026-06-19 20:53:52 +02:00
CLogger.cpp Add an engine "compatible" version 2025-10-26 09:16:46 +01:00
CLogger.h Fix includes in source/renderer 2025-07-27 16:07:14 +02:00
Compress.cpp Fix some includes in source/ps 2025-07-28 16:59:04 +02:00
Compress.h Revert non-ASCII characters from source and configuration files introduced in 157c6af18e. 2023-12-03 00:30:12 +00:00
ConfigDB.cpp Reduces boost usage for strings 2025-10-16 09:17:05 +02:00
ConfigDB.h Fix includes in source/ps 2025-08-05 07:21:22 +02:00
CStr.cpp Update trac links with gitea links 2024-12-10 11:29:48 +01:00
CStr.h Fix some headers in gui 2025-07-02 13:20:13 +02:00
CStrForward.h Revert non-ASCII characters from source and configuration files introduced in 157c6af18e. 2023-12-03 00:30:12 +00:00
CStrIntern.cpp Reduces string allocations in GUI and maths. 2025-10-11 19:44:22 +02:00
CStrIntern.h Reduces string allocations in GUI and maths. 2025-10-11 19:44:22 +02:00
CStrInternStatic.h Enables fragment PBR resolve shader in PostProc 2026-06-20 13:29:11 +02:00
DllLoader.cpp Fix includes in source/ps 2025-08-03 15:57:56 +02:00
DllLoader.h Revert non-ASCII characters from source and configuration files introduced in 157c6af18e. 2023-12-03 00:30:12 +00:00
Errors.cpp Don't leak all GUI objects on name ambiguity following 5cc814759f and remove ERROR_GROUP GUI. 2019-10-11 16:20:50 +00:00
Errors.h Fix some includes in source/ps 2025-07-28 16:59:04 +02:00
FileIo.cpp Fix some includes in source/ps 2025-07-28 16:59:04 +02:00
FileIo.h Fix includes in source/ps 2025-08-05 07:21:22 +02:00
Filesystem.cpp Fix some includes in source/ps 2025-07-28 16:59:04 +02:00
Filesystem.h Fix includes in source/ps 2025-08-05 07:21:22 +02:00
Future.h Make TaskManager independent of Future 2025-08-28 20:01:39 +02:00
Game.cpp Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
Game.h Pass debugOptions on construction of CSimulation2 2025-11-01 17:31:54 +01:00
Globals.cpp Change the return type of event-handler 2026-06-19 20:53:52 +02:00
Globals.h Change the return type of event-handler 2026-06-19 20:53:52 +02:00
GUID.cpp Fix some includes in source/ps 2025-07-28 16:59:04 +02:00
GUID.h Revert non-ASCII characters from source and configuration files introduced in 157c6af18e. 2023-12-03 00:30:12 +00:00
Hashing.cpp Fix some includes in source/ps 2025-07-28 16:59:04 +02:00
Hashing.h Revert non-ASCII characters from source and configuration files introduced in 157c6af18e. 2023-12-03 00:30:12 +00:00
Hotkey.cpp Change the return type of event-handler 2026-06-19 20:53:52 +02:00
Hotkey.h Change the return type of event-handler 2026-06-19 20:53:52 +02:00
Input.cpp Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
Input.h Split screenshot from main input handler 2026-06-19 20:53:52 +02:00
Joystick.cpp Fix includes in source/ps 2025-08-03 15:57:56 +02:00
Joystick.h Fix includes in source/ps 2025-08-05 07:21:22 +02:00
KeyName.cpp Fix some includes in source/ps 2025-07-28 16:59:04 +02:00
KeyName.h Fix includes in source/ps 2025-08-05 07:21:22 +02:00
Loader.cpp Don't suspend loader after each finished task 2025-12-27 17:17:06 +01:00
Loader.h Use a coroutine for Loader tasks 2025-12-21 15:51:46 +01:00
Mod.cpp Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
Mod.h Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
ModInstaller.cpp Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
ModInstaller.h Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
ModIo.cpp Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
ModIo.h Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
Profile.cpp Fix some includes in source/ps 2025-07-28 16:59:04 +02:00
Profile.h Fix includes in source/ps 2025-08-05 07:21:22 +02:00
Profiler2.cpp Removes ArrayDeleter 2026-04-10 23:03:00 +02:00
Profiler2.h Use cpp-httplib instead of mongoose 2026-01-24 10:45:48 +01:00
Profiler2GPU.cpp Fix some includes in source/ps 2025-07-28 16:59:04 +02:00
Profiler2GPU.h Fix some includes in source/renderer 2025-07-09 09:04:50 +02:00
ProfileViewer.cpp Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
ProfileViewer.h Move the profileViewer handler to CProfileViewer 2026-06-19 20:53:52 +02:00
Pyrogenesis.cpp Add an engine "compatible" version 2025-10-26 09:16:46 +01:00
Pyrogenesis.h Use the PYROGENESIS_VERSION macro instead of a global 2025-10-26 09:16:44 +01:00
Replay.cpp Replay: name replay folders after matchID instead of a per-machine index 2026-08-14 06:57:33 -06:00
Replay.h Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
SavedGame.cpp Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
SavedGame.h Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
Singleton.h Fix some includes in source/ps 2025-07-28 16:59:04 +02:00
TaskManager.cpp Make TaskManager independent of Future 2025-08-28 20:01:39 +02:00
TaskManager.h Make TaskManager independent of Future 2025-08-28 20:01:39 +02:00
TemplateLoader.cpp Fix some includes in source/ps 2025-07-28 16:59:04 +02:00
TemplateLoader.h Fix includes in source/ps 2025-08-05 07:21:22 +02:00
Threading.cpp Fix some includes in source/ps 2025-07-28 16:59:04 +02:00
Threading.h Fix includes in source/ps 2025-08-05 07:21:22 +02:00
ThreadUtil.h Revert non-ASCII characters from source and configuration files introduced in 157c6af18e. 2023-12-03 00:30:12 +00:00
TouchInput.cpp Change the return type of event-handler 2026-06-19 20:53:52 +02:00
TouchInput.h Change the return type of event-handler 2026-06-19 20:53:52 +02:00
UniDoubler.h Revert non-ASCII characters from source and configuration files introduced in 157c6af18e. 2023-12-03 00:30:12 +00:00
UserReport.cpp Use Future for the userreporter 2025-11-17 21:45:00 +01:00
UserReport.h Revert non-ASCII characters from source and configuration files introduced in 157c6af18e. 2023-12-03 00:30:12 +00:00
Util.cpp Replay: name replay folders after matchID instead of a per-machine index 2026-08-14 06:57:33 -06:00
Util.h Replay: name replay folders after matchID instead of a per-machine index 2026-08-14 06:57:33 -06:00
VideoMode.cpp Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
VideoMode.h Split window from main event handler 2026-06-19 20:53:52 +02:00
VisualReplay.cpp Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
VisualReplay.h Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
World.cpp Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00
World.h Move Script* classes to Script namespace 2026-06-20 17:43:00 +02:00