Serialize/deserialize all queue data too.
Details
Details
- Reviewers
elexis - Commits
- rP19382: Serialize the queue of cinematic paths playing and resume upon deserialization.
- Trac Tickets
- #3814
- Start multiplayer game on the CinemaDemo map
- Connect to this game after the cutscene's start
- Check that all work synchronously
Diff Detail
Diff Detail
- Repository
- rP 0 A.D. Public Repository
- Lint
Automatic diff as part of commit; lint not applicable. - Unit
Automatic diff as part of commit; unit tests not applicable.
Event Timeline
Comment Actions
Build has FAILED
Link to build: http://jw:8080/job/phabricator/710/
See console output for more information: http://jw:8080/job/phabricator/710/console
Comment Actions
Changes of this diff after the first revision:
- (minimize serialization data): The first version of the diff had serialized all path data in m_Paths and m_PathQueue, the second one now serializes only the names of the path queue to save size when rejoining or doing savegames.
- 2048 for names is not needed, we decided to reduce it to 128 as that is fully sufficient. If there should be some additional data stored, it should be written to some custom tag.
- Removed the // TODO: maybe implement String_Unbounded which would be useful, but should be documented in a trac ticket instead. We already have a way to serialize strings by length (all JS strings are serialized this way, in CBinarySerializerScriptImpl::ScriptString)
- Added few \n
Future Improvements:
- The path rendering is only advanced if the window has focus (even in multiplayer). The path should always be in sync with the simulation, at least in a 1 second margin (so that if a map author wants to focus a specifc entity at a specific time, it should happen that way no matter what)
- It should become impossible to save both rotation and lookAt coordinates (since the camera can look only in one direction). If that is enforced, we can also save less data when serializing.