Multiplayer Woes

DocCox

Chieftain
Joined
Jan 14, 2012
Messages
14
First off thank you guys for all of the work you put into this mod. Single player it's far more enjoyable than anything else I can find.

My brother and I attempt to complete four hours of Civ4 on LAN every few days. We both have played ROM/AND for quite a while and were able to generally get 4 hours of game play without an OOS, occasionally two or so would crop up but we were able to fix it.

This game can OOS on the first turn depending on the map selection, and its quite often it will OOS once every 20-30 turns prehistoric era, and get worse as time goes on. Now that we have gunpowder units, the games unplayable as it will OOS every turn or two and the save game transfers take enough time were transferring the game more than playing

Random events are off, we even turned barbs off, the map sizes are standard, the speed snail. Both computers are extremely powerful. I suspect a random number generator is refusing to sync up, or rolling before the server provides the required information. I wish I knew more of the issue so I could help solve it. Generally we will have a combat event, or somebody will change civics, and it forces a OOS - the rare turns that is not happening, the game is smooth.

I attempted to use pitboss, but whenever we join the server it states that both players are OOS (with the same sync values) and never corrects. Furthermore I have no idea how to select players/leaders in pitboss - which makes it no fun.

My only other issue with multiplayer is some balancing. Specifically research. Our house rule is neither of us build science wonders - but alas a player can go from 100rp to 300 or more in a single golden age, or... as we noticed recently in about 10 turns with this mod and some workers. If the other human isnt exactly on his tail, the game is essentially over as the farming technology's, forges, etc throw the player hopelessly behind in every area.


The end questions:
1) What can I do without programming knowledge to help locate and correct OOS issues
2) Has anybody had stable games, or stable enough to play all of the way through?
3) If so, could you please share your settings
4) Is there any way to balance the research jumps that put one player so far ahead of the rest that the games over before player 2 hits gunpowder units?


I apologize for the long post, but would appreciate any help. If there is anything I can do to help, please let me know. I would love to see this mod improve even further
 
1) What can I do without programming knowledge to help locate and correct OOS issues
Activate logging, then when an OoS happens, send me the logs from both computers (especially the OoS log in the BtS exe folder and the random log in the normal Civ Logs folder).
 
Activate logging, then when an OoS happens, send me the logs from both computers (especially the OoS log in the BtS exe folder and the random log in the normal Civ Logs folder).

Will do. were planning to throw in a couple of hours today


As for anybody else that intends to use pitboss, your vertical screen resolution needs to be at least 1600 pixels to select what players you want in the game, which is horribly unrealistic. The only solution I found was to turn my monitor to portrait mode to select players/leaders, and then turn it back normally after that was done. This is because of the way pitboss was programmed, and that there are so many 'game options' at the start it forces the window to extend well over any 'standard' resolution. even with 1920 pixels its a little difficult... Your only other option is to use the standard amount of random players based off map size and default difficulty settings :(
 
Will do. were planning to throw in a couple of hours today


As for anybody else that intends to use pitboss, your vertical screen resolution needs to be at least 1600 pixels to select what players you want in the game, which is horribly unrealistic. The only solution I found was to turn my monitor to portrait mode to select players/leaders, and then turn it back normally after that was done. This is because of the way pitboss was programmed, and that there are so many 'game options' at the start it forces the window to extend well over any 'standard' resolution. even with 1920 pixels its a little difficult... Your only other option is to use the standard amount of random players based off map size and default difficulty settings :(
What you can do is this:
Open Caveman2Cosmos/Assets/XML/GameInfo/CIV4GameOptionInfos.xml
There you can set game options to invisible and choose a default value for them.
You might have to copy the file to the other computers for it to work then (not sure if it will OoS if you don't, worth a try).
 
All right, here are the logs the game has decided to save. We had an OOS about every 3 turns on average after about turn 700. Earlier in the game (0-250) there were quite few OOS, maybe 5 not including the turn 0 OOS. I have asked the other player to register and post his OOS logs

I have no idea why the game refuses to save all of the OOS logs... I enabled logging and didn't tell it to delete the files or anything. Same result on the opponents machine


------------
As for the pitboss fix - does not work. Hiding any settings will result in them still showing up in pitboss, however they are grayed out an unchangeable. Still not easily possible to run a game with pitboss.... even though regardless of map or settings both players are OOS permanently with identical sync values


-----------
We are amassing a decent number of bugs, but many are multiplayer specific. For example when a rebel faction decides to join an empire, or a vassal asks to join an empire, the message is displayed for everybody... and for some reason whoever clicks a decision first makes it final. We also have a lot of ideas for balancing the mod, the AI is hopelessly far behind hundreds of turns ago, but i worry our ideas wont be very kind to single player and that's obviously the majority of players...


Anyways, thank you for your help, and I look forward to any knowledge that can be gleaned.
 

Attachments

  • OOS Logs DocCox.7z
    64.9 KB · Views: 60
  • DocCox BTS_Logs.7z
    11.8 KB · Views: 37
As for the pitboss fix - does not work. Hiding any settings will result in them still showing up in pitboss, however they are grayed out an unchangeable. Still not easily possible to run a game with pitboss.... even though regardless of map or settings both players are OOS permanently with identical sync values
A pity. Not sure what else can be done about Pitboss there as I have never used it yet.

I will have a look at the logs once the other player has posted his.

Another important log that I don't see among those you posted now is the random log.
It is activated by RandLog = 1 in the Civ ini with Logging activated.
Many OoS are called by the code on one computer using the RNG while the other does not and that log then shows which one did and also where in the code to look for that RNG call.
 
Here are the others
For the turn 0 ones the OoS logs are identical so I can only assume that it happens in the map script but not in a way that changes the map rand. Which map script have you been using?

The turn 108 one shows differences in a lot of areas including the rands, the positions of a wanderer of both of you and a lot of positions of the AIs. Not sure what could make such a big number of items desync at the same time. Did anything significant happen before the OoS? Do you have a savegame before that happens?
For the future: It would really be good to have the random log in those cases which show a difference in the random sync.

The turn 616 only shows a difference in yield for player 5 (Darius, Persian Empire). Did he complete a building in that turn (if you even know)? Do you have a savegame?

Turn 684 OoS is likely caused by a RNG desync so it needs the random log to find out what exactly is the cause. Turn 889 is the same.
 
OOS happen frequently when
  1. Spies are used
  2. Cities captured (I see thats fixed for future versions)
  3. Great people are born (occasionally)
  4. Great people are used (occasionally)
  5. Golden Ages
  6. Autosave is enabled
  7. Revolutions of any sort
  8. AI attacking units as soon as player hits end turn
  9. AI offering diplomatic deals after turn is ended
  10. Having diplomacy open when your turn is finished and the other player finally ends theirs
  11. Any sort of combat, the more combat the more often it will happen
  12. Any automated units that decide to move AFTER the player has ended their turn!
  13. Civic changes
  14. Random events
  15. OOS are more frequent with goodie huts/barbarians - may be due to combat, animals add to the issue

Pitboss will OOS regardless of what map is chosen, same sync vales != same game, they are completely different. I would say pitboss is an impossibility with this mod :(

I also believe anything that plays a video (Wonders, etc) will cause OOS. We dont normally play single player so we are not sure, but it correlates to great wonders and some great people. Also in multiplayer, when diplomatic victory is off but you still build the palace wonder... you can still win a diplomatic victory. That was sad to discover. We are discontinuing our game due to the sync issues at this time and look forward to starting a fresh game in V20. These are the logs that are provided (everything in the _civ4Logs folder)

Any way to give the AI a handicap civic that gives them a 20% research boost from turn 1? Thats about what it would take for the AI to keep up to us (not that skilled) or at least stay competitive

Thanks so much for the help so far AIAndy. Really looking forward to this mod developing! On a side note... I think the PW3 map script will OOS if using the Rands like you set... we changed it and at least the map loading without OOS worked. Dunno why
 

Attachments

  • Cox Logs.7z
    4.9 MB · Views: 59
  • EricLogs.7z
    2.7 MB · Views: 43
Thank you for the logs. Do those logs correspond to the OoS logs you sent earlier or are they from a different game?

In general to find an OoS issue both the random logs and the OoS logs are needed. If you suspect something specific happened when the OoS occured it will also help if you tell what it is. Savegames help as well if available, especially if they are from before the OoS as that way I can look what happened during the turn.

As an example: From the random logs you sent I can see an OoS that likely happened because a local code created a unit. Now I need the OoS log to find out what unit that might be.
 
They generally do, we played a few turns on a pitboss game and they may also be in there. We'll turn autosave on every turn so we can start giving you the prior turns save before the OOS.
 
All right AIAndy you seem to be on top of solving OOS, so we put in some extra effort in finding them. We played on a much larger map than we normally do, V20, and logged our OOS. To our amazement, they started out few and extremely far between, and we have confirmed at least one and maybe to causes of frequent OOS.

5640 T318 - Unknown cause - Suspected rogue/Thief vs animal
5140 T343 - Unknown cause - Suspected rogue/Thief vs animal
5020 T349 - Unknown cause - Suspected rogue/Thief vs animal
4960 T354 - Unknown cause - Suspected rogue/Thief vs animal
4870 T363 - Unknown cause - Suspected rogue/Thief vs animal
4830 T367 - Thieves disbanded OOS still happening
4820 T368 - Still happening...
4790 T371 - All trackers/hunters were put on fortify... OOS stop occurring. Automation explore/hunt = OOS
4460 T404 - Automation resumed and OOS returned
3450 T505 - Unknown OOS. Possibly AI? Even though almost all of them died right away

Occasionally an animal would inexplicably attack a thief or rouge or whatever their called, even though their hidden. This results in an OOS. If an animal walks onto a tile where a thief/rouge is... it will OOS. Any automation of trackers, or other units (even if you just automate 3 or 4) can/will lead to OOS. Im assuming its because the players computer tells the other 'hey im moving two squares left' and after it sends it, it notices an animal and decides to change its direction without correcting its previous orders. Just a guess, I have no idea.


As for the _Civ4Logs folders... well erm... the files are huge... let me see if this uploads... We enabled autosave every single turn, just to help capture the OOS like you requested as well.

Hmm, even on ultra compression its 74mb... I will have to find a place to upload this other than this site

EDIT----------
OOS_Report.7z
Just a heads up, that extracts to over 1 gb
 
All right AIAndy you seem to be on top of solving OOS, so we put in some extra effort in finding them. We played on a much larger map than we normally do, V20, and logged our OOS. To our amazement, they started out few and extremely far between, and we have confirmed at least one and maybe to causes of frequent OOS.

5640 T318 - Unknown cause - Suspected Rouge/Thief vs animal
5140 T343 - Unknown cause - Suspected Rouge/Thief vs animal
5020 T349 - Unknown cause - Suspected Rouge/Thief vs animal
4960 T354 - Unknown cause - Suspected Rouge/Thief vs animal
4870 T363 - Unknown cause - Suspected Rouge/Thief vs animal
4830 T367 - Thieves disbanded OOS still happening
4820 T368 - Still happening...
4790 T371 - All trackers/hunters were put on fortify... OOS stop occurring. Automation explore/hunt = OOS
4460 T404 - Automation resumed and OOS returned
3450 T505 - Unknown OOS. Possibly AI? Even though almost all of them died right away

Occasionally an animal would inexplicably attack a thief or rouge or whatever their called, even though their hidden. This results in an OOS. If an animal walks onto a tile where a thief/rouge is... it will OOS. Any automation of trackers, or other units (even if you just automate 3 or 4) can/will lead to OOS. Im assuming its because the players computer tells the other 'hey im moving two squares left' and after it sends it, it notices an animal and decides to change its direction without correcting its previous orders. Just a guess, I have no idea.
Good information. Thanks. I have a suspicion about the automation problem. The minimum odds for automated hunt might not be synced properly. Do you have different odds set there?

As for the _Civ4Logs folders... well erm... the files are huge... let me see if this uploads... We enabled autosave every single turn, just to help capture the OOS like you requested as well.

Hmm, even on ultra compression its 74mb... I will have to find a place to upload this other than this site

EDIT----------
OOS_Report.7z
Just a heads up, that extracts to over 1 gb
The OoS log shows a desync in only one thing: The tracker position. So the automation explanation up there is likely.
I only saw one OoS log in there. Do you have the OoS logs for the other turns in which an OoS happened?
 
The OoS log shows a desync in only one thing: The tracker position. So the automation explanation up there is likely.
I only saw one OoS log in there. Do you have the OoS logs for the other turns in which an OoS happened?
The game is not generating logs for every OOS. I do not understand why, as I have enabled it and every other form of logging. Player Eric's machine is also not reporting additional OOS Logs. Perhaps there is an issue with the logger? I had uploaded the saves in hopes it could be reproduced, but maybe I should upload the prior turn?


Good information. Thanks. I have a suspicion about the automation problem. The minimum odds for automated hunt might not be synced properly. Do you have different odds set there?
The setting was changed on Erics machine after OOS on T367. They however automatically reset as soon as we reloaded the game on turn 368

Also, its not just automated hunt that causes the OOS its also automated explore...

For thieves, we manually controlled them in general and anytime an animal somehow got on top of the thieve it would have a chance to OOS (ex: thieve subdues animal, animal attacks the subdued animal, OOS with both sharing tile?) It's a suspicion and not a fact however.


Without automate hunt/explore the Eric player is doomed. He claims to be on a massive continent, with thousands and thousands of animals spawning... Whilist my small island is secure. We do however seem to have a real problem, on all islands (including 1 square islands) animals have spawned.It seems there is no limit to how many animals will exist, small islands are ending up with far, far, far more animals than one would expect (as is Erics continent due to the mass extinction of AI somehow...). Perhaps that belongs in the bugs thread... but I dont see it being a problem for the single player folks really.

As always, your help is much appreciated AIAndy. We will continue the OOS hunt, now that our technology is progressing they should become far more common.
 
New OOS logs, were up to turn 637 now that nothing is being automated except workers
Before I post up all the information, what specifically in the _civ4Logs folder are you interested in (dont like uploading large files). Also, Do you want the save from the turn that tells us we are out of sync, or the save from the turn prior? On one machine or both? Do you have any idea why the game wont save more than one of the OOS files? we found and confirmed a couple of OOS issues, will post it tomorrow probably.
 
New OOS logs, were up to turn 637 now that nothing is being automated except workers
Before I post up all the information, what specifically in the _civ4Logs folder are you interested in (dont like uploading large files). Also, Do you want the save from the turn that tells us we are out of sync, or the save from the turn prior? On one machine or both? Do you have any idea why the game wont save more than one of the OOS files? we found and confirmed a couple of OOS issues, will post it tomorrow probably.
The logs I am interested in are the random logs and the OOS logs. Usually only the last part before the OoS happened is needed in the random logs. So to save space you might want to send only the two last sets.
For the savegames the important thing is that they are from before the OOS happened (it can happen before the actual OOS being reported).
Do you restart Civ4 before reloading the game? If not, then that is probably the reason that it does not save the OOS log as that script uses a global to store if it wrote a log (and I don't think it resets i properly when a new game is loaded).

One recommendation is to use the SVN version as we found out that there was a problem with the compilation of the V20 release which caused crashes and might also have caused other weird behavior.
 
One recommendation is to use the SVN version as we found out that there was a problem with the compilation of the V20 release which caused crashes and might also have caused other weird behavior.

No, it wasn't the v20 version, it was the SVN version that followed it for about 2 days.
 
Hmm, after some further investigation:
Do you have the same or different BUG settings in Sentry While Healing?
 
Me and a friend are getting tired of the OOS phenomena and decided to help you guys get rid of it, by sending in some OOS- & rand num.- logs.

Most of these OOS appear when one of the players manually move hunters around. The hunter part might just be a coincidence since they are way more active in early game than other units.

OOS often appear if I use "go to" twice where the second one is used while the units is performing the first "go to" process. (quick move is turned on)

We don't know witch logs are useful, tell me if there are something missing and which logs are useless to you and if you need the saved games from both players or not at all.
we play with revolution on, no random events and start as minor. Bug settings are identical with "sentry while healing" turned off, and "terrain damage" on.

Hope this helps.
View attachment 312762

View attachment 312763
 
3390 T511 - Player Eric manually ordered hunter to move after already attacking a unit. Unit was auto-moving to tile and discovered animal and OOS

3340 T516 - Eric unit named John Churchill (hunter) ordered to move OOS. DEFINITE bug in the upgrades and how the movement costs are calculated. One machine reports moves cost more than the other, upgrades are not understood by both computers. One machine reports the ability to move 2 squares or 3 while the other reports 1 or 2. Repeatable bug, if your interested.

3330 T517 - Repeated movement bug and confirmed

2930 T557 - OOS related to Hunter vs Nile Moniter. Noticing somewhat frequent OOS when a unit engages a Nile moniter or other animal with withdrawal chances.

2590 T591 - Unknown OOS - we believe it came from deleting an animal (too damn many, too much upkeep). Happened mid turn as we were both deleting animals so we are almost 100% positive

2520 T598 - Barbarian Slinger vs Tracker resulted in OOS

2380 T612 - Unknown OOS

2130 T637 - Unknown OOS

Files will be uploaded later, some OOS's are easily repeatable

As for the BUG settings, all are identical, and will remain identical.

No OOS log was generated at all for the host... the client generated only one.
 
Top Bottom