View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0001109 | OpenClonk | Engine - Network | public | 2014-09-03 19:01 | 2018-01-28 16:35 | ||||||||
Reporter | Jan | ||||||||||||
Assigned To | |||||||||||||
Priority | normal | Severity | minor | Reproducibility | always | ||||||||
Status | acknowledged | Resolution | open | ||||||||||
Product Version | |||||||||||||
Target Version | git master | Fixed in Version | |||||||||||
Summary | 0001109: Sync loss on runtime join | ||||||||||||
Description | Finally I found a way to reliably trigger the runtime join sync loss in Clonk Rage and OpenClonk. | ||||||||||||
Steps To Reproduce | You just have to constantly create control data which affects the values compared in the sync checks. The easiest value to modify is Rnc (RandomCount). In C4Game::Execute(), write if (Network.isHost()) ::Control.DoInput(CID_Script, new C4ControlScript("Random(100)", C4ControlScript::SCOPE_Console), CDT_Queue);to the line above EXEC_S( ExecObjects(); , ExecObjectsStat ) | ||||||||||||
Additional Information | - Control rate must be set to at least 2. - eDeliveryof C4GameControl::DoInput()has to be CDT_Queue. CDT_Syncdoes not cause sync loss. - The bug was introduced somewhere between Clonk Rage 4.9.9.7 [312] and 4.9.10.1 [318], since runtime join still works in [312], but desyncs in [318]. I didn't test the versions between them since I couldn't obtain these versions. | ||||||||||||
Tags | No tags attached. | ||||||||||||
Attached Files |
|
![]() |
|
Sven2 (developer) 2014-09-04 20:36 |
This is very interesting. Have you checked whether the controls between different clients are in the same order in the resulting records? (i.e..: Convert host and client record to text file using rec dump and then just compare). |
Clonkonaut (developer) 2015-11-30 12:39 |
Is this still an issue? |
ala (developer) 2015-11-30 15:54 |
As far as we tested, runtime join doesn't work currently. |
Clonkonaut (developer) 2015-11-30 17:12 |
Yes, runtime join in general. I was asking about this specific bug. |
Jan (reporter) 2015-11-30 20:27 |
Yes, the bug is still present. There is only a workaround (which I'm currently using in Clonk Rage) but no real solution yet. |
Clonkonaut (developer) 2015-12-01 10:45 |
Could you share this workaround? |
Jan (reporter) 2015-12-02 13:41 |
I attached the workaround to the bug report. |
Jan (reporter) 2016-01-02 22:09 |
Uploaded new patch. This is the real fix, not only a workaround like the one before. |
Clonkonaut (developer) 2016-01-04 10:18 |
I have created a corresponding thread in the forum: http://forum.openclonk.org/topic_show.pl?tid=3229 |
PeterW (developer) 2016-01-09 00:35 |
See forum - this patch is probably on the right track, but still quite symptomatic. The "proper way" here would be: 1. Correct which control packets we expect - this boils down to setting the next control ticks for runtime clients correctly in C4GameControlNetwork::AddClient (add +1?). Note that this would have to check whether it's a runtime join, as normal joins definitely want the unchanged start control tick in that space. 2. Figure out why the surplus control gets produced in the first place - jumping over control packets is a big no-no, as it might have stuff like player joins that might get stuck. This is probably going to be a fairly similar change to the one above, but concerning C4GameControlNetwork::SetActivated: For runtime joins (!) you might have to remove the "-1" here. And then pray to god that savegame resumes didn't break again... |
PeterW (developer) 2016-01-09 19:53 |
Hm, your method doesn't seem to be enough to cause desyncs with OC for me. Can you describe exactly what you did - e.g. network configuration, sync check rate and scenario? |
occ (reporter) 2018-01-28 16:35 |
Hi! There's been a check-in that references this bug. For more information you can visit the repository browser at this address: https://git.openclonk.org/openclonk.git/commitdiff/0f78e63f0213a0d2c98791a0fed02d98f3d5b12e Changeset 0f78e63 by Lukas Werling <lukas.werling@gmail.com> Add warning for broken runtime join (0001109) This also fixes the "no runtime join" error appearing for pre-lobby games, where joining usually works anyways. |
![]() |
|||
Date Modified | Username | Field | Change |
---|---|---|---|
2014-09-03 19:01 | Jan | New Issue | |
2014-09-04 20:36 | Sven2 | Note Added: 0003094 | |
2015-10-16 00:33 | Sven2 | Target Version | => 7.0 |
2015-11-30 12:39 | Clonkonaut | Note Added: 0004181 | |
2015-11-30 12:39 | Clonkonaut | Status | new => feedback |
2015-11-30 15:54 | ala | Note Added: 0004200 | |
2015-11-30 17:12 | Clonkonaut | Note Added: 0004204 | |
2015-11-30 20:27 | Jan | Note Added: 0004207 | |
2015-11-30 20:27 | Jan | Status | feedback => new |
2015-12-01 10:45 | Clonkonaut | Note Added: 0004214 | |
2015-12-02 13:40 | Jan | File Added: 0001-Workaround-for-runtime-join-desync.patch | |
2015-12-02 13:41 | Jan | Note Added: 0004231 | |
2016-01-02 19:44 | Clonkonaut | Status | new => acknowledged |
2016-01-02 19:44 | Clonkonaut | Target Version | 7.0 => 7.1 (Bugfix update) |
2016-01-02 22:08 | Jan | File Added: 0001-Fix-sync-loss-on-runtime-join-in-decentral-network-mode.patch | |
2016-01-02 22:09 | Jan | Note Added: 0004450 | |
2016-01-04 10:18 | Clonkonaut | Note Added: 0004457 | |
2016-01-09 00:35 | PeterW | Note Added: 0004498 | |
2016-01-09 19:53 | PeterW | Note Added: 0004506 | |
2017-08-05 09:06 | Maikel | Target Version | 7.1 (Bugfix update) => 8.0 |
2018-01-06 23:41 | K-Pone | Target Version | 8.0 => git master |
2018-01-28 16:35 | occ | Note Added: 0006104 |