De-sync problems with 2.8

UxbridgeB

Chieftain
Joined
Jun 20, 2020
Messages
5
First let me thank all you Mod Developers for what is in my opinion the best Mod out of some very good mods available for civilization.
Unfortunately like the original Colonization it can't really be played multiplayer just now.
My friend and I where about 30h into a game on 2.7 when found 2.8 the game was going fine with a de-sync or two when trading with the natives usually by pressing the barter choice by mistake.
We took a look at 2.8 and decided to start again from scratch we have been battling de-sync since then. Having done every thing we can think of and finally having to restart the game about every turn we have had to stop playing :( for now we hope this problem can be solved by one of you mod wizards, or any one who has over come this.
 
Hi UxbridgeB,

first of all there are 2 likely suspects that could potentially be responsible for desyncs.
Both use a kind of "random" system, although both systems are quite different.

1) Python Events
(The small text event Pop-Ups.)

These can be deactivated by Game Option "No Events" in "Custom Game" / "Custom Scenario".
Actually if anybody could try this in MP games and check if there are still desyncs, we could be a lot smarter.

However:
It is not possible that all of them cause desyncs. If at all, it can only be a few couple ones.
It is even possible that the Python Events are all working fine.

2) DLL Events
(The Diplomacy-Dialogue Pop-Ups.)

These can only be deactivated by changing "GlobalDefinesAlt.xml".
But it is not as simple as deactivating the Pyhton Events.

This however would then affect: Native Mercenaries, African Slaves, Native Slaves, Revolutionary Noble, Bishop, Conquistadors, ...
So it would be quite a huge effort to correct all of them.

-------------

If I would have to place my bet one one of the 2 candidates, it would be that the desyncs are caused by "DLL Diplo Events".
It would also match to the easily reproducable desyncs with Bargaining, because the DLL Diplo Events use a similar implementation pattern.

It would also explain, why we have such a trouble of identifying the cause of the desyncs.
The DLL-Event options are "precalculated" with some randomness and trigger their dialog the turn after.

-------------

Problems:


I never played or tested in Mutliplayer.
Even if I knew what exactly causes the desync and tried to fix it, I would have a hard time verifying that the fix worked.

Also, I know very little about desyncs technically.
Nightinggale knows much more about it.

-------------

Summary:

At the moment we simply do not know what exactly causes the desyncs.
Even though we have reports from our community, we are still guessing the cause.

We were never really able to pin-point it like:
"Every time X happens, it desyncs."

A fast fix for the desync problem anywhere soon is unlikely.
I am not even sure if any of the old team members are currently actively working on the mod.

But if somebody could check MP games with Game Options "No Events",
it would really give us valuable information to narrow down the potential causes.
 
I don't know if this helps.
 

Attachments

  • col python exeption0000.JPG
    col python exeption0000.JPG
    145.3 KB · Views: 296
We are playing with my brother in multiplayer, we only played 2.8 version. Lot of desyncs so far. We play with simultaneous turns of course, and one thing that seemed to help, when the first player has pressed the "end turn" button, he does not check city screens and other screens, because when the other player ends the turn, this can cause desync. So, for example, I hit "end turn", my brother is still playing, then I go to a city screen to check something, my brother ends the turn while I am still on the city screen, this can can cause desync. So it is better to not touch anything after I hit "end turn". I hope I explained it clear enough. :) When we have the time to continue playing, I can maybe provide some more feedback.

(And btw, we both have the Steam version, and only direct IP is working and only through Hamachi when we are not in the same LAN. It took a while to figure this out. Are we doing something wrong or is this normal?)
 
Last edited:
We are playing using Steam internet the game restarts when you get an invite so you need to have the game auto load the mod at start. We just started a new game with no random events, and after 3h of play we have no De-sync so far.
 
OK 6 De-syncs from 1544 to 1562 All related to ships arriving in port or founding fathers we had no ruins and no random events on.
 
I will need a desyncing savegame in order to investigate what the problem is. If you can upload a savegame where all I have to do is to click end turn and it will then desync when the next turn starts, then I will have the best chance at finding the issue.

when trading with the natives usually by pressing the barter choice by mistake.
Yeah it has been a known issue with bartering for a while and there have been attempts at fixing it a few times. Clearly not successful yet, but we haven't given up on it.
 
We just started a new game with no random events, and after 3h of play we have no De-sync so far.

Interesting. :think:

We play with simultaneous turns of course, ...

Ah ... :think:

Could somebody please try what happens if you play MP with sequential turns?
It might be possible that by this there would not be any desyncs anymore.

Please however play with "Random Events" activated to get a comparison.

------------

At the moment I get the following "gut feeling":

The desyncs are not caused by DLL-Diplomacy-Events (which is good news)

Instead they are eventually caused by these 2 factors:

A) simultaneous turns play style in Multiplayer
AND
B) Random Event triggering (talking about a Python Event)

Explanation:

Part 1:
Already in TAC (10 years ago) we had the issue that MP games had (random) desyncs.
But at the same time we found out that "PBEM - Play By eMail" MP games - where player turns are sequential - had no desync issues at all. (Just like SinglePlayer)

Part 2:
As far as I know the "simultaneous MP" was added pretty late to Civ4Col (after it was introduced in Civ4BTS due to user complaints) and maybe not properly tested.
Also Civ4Col Vanilla did not have random Python Events - in TAC we completely built that event system almost from scratch by reusing some code from Civ4BTS.
(All Civ4Col Vanilla had were some fixed Python Popu-Ups for Tutorial infos. It was not even close to the current event Event system implemented in WTP.)

------------

Summary:

Please somebody try a MP game with sequential turns (not simultaneous).
Please play with Random Events (Python Events) being active.

Edit:

I know that sequential turns are not ideal because you have to wait for the other player to end his turn. So this is not necessary the final solution, if it proves to be true.
But if it proves that the desyncs are cause by Python events in MP games with simutaneous turns, we are much closer to being able to understund and thus to fix.
 
Last edited:
OK 6 De-syncs from 1544 to 1562 All related to ships arriving in port or founding fathers we had no ruins and no random events on.

Ok, this then would prove my theory considering "desyncs caused by Python Events" to be wrong.
(Or at least it could not be the only reason then.)

However:

I still believe it is caused by or at least related to "simultaneous turns" for MP games.
(Which is Vanilla code we never touched in either TAC nor RaR nor WTP.)

The more I think about it, the more convinced I am that this really is the issue.
(Which does not mean that I have an idea how to solve it yet.)

For further analysis we would really need somebody to play a MP game with "sequential turns".
(Just for testing purposes to help us analyse.)
 
Last edited:
I often play with 2 or three others in multi-player games. We The People has proven to be the most captivating out of all available Civ games for multi-player.

@mrjepson:

So for you and your friends MP is working acceptably?
Or are you guys having lots of desyncs as well?
 
Only direct IP is working and only through Hamachi when we are not in the same LAN.
It took a while to figure this out.
Are we doing something wrong or is this normal?

As far as I know, direct IP is the only more or less reliable way to play MP games in LAN with Civ4Col.
And Hamachi I have also heared several times. But I do not know anything about it.

So yes, it sounds "normal". :)
But my information may be very outdated - time before the Steam version and its MP problems - and is also only second hand information since I do not play MP games myself.

When we have the time to continue playing, I can maybe provide some more feedback.

Thanks. :thumbsup:
 
Last edited:
we tried to play multiplayer with sequential moves - there is a desync.

Hm. :(
That is disappointing because I am now no smarter than before.

Still thanks for the information. :thumbsup:
 
POTENTIALLY GOOD NEWS !!!

Hi guys,

one of our supporters (marvol77) has reported in the internal forum, that he might have found the cause for the OOS desyncs and fixed it! :eek:
(He wrote that after he fixed it, he did not have any OOS desyncs anymore in his MP games ... at least so far.)

If he is correct, it was really a tiny issue (not even a real bug) that the compiler did not complain about and Singleplayer does not care at all. :cringe:
(It was simply an unecessary redeclaration of a variable ...)

Problem is, that I can not verify the fix myself in Multiplayer.
So somebody (actually playing MP games) please help to verify it in Mulitplayer.

Uploaded you will find a new the new version of the DLL with the mentioned fix.
(It is the 2-Plot-City-Screen version. If the fix is verified, we will also provide a 1-Plot-City-Screen version.)

How to use it:

1. Unpack the CvGameCoreDLL.7z (e.g. using a current version of WinRaR or 7z)
2. Copy the CvGameCoreDLL.dll you will find inside into the "/Assets" folder of your local WTP installation
3. Please start a new game to be sure. (I do not know if existing MP savegames are already corrupted by the OOS issue.)

Of course: Both players of the MP game need the new DLL.
(It does not help if only 1 player has it.)

By the way:
This will not break any savegames (in Singleplayer).
We simply do not yet for sure if it will really fix the OOS desyncs.
 

Attachments

Last edited:
We tried this dll file and did not solve the desync issues we are having in 2.8.

However, we sometimes can 'overcome' the desync, where we can still play and turn, it magically disappears after one or two turns. The red desync message disappears too then.

Also to note, when there is a desync its always one person that desyncs and not more.
Sometimes me, sometimes one of my friends.
It appears also to us this happens when one of us is fighting against indians. ( we tried the 'don't go to your city view when you are done with your turn rule, to rule out that desync, explained in a few posts earlier )

A steam multiplayer game has never worked for us with the mod installed. I'm curious to know how others do this, connecting clients are never seeing the hosts game when we try it, so we use the old cd version and do a 'direct ip option'

If you want to have our log files, please let me know how to source them for you. We are happy to participate as test subjects since we play WTP a lot for over many and many years..
 
If you want to have our log files, please let me know how to source them for you. We are happy to participate as test subjects since we play WTP a lot for over many and many years..
Sounds like I need to continue to work on my desync hunting code. I added a button to make all players save the game in plain text, which can then be used to analyzing what is going on. While you have it, you do need to edit a source file to display the button. That's not a great design, but it was the quick one I added for personal usage. I used it to figure out that the AI managed to cause a desync in a plot no player had ever seen. That would have been tricky to figure out through playing the game. Needless to say I fixed that bug once I discovered it and it's not the one causing the problem now.
 
Back
Top Bottom